質問するログイン新規登録

回答編集履歴

2

ダブルクォーテーションの削除

2020/06/11 08:04

投稿

ToyoshimaHi
ToyoshimaHi

スコア130

answer CHANGED
@@ -1,7 +1,7 @@
1
1
  拝見しました。以下のようにしてはどうでしょうか?
2
2
 
3
3
  ```bash
4
- if [ 0 -lt $(ls -l "${out_dir}/*.xyz.gz" | wc -l) ]; then
4
+ if [ 0 -lt $(ls -l ${out_dir}/*.xyz.gz | wc -l) ]; then
5
5
  echo "file already exist"
6
6
  else
7
7
  echo "file not exists"

1

条件分岐の訂正

2020/06/11 08:04

投稿

ToyoshimaHi
ToyoshimaHi

スコア130

answer CHANGED
@@ -2,8 +2,8 @@
2
2
 
3
3
  ```bash
4
4
  if [ 0 -lt $(ls -l "${out_dir}/*.xyz.gz" | wc -l) ]; then
5
+ echo "file already exist"
6
+ else
5
7
  echo "file not exists"
6
- else
7
- echo "file already exists"
8
8
  fi 2> /dev/null
9
9
  ```