command - 为什么 "-n"通常用于试运行?

标签 command naming-conventions conventions

众所周知的命令,如 makersyncgit 使用 -n 选项进行试运行.
-n 在这种情况下代表什么?

最佳答案

我的猜测是因为 dry-run 包含字母 n 并且因为 dr 是已经使用过:

$ make --help | grep '^ *-[dr]'
  -d                          Print lots of debugging information.
  -r, --no-builtin-rules      Disable the built-in implicit rules.
$ rsync --help | grep '^ *-[dr]'
 -r, --recursive             recurse into directories
 -d, --dirs                  transfer directories without recursing

关于command - 为什么 "-n"通常用于试运行?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/64534753/

相关文章:

首先指定哪些标签的 CSS 排序约定

java - Java 约定中的 Getters 和 Setters

scala - 包和项目的命名约定

r - 切片操作避免循环

linux - 如何在 Linux 中创建 shell 命令,如 : hh. sh filename -e -c?

linux - 我们必须在哪里放置 linux 命令?

Node.js 命令提示符;从 Z : instead of C: 开始

python - Powershell 文件路径命令正在被 Pycharm 更改

c++11 - 命名 API 是否意味着内存所有权的转移?

c++ - 合并函数参数的适当命名约定是什么?