如何通过命令提示符模式在Windows中设置文件权限?

10
如何通过命令提示符模式在Windows中设置相同的文件权限?

除了 attrib 命令,你还可以使用 cacls 或 icacls 命令。http://ss64.com/nt/cacls.html - Anathema.Imbued
当我在Win7中使用cacls时,会显示以下消息:"注意:Cacls现已弃用,请使用Icacls。" - Lai
1个回答

5
>attrib /?
Displays or changes file attributes.

ATTRIB [+R | -R] [+A | -A ] [+S | -S] [+H | -H] [drive:][path][filename]
       [/S [/D]]

  +   Sets an attribute.
  -   Clears an attribute.
  R   Read-only file attribute.
  A   Archive file attribute.
  S   System file attribute.
  H   Hidden file attribute.
  [drive:][path][filename]
      Specifies a file or files for attrib to process.
  /S  Processes matching files in the current folder
      and all subfolders.
  /D  Processes folders as well.

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接