]> git.rmz.io Git - dotfiles.git/commitdiff
zsh: motd: git --fixup and --autosquash
authorSamir Benmendil <samir.benmendil@gmail.com>
Mon, 15 Jun 2015 22:59:54 +0000 (23:59 +0100)
committerSamir Benmendil <samir.benmendil@gmail.com>
Tue, 16 Jun 2015 03:42:50 +0000 (04:42 +0100)
zsh/lib/motd.zsh [new file with mode: 0644]

diff --git a/zsh/lib/motd.zsh b/zsh/lib/motd.zsh
new file mode 100644 (file)
index 0000000..43e8152
--- /dev/null
@@ -0,0 +1,9 @@
+autoload colors; colors;
+
+msg()
+{
+  print "$fg_bold[white]$1$reset_color\n$2\n"
+}
+
+msg "gc --{fixup,squash} :/commitmsg " "auto constructs a '{fixup,squash}!' commit message for the last commit matching 'commitmsg'"
+msg "git rebase --autosquash         " "{fixup,squash} commits starting with {fixup,squash}!, must be --interactive"