aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorGravatar Googler <noreply@google.com>2018-06-21 13:17:40 -0700
committerGravatar Copybara-Service <copybara-piper@google.com>2018-06-21 13:18:59 -0700
commit8b73f8d5bcf9d23e44ac5c4a7d6f51247013c232 (patch)
tree2a38cdc9b0e00c3110475e945097baa37a3a6afa /src
parent9c1399e20c96988639d28850898f959abac9d248 (diff)
Remove deprecated flag "skylark_incremental_res" from mobile-install command.
RELNOTES[INC]: The mobile-install --skylark_incremental_res flag is no longer available, use the --skylark flag instead. PiperOrigin-RevId: 201574876
Diffstat (limited to 'src')
-rw-r--r--src/main/java/com/google/devtools/build/lib/runtime/mobileinstall/MobileInstallCommand.java34
1 files changed, 5 insertions, 29 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/runtime/mobileinstall/MobileInstallCommand.java b/src/main/java/com/google/devtools/build/lib/runtime/mobileinstall/MobileInstallCommand.java
index c65b401c12..e5a3329a80 100644
--- a/src/main/java/com/google/devtools/build/lib/runtime/mobileinstall/MobileInstallCommand.java
+++ b/src/main/java/com/google/devtools/build/lib/runtime/mobileinstall/MobileInstallCommand.java
@@ -72,29 +72,7 @@ public class MobileInstallCommand implements BlazeCommand {
/**
* An enumeration of all the modes that mobile-install supports.
*/
- public enum Mode {
- CLASSIC("classic", null),
- CLASSIC_INTERNAL_TEST("classic_internal_test_DO_NOT_USE", null),
- SKYLARK("skylark", "MIASPECT"),
- SKYLARK_INCREMENTAL_RES("skylark_incremental_res", "MIRESASPECT");
-
- private final String mode;
- private final String aspectName;
-
- Mode(String mode, String aspectName) {
- this.mode = mode;
- this.aspectName = aspectName;
- }
-
- public String getAspectName() {
- return aspectName;
- }
-
- @Override
- public String toString() {
- return mode;
- }
- }
+ public enum Mode { CLASSIC, CLASSIC_INTERNAL_TEST_DO_NOT_USE, SKYLARK }
/**
* Converter for the --mode option.
@@ -144,9 +122,7 @@ public class MobileInstallCommand implements BlazeCommand {
help =
"Select how to run mobile-install. \"classic\" runs the current version of "
+ "mobile-install. \"skylark\" uses the new skylark version, which has support for "
- + "android_test. \"skylark_incremental_res\" is the same as \"skylark\" plus "
- + "incremental resource processing. \"skylark_incremental_res\" requires a device "
- + "with root access."
+ + "android_test."
)
public Mode mode;
@@ -170,7 +146,7 @@ public class MobileInstallCommand implements BlazeCommand {
WriteAdbArgsAction.Options adbOptions = options.getOptions(WriteAdbArgsAction.Options.class);
if (mobileInstallOptions.mode == Mode.CLASSIC
- || mobileInstallOptions.mode == Mode.CLASSIC_INTERNAL_TEST) {
+ || mobileInstallOptions.mode == Mode.CLASSIC_INTERNAL_TEST_DO_NOT_USE) {
// Notify internal users that classic mode is no longer supported.
if (mobileInstallOptions.mode == Mode.CLASSIC
&& !mobileInstallOptions.mobileInstallAspect.startsWith("@")) {
@@ -325,7 +301,7 @@ public class MobileInstallCommand implements BlazeCommand {
public void editOptions(OptionsParser optionsParser) {
Options options = optionsParser.getOptions(Options.class);
try {
- if (options.mode == Mode.CLASSIC || options.mode == Mode.CLASSIC_INTERNAL_TEST) {
+ if (options.mode == Mode.CLASSIC || options.mode == Mode.CLASSIC_INTERNAL_TEST_DO_NOT_USE) {
String outputGroup =
options.splitApks
? "mobile_install_split" + INTERNAL_SUFFIX
@@ -341,7 +317,7 @@ public class MobileInstallCommand implements BlazeCommand {
PriorityCategory.COMMAND_LINE,
"Options required by the skylark implementation of mobile-install command",
ImmutableList.of(
- "--aspects=" + options.mobileInstallAspect + "%" + options.mode.getAspectName(),
+ "--aspects=" + options.mobileInstallAspect + "%MIASPECT",
"--output_groups=android_incremental_deploy_info",
"--output_groups=mobile_install" + INTERNAL_SUFFIX,
"--output_groups=mobile_install_launcher" + INTERNAL_SUFFIX));