内容纲要
语法:mvn [options] [<goal(s)>] [<phase(s)>]
| 选项options | 解释 |
|---|---|
| -am,--also-make | If project list is specified, also build projects required by the list 如果指定了项目列表,也构建列表所需的项目 |
| -amd,--also-make-dependents | If project list is specified, also build projects that depend on projects on the list 如果指定了项目列表,也构建依赖于列表中的项目的项目 |
| -B,--batch-mode | Run in non-interactive (batch) mode 以非交互式(批处理)模式运行 |
| -b,--builder |
The id of the build strategy to use 要使用的构建策略的id |
| -C,--strict-checksums | Fail the build if checksums don't match 如果校验和不匹配,则构建失败 |
| -c,--lax-checksums | Warn if checksums don't match 如果校验和不匹配则发出警告 |
| -cpu,--check-plugin-updates | Ineffective, only kept for backward compatibility 无效,只保留向后兼容 |
| -D,--define |
Define a system property 定义一个系统属性 |
| -e,--errors | Produce execution error messages 产生执行错误消息 |
| -emp,--encrypt-master-password |
Encrypt master security password 加密master 安全密码 |
| -ep,--encrypt-password |
Encrypt server password 加密服务器密码 |
| -f,--file |
Force the use of an alternate POM file (or directory with pom.xml) 强制使用替代POM文件(或带有POM .xml的目录) |
| -fae,--fail-at-end | Only fail the build afterwards; allow all non-impacted builds to continue 只在之后的构建中失败;允许所有不受影响的构建继续进行 |
| -ff,--fail-fast | Stop at first failure in reactorized builds 在经过运行处理构建中,在第一次出现故障时停止 |
| -fn,--fail-never | NEVER fail the build, regardless of project result 无论项目结果如何,永远不要让构建失败 |
| -gs,--global-settings |
Alternate path for the global settings file 全局设置文件的备用路径 |
| -gt,--global-toolchains |
Alternate path for the global toolchains file 全局工具链文件的备用路径 |
| -h,--help | Display help information 显示帮助信息 |
| -l,--log-file |
Log file where all build output will go (disables output color) 所有构建输出的日志文件(禁用输出颜色) |
| -llr,--legacy-local-repository | Use Maven 2 Legacy Local Repository behaviour, ie no use of _remote.repositories. Can also be activated by using -Dmaven.legacyLocalRepo=true 使用Maven 2遗留本地存储库行为,即不使用 _remote.repositories。也可以通过使用 -Dmaven.legacyLocalRepo=true激活 |
| -N,--non-recursive | Do not recurse into sub-projects 不递归到子项目 |
| -npr,--no-plugin-registry | Ineffective, only kept for backward compatibility 无效,只保留向后兼容 |
| -npu,--no-plugin-updates | Ineffective, only kept for backward compatibility 无效,只保留向后兼容 |
| -nsu,--no-snapshot-updates | Suppress SNAPSHOT updates 抑制快照更新 |
| -ntp,--no-transfer-progress | Do not display transfer progress when downloading or uploading 下载或上传时不显示传输进度 |
| -o,--offline | Work offline 离线工作 |
| -P,--activate-profiles |
Comma-delimited list of profiles to activate 要激活的概要文件的逗号分隔列表 |
| -pl,--projects |
Comma-delimited list of specified reactor projects to build instead of all projects. A project can be specified by [groupId]:artifactId or by its relative path以逗号分隔的指定反应堆项目列表,以取代所有项目。项目可以通过 [groupId]:artifactId或其相对路径指定 |
| -q,--quiet | Quiet output - only show errors 安静输出-只显示错误 |
| -rf,--resume-from |
Resume reactor from specified project 从指定项目恢复反应堆 |
| -s,--settings |
Alternate path for the user settings file 用户设置文件的备用路径 |
| -t,--toolchains |
Alternate path for the user toolchains file 用户工具链文件的备用路径 |
| -T,--threads |
Thread count, for instance 2.0C where C is core multiplied 线程数,例如2.0C,其中C是core核心数的乘法 |
| -U,--update-snapshots | Forces a check for missing releases and updated snapshots on remote repositories 强制检查远程存储库上丢失的版本和更新的快照 |
| -up,--update-plugins | Ineffective, only kept for backward compatibility 无效,只保留向后兼容 |
| -v,--version | Display version information 显示版本信息 |
| -V,--show-version | Display version information WITHOUT stopping build 显示版本信息而不停止构建 |
| -X,--debug | Produce execution debug output 产生执行调试输出 |