diff options
author | typebrook <typebrook@gmail.com> | 2020-01-16 13:18:48 +0800 |
---|---|---|
committer | typebrook <typebrook@gmail.com> | 2020-01-16 13:18:48 +0800 |
commit | abae0fc598e9d8f008d0ced1594303baece3c0af (patch) | |
tree | b117bee89d384c3b0c66cad61db298c1d42321d1 /scripts | |
parent | 60ed93757f1a741f3e651ba203b7bc50fb1f9369 (diff) |
update
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/gist | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/scripts/gist b/scripts/gist index bd37b1e..b3b9e85 100755 --- a/scripts/gist +++ b/scripts/gist | |||
@@ -59,7 +59,13 @@ index=$folder/index | |||
59 | 59 | ||
60 | # Show the list of gist, but not updated time | 60 | # Show the list of gist, but not updated time |
61 | _show_list() { | 61 | _show_list() { |
62 | cat $index | cut -d' ' -f1-2,4- | 62 | cat $index |\ |
63 | while read line_num link file_url_array file_num extra description; do | ||
64 | repo=$folder/$(echo $link | sed 's#.*/##') | ||
65 | # if there is something need to commit | ||
66 | cd $repo && [[ -n $(git status --short) ]] && extra="\e[36m[working]\e[0m" | ||
67 | echo -e $line_num $link $file_num $extra $description | ||
68 | done | ||
63 | } | 69 | } |
64 | 70 | ||
65 | # get the list of gists | 71 | # get the list of gists |