Browse Source

Add "ninja -t targets" to the command allowlist

It's used here: https://source.chromium.org/chromium/chromium/src/+/main:build/android/list_java_targets.py;drc=911128ac37a470797e6e24251598e4d0f3d3c21c;l=82

Change-Id: I31c687d36393a36b3b7d75b4668720214011aa1f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5527347
Auto-Submit: Andrew Grieve <agrieve@chromium.org>
Commit-Queue: Fumitoshi Ukai <ukai@google.com>
Reviewed-by: Fumitoshi Ukai <ukai@google.com>
Andrew Grieve 1 năm trước cách đây
mục cha
commit
e1385296c4
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      ninja.py

+ 1 - 1
ninja.py

@@ -42,7 +42,7 @@ def checkOutdir(ninja_args):
             out_dir = ninja_args[i + 1]
         elif arg.startswith("-C"):
             out_dir = arg[2:]
-    if tool in ["list", "commands", "inputs"]:
+    if tool in ["list", "commands", "inputs", "targets"]:
         # These tools are just inspect ninja rules and not modify out dir.
         # TODO: b/339320220 - implement these in siso
         return