From 5e102ff5dbcd5541c7597071ec6bd5a431ab41e4 Mon Sep 17 00:00:00 2001 From: chonghe Date: Tue, 3 Oct 2023 20:40:13 +0800 Subject: [PATCH] Fix indent and echo file not found --- scripts/cli.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/cli.sh b/scripts/cli.sh index 3d703ae153..5dee050235 100755 --- a/scripts/cli.sh +++ b/scripts/cli.sh @@ -10,7 +10,7 @@ write_to_file() { cmd=${cmd#*$'\n'} # We need to add the header and the backticks to create the code block. - printf "# %s\n\n\`\`\`\n%s\n\`\`\`" "$program" "$cmd" > "$file" + printf "# %s\n\n\`\`\`\n%s\n\`\`\`" "$program" "$cmd" > "$file" } # Check if a lighthouse binary exists in the current branch. @@ -66,7 +66,8 @@ if [[ -f $1 ]]; then # check for existence of file else cp $2 ./book/src changes=true - exist+=(true) + exist+=(true) + echo "$1 is not found, it has just been created" fi if [[ -z $diff ]]; then # check for difference