Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Make sure EDITOR is set
- export EDITOR=vim
- mkdir diary
- cd diary
- git init
- # this installs shortcuts for creating a diary
- echo """
- [alias]
- r = log --date=local --pretty=format:\"[%h] %ad (%ar): %n%C(yellow)%s%C(reset) %n%b\"
- c = log --date=local --pretty=format:\"%C(red)%ad%C(reset)%n%C(yellow)%s%C(reset) %n%b %n\"
- s = log --date=short --pretty=format:\"%ad %s\"
- n = commit --allow-empty
- q = commit --allow-empty -m
- u = commit --allow-empty --amend
- """ >> .git/config
- # Now you can add a quick entry
- git q "This is a short one line entry"
- # A longer one entry that opens in your $EDITOR
- git n
- # View your entries
- git c
- git s
- git r
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement