官术网_书友最值得收藏!

Task name abbreviation

Before we look at more Gradle command-line options, it is good to discuss a real-time save feature of Gradle: task name abbreviation. With task name abbreviation, we don't have to type the complete task name on the command line. We only have to type enough of the name to make it unique within the build.

In our first build, we only have one task, so the gradle h command should work just fine. However, we didn't take the built-in help task into account. So, to uniquely identify our helloWorld task, we use the hello abbreviation:

$ gradle -q hello
Hello world.

We can also abbreviate each word in a CamelCase task name. For example, our helloWorld task name can be abbreviated to hW:

$ gradle -q hW
Hello world.

This feature saves us the time spent in typing the complete task name and can speed up the execution of our tasks.

主站蜘蛛池模板: 镇赉县| 满城县| 香河县| 桐梓县| 梅州市| 东山县| 顺平县| 北流市| 澜沧| 南安市| 石景山区| 武清区| 罗田县| 嘉义市| 广丰县| 庄浪县| 岳池县| 巩留县| 虎林市| 富宁县| 东丰县| 镇江市| 招远市| 广东省| 富源县| 布拖县| 观塘区| 碌曲县| 汝阳县| 洪江市| 大方县| 乌什县| 弋阳县| 衢州市| 樟树市| 大田县| 丰台区| 剑河县| 贵阳市| 广丰县| 竹北市|