aboutsummaryrefslogtreecommitdiffhomepage
path: root/scripts/gist
diff options
context:
space:
mode:
authortypebrook <typebrook@gmail.com>2020-02-09 17:51:54 +0800
committertypebrook <typebrook@gmail.com>2020-02-09 17:51:54 +0800
commit6ca6cfaeffe75002b1b2c729079cebb7b3443d5e (patch)
tree33d0301769d1fabd1ce830d6b99fd1f7fc40f7cd /scripts/gist
parentc1c3c55f875a7c22f404a20e2f61ea9a7ecb602c (diff)
update
Diffstat (limited to 'scripts/gist')
-rwxr-xr-xscripts/gist9
1 files changed, 6 insertions, 3 deletions
diff --git a/scripts/gist b/scripts/gist
index c2c500f..ffbdd47 100755
--- a/scripts/gist
+++ b/scripts/gist
@@ -256,7 +256,9 @@ _show_list() {
256 echo -e "$(printf "% 3s" $index)" $link $name $extra $description \ 256 echo -e "$(printf "% 3s" $index)" $link $name $extra $description \
257 | cut -c -$(tput cols) 257 | cut -c -$(tput cols)
258 done 258 done
259 $hint && echo -e '\nrun "gist fetch" to update gists or "gist help" for more details' > /dev/tty 259
260 $hint && echo -e '\nrun "gist fetch" to update gists or "gist help" for more details' > /dev/tty \
261 || return 0
260} 262}
261 263
262# TODO support filenames, file contents 264# TODO support filenames, file contents
@@ -548,9 +550,10 @@ if [[ $init ]]; then _fetch_gists; exit 0; fi
548case "$1" in 550case "$1" in
549 "") 551 "")
550 [[ -z "$hint" ]] && hint=true 552 [[ -z "$hint" ]] && hint=true
551 _show_list ;; 553 hint=$hint _show_list ;;
552 star | s) 554 star | s)
553 hint=true mark=s _show_list ;; 555 [[ -z "$hint" ]] && hint=true
556 hint=$hint mark=s _show_list ;;
554 fetch | f) 557 fetch | f)
555 _fetch_gists "$2" ;; 558 _fetch_gists "$2" ;;
556 new | n) 559 new | n)