gzipping up a set of directories and creating a tar compressed file

后端 未结 5 1495
孤独总比滥情好
孤独总比滥情好 2020-12-29 07:26

My bash fu is not what it should be.

I want to create a little batch script which will copy a list of directories into a new zip file.

There are (at least) t

5条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-29 08:11

    You can export a variable like DIRECTORIES="DIR1 DIR2 DIR3 ...." And in the script you need to use the variable like tar czvf $DIRECTORIES

提交回复
热议问题