From 6d70d519841f550486820e9eec83736696631f85 Mon Sep 17 00:00:00 2001 From: Will Hilton Date: Sun, 26 Mar 2017 12:33:17 -0400 Subject: [PATCH] Add 'g amend' (and also 'g ammend' because I have trouble spelling that one) --- README.md | 1 + bin/g | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/README.md b/README.md index 48f0656..91627f1 100644 --- a/README.md +++ b/README.md @@ -38,6 +38,7 @@ g | git equivalent g commit | Prompts for commit message inline, rather than opening a text editor g commit *message* | git commit -m *message* g uncommit | git reset --soft HEAD~1 +g ammend | git commit --amend --no-edit g branch *branch* | stashes working tree, creates or switches branch, and checks out branch g rmbranch *branch* | git branch -d *branch* *TODO: rename?* g tag *tag* | git tag *tag* diff --git a/bin/g b/bin/g index b84d042..d6f09ac 100755 --- a/bin/g +++ b/bin/g @@ -167,6 +167,10 @@ uncommit) git reset --soft HEAD~1 ;; +amend | ammend) +git commit --amend --no-edit +;; + '@' | branch) echo 'Switching to branch' if [ -z "$2" ]; then