chmod a+x myscript.sh
chmod u=rwx, go=r myscript.sh
chmod a-w myscript.sh
chmod = myscript.sh
chmod 644 myscript.sh
chmod 755 myscript.sh
chmod 666 myscript.sh
u - 用户 (文件的所有者)
g - 组 (文件组的成员)
o - 全局 (所有非所有者和非组员的用户)
a - 所有 (上述所有3个角色)
7 - 完全 (rwx)
6 - 读写 (rw-)
5 - 读+执行 (r-x)
4 - 只读 (r--)
3 - 写+执行 (-wx)
2 - 只写 (-w-)
1 - 只执行 (--x)
0 - 无 (---)
chmod a+x myscript.sh
chmod u=rwx, go=r myscript.sh
chmod a-w myscript.sh
chmod = myscript.sh
chmod 644 myscript.sh
chmod 755 myscript.sh
chmod 666 myscript.sh
u - user (owner of the file)
g - group (members of file's group)
o - global (all users who are not owner and not part of group)
a - all (all 3 roles above)
7 - full (rwx)
6 - read and write (rw-)
5 - read and execute (r-x)
4 - read only (r--)
3 - write and execute (-wx)
2 - write only (-w-)
1 - execute only (--x)
0 - none (---)
腾图小抄 SCWY.net v0.03 小抄561条 自2022-01-02访问247794次