Spring Boot CLI提供了一个Shell接口来运行命令,可以在其中直接运行命令,如下所示。 转到E:/Test文件夹并键入以下命令 -
E:/Test> spring shell
将会看到以下输出:
?[1mSpring Boot?[m?[2m (v2.0.5.RELEASE)?[m
Hit TAB to complete. Type \'help\' and hit RETURN for help, and \'exit\' to quit.
在Shell中运行命令
输入以下内容并查看输出 -
version
Spring CLI v2.0.5.RELEASE
可以按Tab
键自动完成命令,然后键入exit
以退出shell
控制台。
在shell中测试应用程序
输入以下内容并查看输出 -
E:\Test\FirstApplication>spring shell
?[1mSpring Boot?[m?[2m (v2.0.5.RELEASE)?[m
Hit TAB to complete. Type \'help\' and hit RETURN for help, and \'exit\' to quit.
$ test FirstApplication.groovy TestFirstApplication.groovy
.
Time: 0.347
OK (1 test)
$ exit
E:\Test\FirstApplication>
上一篇:
Spring Boot CLI创建项目
下一篇:无