Skip to content

Commit

Permalink
Add version flag
Browse files Browse the repository at this point in the history
  • Loading branch information
yankeexe committed Jan 27, 2022
1 parent dd32b71 commit 311b2fe
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,3 +87,9 @@ Update to the latest release
```bash
$ wt update
```

Show the CLI version

```bash
$ wt version
```
6 changes: 5 additions & 1 deletion wt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e
# Switch between git worktrees with ease.

args=("$@")
VERSION="0.0.7"
VERSION="0.0.8"
TMP_PATH=$(mktemp)
BINARY_PATH=$(which wt)
JQ_URL="https://stedolan.github.io/jq/download"
Expand All @@ -22,6 +22,7 @@ help_message() {
echo -e "\twt <worktree-name>: search for worktree names and change to that directory."
echo -e "\twt list: list out all the git worktrees."
echo -e "\twt update: update to the latest release of worktree switcher."
echo -e "\twt version: show the CLI version."
echo -e "\twt help: shows this help message."
}

Expand Down Expand Up @@ -86,6 +87,9 @@ update)
help)
help_message
;;
version)
echo Version: $VERSION
;;
-)
goto_main_worktree
;;
Expand Down

0 comments on commit 311b2fe

Please sign in to comment.