diff --git a/Commands.md b/Commands.md index 44deb5d..6e57189 100644 --- a/Commands.md +++ b/Commands.md @@ -997,16 +997,17 @@ Issue FOO-456 #close Review https://reviews.foo.org/r/4567/ ``` -Replace previous issues with a new one +Replace previous issues with a new one +(Note that the identifier is case insensitive) ```bash -$ git stamp --replace Issue BAR-123 +$ git stamp --replace issue BAR-123 Fix timezone bug Review https://reviews.foo.org/r/4567/ -Issue BAR-123 +issue BAR-123 ``` diff --git a/bin/git-stamp b/bin/git-stamp index 6de567d..0f48553 100755 --- a/bin/git-stamp +++ b/bin/git-stamp @@ -39,7 +39,7 @@ stamp() { # remove previous stamps with same ID from the commit message commit_msg=$( echo "${commit_msg}" \ - | grep --invert-match "^${ID}\b" \ + | grep --ignore-case --invert-match "^${ID}\b" \ | cat --squeeze-blank ) fi diff --git a/man/git-stamp.1 b/man/git-stamp.1 index c36a45c..ab723fb 100644 --- a/man/git-stamp.1 +++ b/man/git-stamp.1 @@ -32,6 +32,7 @@ With this flag, all the related stamps with the same identifier will be removed .nf Replace all previous stamps in the last commit message that have the same identifier +The identifier is case insensitive for this replacement . .fi . @@ -94,17 +95,20 @@ $ git stamp Review https://reviews\.foo\.org/r/4567/ .P Replace previous issues with a new one . +.br +(Note that the identifier is case insensitive) +. .IP "" 4 . .nf -$ git stamp \-\-replace Issue BAR\-123 +$ git stamp \-\-replace issue BAR\-123 | Fix timezone bug | | Review https://reviews\.foo\.org/r/4567/ | -| Issue BAR\-123 +| issue BAR\-123 . .fi . diff --git a/man/git-stamp.html b/man/git-stamp.html index e2a4ae0..501a9d4 100644 --- a/man/git-stamp.html +++ b/man/git-stamp.html @@ -91,7 +91,8 @@ With this flag, all the related stamps with the same identifier will be removed
-r, --replace
-Replace all previous stamps in the last commit message that have the same identifier
+Replace all previous stamps in the last commit message that have the same identifier
+The identifier is case insensitive for this replacement
EXAMPLES
@@ -107,9 +108,9 @@ With this flag, all the related stamps with the same identifier will be removed
$ git stamp Issue "FOO-456 #close"
| Fix timezone bug
-|
+|
| Issue FOO-123
-|
+|
| Issue FOO-456 #close
@@ -122,24 +123,25 @@ $ git stamp Issue "FOO-456 #close"
| Issue FOO-123
|
| Issue FOO-456 #close
-|
+|
| Review https://reviews.foo.org/r/4567/
-Replace previous issues with a new one
+Replace previous issues with a new one
+(Note that the identifier is case insensitive)
$ git stamp --replace Issue BAR-123
+$ git stamp --replace issue BAR-123
| Fix timezone bug
|
| Review https://reviews.foo.org/r/4567/
|
-| Issue BAR-123
+| issue BAR-123
AUTHOR
-Written by Damien Tardy-Panis <damien@tardypad.me>
+Written by Damien Tardy-Panis <damien@tardypad.me>
REPORTING BUGS
diff --git a/man/git-stamp.md b/man/git-stamp.md
index 9a443f9..ada53fa 100644
--- a/man/git-stamp.md
+++ b/man/git-stamp.md
@@ -18,7 +18,8 @@ With this flag, all the related stamps with the same identifier will be removed
-r, --replace
- Replace all previous stamps in the last commit message that have the same identifier
+ Replace all previous stamps in the last commit message that have the same identifier
+ The identifier is case insensitive for this replacement
## EXAMPLES
@@ -49,15 +50,16 @@ Link to its review page
|
| Review https://reviews.foo.org/r/4567/
-Replace previous issues with a new one
+Replace previous issues with a new one
+(Note that the identifier is case insensitive)
- $ git stamp --replace Issue BAR-123
+ $ git stamp --replace issue BAR-123
| Fix timezone bug
|
| Review https://reviews.foo.org/r/4567/
|
- | Issue BAR-123
+ | issue BAR-123
## AUTHOR