From ede263ca8c357ebba4718775ed2609b4c58dfae0 Mon Sep 17 00:00:00 2001 From: Suraj Shetty <13928957+surajshetty3416@users.noreply.github.com> Date: Thu, 16 Apr 2020 19:06:45 +0530 Subject: [PATCH] chore(linter): Skip only first argument --- .github/frappe_linter/translation.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/frappe_linter/translation.py b/.github/frappe_linter/translation.py index 63c4821775..bb81e848f1 100644 --- a/.github/frappe_linter/translation.py +++ b/.github/frappe_linter/translation.py @@ -5,8 +5,8 @@ errors_encounter = 0 pattern = re.compile(r"_\(([\"']{,3})(?P((?!\1).)*)\1(\s*,\s*context\s*=\s*([\"'])(?P((?!\5).)*)\5)*(\s*,\s*(.)*?\s*(,\s*([\"'])(?P((?!\11).)*)\11)*)*\)") start_pattern = re.compile(r"_{1,2}\([\"']{1,3}") -# skip first 2 arguments -files = sys.argv[2:] +# skip first argument +files = sys.argv[1:] for _file in files: if not _file.endswith(('.py', '.js')): continue