aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/skylarkbuildapi/SkylarkActionFactoryApi.java
diff options
context:
space:
mode:
authorGravatar cparsons <cparsons@google.com>2018-08-15 12:42:12 -0700
committerGravatar Copybara-Service <copybara-piper@google.com>2018-08-15 12:43:53 -0700
commitdc9b3cd9b3105f40a59cee33d4f05dc19fcd13e4 (patch)
tree86a31b8ab656203348bab799763c0962a6fcc6f7 /src/main/java/com/google/devtools/build/lib/skylarkbuildapi/SkylarkActionFactoryApi.java
parentb6c0996f444c5ea273a51cf034519dfa2014d12b (diff)
Throw an EvalException when run_shell is passed both a command string sequence and arguments.
Previously, this resulted in an uncaught UnsupportedOperationException. Closes #5892. RELNOTES: None. PiperOrigin-RevId: 208865301
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/skylarkbuildapi/SkylarkActionFactoryApi.java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/skylarkbuildapi/SkylarkActionFactoryApi.java11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/skylarkbuildapi/SkylarkActionFactoryApi.java b/src/main/java/com/google/devtools/build/lib/skylarkbuildapi/SkylarkActionFactoryApi.java
index 15d940ea74..282890de33 100644
--- a/src/main/java/com/google/devtools/build/lib/skylarkbuildapi/SkylarkActionFactoryApi.java
+++ b/src/main/java/com/google/devtools/build/lib/skylarkbuildapi/SkylarkActionFactoryApi.java
@@ -369,12 +369,11 @@ public interface SkylarkActionFactoryApi extends SkylarkValue {
positional = false,
doc =
"Shell command to execute.<br><br>"
- + "<b>Passing a sequence of strings to this attribute is deprecated and Blaze"
- + "may "
- + "stop accepting such values in the future.</b><br><br>"
- + "The command can access the elements of the <code>arguments</code> object "
- + "via "
- + "<code>$1</code>, <code>$2</code>, etc.<br>"
+ + "<b>Passing a sequence of strings to this attribute is deprecated and Blaze "
+ + "may stop accepting such values in the future.</b> If a sequence of strings "
+ + "is passed, then <code>arguments</code> must not be used.<br><br> "
+ + "The command string can access the elements of the <code>arguments</code> "
+ + "object via <code>$1</code>, <code>$2</code>, etc.<br> "
+ "When this argument is a string, it must be a valid shell command. For "
+ "example: "
+ "\"<code>echo foo > $1</code>\". Blaze uses the same shell to execute the "