diff options
author | typebrook <typebrook@gmail.com> | 2020-05-08 22:31:49 +0800 |
---|---|---|
committer | typebrook <typebrook@gmail.com> | 2020-05-08 22:31:49 +0800 |
commit | d2bb4b1881d45e42f9aca0e08aeb601dca0f02d5 (patch) | |
tree | 2fa20149492e328001daf82635a22ab7b533dd32 | |
parent | 0cbb0e7ef11db50c4e96a19e878a79830bf4fd42 (diff) |
Remove temporary file after user create a gist
-rwxr-xr-x | gist | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -654,8 +654,8 @@ _new_file() { | |||
654 | 654 | ||
655 | echo > /dev/tty | 655 | echo > /dev/tty |
656 | [[ -z $1 ]] && read -e -r -p 'Type file name: ' filename < /dev/tty | 656 | [[ -z $1 ]] && read -e -r -p 'Type file name: ' filename < /dev/tty |
657 | mv "$tmp_file" /tmp/"$filename" | 657 | mv "$tmp_file" $tmp_dir/"$filename" |
658 | echo /tmp/"$filename" | 658 | echo $tmp_dir/"$filename" |
659 | } | 659 | } |
660 | 660 | ||
661 | # Parse JSON object of a single gist | 661 | # Parse JSON object of a single gist |