From 50f1fb6fa69ecf7117afd9f8ef873ba20f0c4629 Mon Sep 17 00:00:00 2001 From: qibaoguang Date: Mon, 9 Mar 2015 23:11:17 +0800 Subject: [PATCH] Update 55. Using the CLI.md --- VII. Spring Boot CLI/55. Using the CLI.md | 41 +++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/VII. Spring Boot CLI/55. Using the CLI.md b/VII. Spring Boot CLI/55. Using the CLI.md index e69de29..a58a623 100644 --- a/VII. Spring Boot CLI/55. Using the CLI.md +++ b/VII. Spring Boot CLI/55. Using the CLI.md @@ -0,0 +1,41 @@ +### 55. 使用CLI + +一旦安装好CLI,你可以输入`spring`来运行它。如果你不使用任何参数运行`spring`,将会展现一个简单的帮助界面: +```shell +$ spring +usage: spring [--help] [--version] + [] + +Available commands are: + + run [options] [--] [args] + Run a spring groovy script + + ... more command help is shown here +``` +你可以使用`help`获取任何支持命令的详细信息。例如: +```shell +$ spring help run +spring run - Run a spring groovy script + +usage: spring run [options] [--] [args] + +Option Description +------ ----------- +--autoconfigure [Boolean] Add autoconfigure compiler + transformations (default: true) +--classpath, -cp Additional classpath entries +-e, --edit Open the file with the default system + editor +--no-guess-dependencies Do not attempt to guess dependencies +--no-guess-imports Do not attempt to guess imports +-q, --quiet Quiet logging +-v, --verbose Verbose logging of dependency + resolution +--watch Watch the specified file for changes +``` +`version`命令提供一个检查你正在使用的Spring Boot版本的快速方式: +```shell +$ spring version +Spring CLI v1.3.0.BUILD-SNAPSHOT +```