Upgrade to the new actions API (#65)

In future Bazel releases ctx.file_action will be removed.
ctx.action.write should be used instead.

With this change tests pass even if --incompatible_new_actions_api
is used.

Bazel issue:
https://github.com/bazelbuild/bazel/issues/5825
This commit is contained in:
bttk 2018-11-13 02:22:18 -08:00 committed by Laurent Le Brun
parent 6ad5e286cb
commit 3360231ec0
1 changed files with 2 additions and 2 deletions

View File

@ -166,10 +166,10 @@ def _end(env):
"EOF",
"exit %d" % len(env.failures),
])
env.ctx.file_action(
env.ctx.actions.write(
output = env.ctx.outputs.executable,
content = cmd,
executable = True,
is_executable = True,
)
def _fail(env, msg):