bash variable interpolation separate variables by a hyphen or underscore

后端 未结 3 1323
死守一世寂寞
死守一世寂寞 2020-11-30 15:30

This is a simple script just to see if the file has been downloaded. On this script the find command always evaluated to zero - even if it didn\'t find anything. So I commen

3条回答
  •  春和景丽
    2020-11-30 15:59

    You can use backslash to do that.

    # filename=test
    # yesterday=somedate
    # echo $filename_$yesterday.csv
    somedate.csv
    # echo $filename\_$yesterday.csv
    test_somedate.csv
    #
    

提交回复
热议问题