https://github.com/bmoneill/habit
Break bad habits in the terminal
https://github.com/bmoneill/habit
bash command-line productivity terminal
Last synced: about 2 months ago
JSON representation
Break bad habits in the terminal
- Host: GitHub
- URL: https://github.com/bmoneill/habit
- Owner: bmoneill
- License: mit
- Created: 2025-07-09T18:15:30.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2025-07-09T18:24:35.000Z (12 months ago)
- Last Synced: 2025-09-06T20:59:54.509Z (10 months ago)
- Topics: bash, command-line, productivity, terminal
- Language: Shell
- Homepage:
- Size: 6.84 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# habit: Break bad habits in the terminal
This is a script to help you break bad habits when using the terminal. Upon
running a command with `habit`, you will be prompted to see if you have addressed
all possible concerns/prerequisites before the command is executed.
## Installing
```shell
sudo make install
```
## Usage
Habit is mainly designed to be used in Bash aliases. After installing, put
something like the following in `~/.config/habits.csv`:
```csv
COMMAND,MESSAGE
git,Make sure you are on the right branch
git,Make sure your commit message is descriptive
git,Make sure your code works
rm,Make sure you really want to remove these files!
```
Modify your `.bashrc`:
```bash
alias git="habit git"
alias rm="habit rm"
```
Habit will now prompt you every time you run the command:
```bash
$ git commit
habit:
- Make sure you are on the right branch
- Make sure your commit message is descriptive
- Make sure the project builds
Did you address these concerns? (y/n):
```
## License
Copyright (c) 2025 Ben O'Neill . This work is released under the
terms of the MIT License. See [LICENSE](LICENSE) for the license terms.