chore: add GN linting (#14678)

* chore: add GN linter

* chore: fix GN lint errors

* try some crazy bash to get a gn exe

* base64 on linux is different

* cloning build_tools doesn't download GN

* download_from_google_storage needs depot_tools in the path

* fixup! chore: add GN linter
This commit is contained in:
Jeremy Apthorp 2018-10-03 16:03:26 -07:00 committed by Charles Kerr
parent 5efb0fdff1
commit 14fc6f3081
9 changed files with 88 additions and 45 deletions

View file

@ -17,6 +17,7 @@ config("build_time_executable") {
}
}
}
# For MAS build, we force defining "MAS_BUILD".
config("mas_build") {
if (is_mas_build) {

View file

@ -1,16 +1,22 @@
template("npm_action") {
assert(defined(invoker.script),
"Need script name to run (must be defined in package.json)")
assert(defined(invoker.args),
"Need script argumets")
assert(defined(invoker.args), "Need script argumets")
action(target_name) {
forward_variables_from(invoker, ["deps", "public_deps", "sources", "inputs", "outputs"])
forward_variables_from(invoker,
[
"deps",
"public_deps",
"sources",
"inputs",
"outputs",
])
script = "//electron/build/npm-run.py"
args = [
"--silent",
invoker.script,
"--"
] + invoker.args
"--silent",
invoker.script,
"--",
] + invoker.args
}
}