diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2018-12-06 14:58:18 +1300 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2018-12-06 14:58:18 +1300 |
commit | b4c295ebb2ea54c4187795c7a9987e2b31b33bb9 (patch) | |
tree | 5564c6e22bae5ffccd849e0af573f4eb48304e8a | |
parent | Remove unneeded semicolon (diff) | |
download | watch-vcs-tags-b4c295ebb2ea54c4187795c7a9987e2b31b33bb9.tar.gz watch-vcs-tags-b4c295ebb2ea54c4187795c7a9987e2b31b33bb9.zip |
Correct subcommands for tags generation function
I got them around the wrong way...
-rw-r--r-- | watch-git-tags.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/watch-git-tags.sh b/watch-git-tags.sh index 7dabb71..f8d4265 100644 --- a/watch-git-tags.sh +++ b/watch-git-tags.sh @@ -1,8 +1,8 @@ # Function to retrieve and filter tag names tags() { case $1 in - remote) git -C "$repo" show-ref --tags ;; - local) git -C "$repo" ls-remote --quiet --refs --tags ;; + local) git -C "${2:-.}" show-ref --tags ;; + remote) git -C "${2:-.}" ls-remote --quiet --refs --tags ;; *) return 2 ;; esac | while read -r _ tag ; do |