How to create a directory and give permission in single command

后端 未结 8 1980
日久生厌
日久生厌 2021-01-29 23:27

How to create a directory and give permission in single command in Linux?

I have to create lots of folder with full permission 777.

Commands

8条回答
  •  臣服心动
    2021-01-29 23:55

    IMO, it's better to use the install command in such situations. I was trying to make systemd-journald persistent across reboots.

    install -d  -g systemd-journal -m 2755 -v /var/log/journal
    

提交回复
热议问题