diff options
| author | typebrook <typebrook@gmail.com> | 2020-01-22 17:33:10 +0800 |
|---|---|---|
| committer | typebrook <typebrook@gmail.com> | 2020-01-22 17:33:10 +0800 |
| commit | 844ac3f003db495822d298ae18379a2220c1d723 (patch) | |
| tree | ca453ff4280b6050284b98f123030bad79ce124b /scripts | |
| parent | cf074c00e1a7c5b5176986be5043a9b72a61f1c2 (diff) | |
update
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/gist | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/gist b/scripts/gist index 853ab99..db316d6 100755 --- a/scripts/gist +++ b/scripts/gist | |||
| @@ -104,7 +104,8 @@ _show_list() { | |||
| 104 | local repo=$folder/$(echo $link | sed 's#.*/##') | 104 | local repo=$folder/$(echo $link | sed 's#.*/##') |
| 105 | 105 | ||
| 106 | # if repo is not yet cloned, show green message "Sync Now" | 106 | # if repo is not yet cloned, show green message "Sync Now" |
| 107 | cd $repo 2>/dev/null || extra="\e[32m[Sync Now]\e[0m" | 107 | # FIXME |
| 108 | [[ ! -d $repo ]] && extra="\e[32m[Sync Now]\e[0m" | ||
| 108 | # if there are some changes in git index or working directory, show blue message "working" | 109 | # if there are some changes in git index or working directory, show blue message "working" |
| 109 | [[ -n $(git status --short) ]] 2>/dev/null && extra="\e[36m[working]\e[0m" | 110 | [[ -n $(git status --short) ]] 2>/dev/null && extra="\e[36m[working]\e[0m" |
| 110 | # if there is a commit not yet push, show red message "ahead" | 111 | # if there is a commit not yet push, show red message "ahead" |