forked from brave/brave-core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for upstream presubmit logic on npm run lint.
- Loading branch information
Showing
16 changed files
with
389 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Copyright (c) 2022 The Brave Authors. All rights reserved. | ||
# This Source Code Form is subject to the terms of the Mozilla Public | ||
# License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
# You can obtain one at http://mozilla.org/MPL/2.0/. */ | ||
|
||
USE_PYTHON3 = True | ||
PRESUBMIT_VERSION = '2.0.0' | ||
|
||
|
||
def CheckChangeLintsClean(input_api, output_api): | ||
return input_api.canned_checks.CheckChangeLintsClean(input_api, output_api) | ||
|
||
|
||
def CheckPylint(input_api, output_api): | ||
return input_api.canned_checks.RunPylint(input_api, | ||
output_api, | ||
version='2.7') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
# This file is used by git-cl to get repository specific information. | ||
GERRIT_HOST: True | ||
|
||
# Don't add GERRIT_HOST, it will make PRESUBMIT checks do unnecessary stuff. | ||
# CODE_REVIEW_SERVER is a mock value to not generate errors during PRESUBMIT. | ||
CODE_REVIEW_SERVER: github.com | ||
|
||
LINT_IGNORE_REGEX: win_build_output/midl/google_update/.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
This file allows src/PRESUBMIT.py to be executed on brave/* files. | ||
See presubmit_support.py for details. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
diff --git a/PRESUBMIT.py b/PRESUBMIT.py | ||
index 81b1b62c3ef84dedaba01ef067bafc66d9ebfbb4..7e4fb471f68b60b23b03603902f33fb0e90ca204 100644 | ||
--- a/PRESUBMIT.py | ||
+++ b/PRESUBMIT.py | ||
@@ -5845,3 +5845,4 @@ def CheckPythonShebang(input_api, output_api): | ||
"Please use '#!/usr/bin/env python/2/3' as the shebang of %s" % | ||
file)) | ||
return result | ||
+if not globals().get('__name__'): from lib.import_inline import inline_module; inline_module('chromium_presubmit_overrides', globals(), locals()) |
Oops, something went wrong.