Граф коммитов

23 Коммитов

Автор SHA1 Сообщение Дата
Patrick Brosset 406297be5c Bug 1248360 - Set eslint version to 1.10.3 when setting it up via mach
MozReview-Commit-ID: LmKsvGzj3fo

--HG--
extra : rebase_source : ec5aaeef13fca603250d5e57b8425ff339136070
2016-02-16 10:01:11 +01:00
Dave Townsend 06f432d221 Bug 1239139: Verify that a high enough node version is available before running eslint. r=gps
The most common issue I'm hearing with eslint is people who have an outdated
node installed. This does a quick check to verify the version is high enough
before linting.

MozReview-Commit-ID: Em0jn18OUYo

--HG--
extra : rebase_source : 5325eb5f556f93e09d48fb123e0abb625aa77b84
2016-02-09 15:34:37 -08:00
Kris Maglione 8d948cbdfc Bug 1230776: Support scripts from HTML files in eslint. r=gps
Also removes related unused variables in mach_commands.py.

--HG--
extra : commitid : IiDVMuEZtA5
extra : rebase_source : 575a51dd0ad5450323b4da5f441f8e5d721e41d6
2015-12-05 13:17:49 -08:00
Felipe Gomes 4680ffb080 Bug 1231720 - Log when ESLint finishes running. r=nalexander
--HG--
extra : commitid : 5u08LIBan4s
2015-12-10 14:31:14 -05:00
Dave Townsend 9ee8a4af74 Bug 1230300: Fix mach eslint to pass command arguments through to eslint. r=gps
Currently mach treats the first argument to eslint as the path and moves it to
the end of the arguments but this breaks usage like "mach eslint -f json browser".

It used to be necessary to change to the directory you wanted to lint but now
the .eslintignore is at the top level we just run from the top level. This means
the path argument doesn't need to be special anymore.

--HG--
extra : commitid : 5ozct0pVSC4
extra : rebase_source : 22132a240d8e6f4d099dbcdeb793958d7173e154
extra : amend_source : 2b9931b4283e1c84f699027e13eccc33fcdec978
2015-12-03 10:38:29 -08:00
Dave Townsend e966ac1914 Bug 1229858: Add a preprocessor to convert XBL into JavaScript blocks for eslint. r=miker
--HG--
extra : commitid : KBrnZcg3l6i
extra : rebase_source : 0b961d96d021923d7ef2855367549b3aa2a077da
extra : amend_source : 7f403c59c018656bcff98e7fc2996bfbb9b853d3
2015-12-02 17:03:33 -08:00
Jared Wein d118134fda Bug 1229154 - Launch 'eslint' with UNIX environment since 'eslint' is not a valid Win32 binary. r=gps
--HG--
extra : rebase_source : a738aa832da24531c47a72632ecef8c729601966
2015-12-01 14:29:47 -05:00
Dave Townsend 3593419254 Bug 1228628: Move all eslintignore rules to the top-level of the tree. r=mconley
--HG--
extra : commitid : Dwq9c2G0xAV
extra : rebase_source : 29ef8c7dad0b0477933d82ea87fd157607cc7b14
extra : amend_source : f0353d9eab87d940d29377401b60606153644985
2015-11-27 09:39:59 -08:00
Michael Ratcliffe fc66d30a75 Bug 1212047 - Improve ESLint logging in case of error r=glandium
Fix *all* return codes

--HG--
extra : transplant_source : %DEp0%92%E4%9E%8E1%17%B0%D4%AE%2C%C0%C0%04%7DBd%AE
2015-10-23 17:18:45 +01:00
Michael Ratcliffe 59b814892b Bug 1211223 - Error running eslint setup on Windows r=mh+mozilla, r=pbro
--HG--
extra : commitid : VCSW7YjYq1
extra : rebase_source : 619bf85751c2f9281c897d958893c62360d4fd37
2015-10-23 14:36:24 +01:00
Michael Ratcliffe 3efb3a9e6f Bug 1203520 - We need a DevTools ESLint plugin containing our ruleset r=gps
--HG--
extra : commitid : FrMOnVBUxmY
extra : rebase_source : c38511e94177f651a0decad41180991c54cb0f33
2015-09-30 14:44:48 +01:00
Nick Alexander 159cd7e187 Bug 1177933 - Add |mach eslint| command. r=mcomella,dmose
DONTBUILD NPOTB

--HG--
extra : commitid : IkJltHjrNkD
extra : rebase_source : 93b215c71160013c41fc447ff8eea16f670833cf
extra : histedit_source : 73c8204c8aa208b5ed7739b2f7064a110d6f5982%2Cf5cb35fa8eeea8c6443f96b3940df32c2e5fb826
2015-07-02 12:18:52 -07:00
Gregory Szorc 0fd4fce9ae Bug 1176642 - Defer import of glob; r=glandium
This was the only import of glob from all mach_commands.py files. Kill
it.

With this commit, there are no modules imported by a single
mach_commands.py outside of testing/web-platform/mach_commands.py.

--HG--
extra : commitid : 4CJqlwDqOVg
extra : rebase_source : 9dbbd69291d64b894a399523864562107c10872e
2015-06-25 12:11:55 -07:00
Gregory Szorc 3e949ee8fe Bug 1176642 - Use absolute_import in mach_commands.py files; r=glandium
This removes ambiguity as to which modules are being imported, making
import slightly faster as Python doesn't need to test so many
directories for file presence.

All files should already be using absolute imports because mach command
modules aren't imported to the package they belong to: they instead
belong to the "mach" package. So relative imports shouldn't have been
used.

--HG--
extra : commitid : 6tFME1KKfTD
extra : rebase_source : 78728f82f5487281620e00c2a8004cd5e1968087
2015-06-21 17:39:09 -07:00
Gregory Szorc a19bee3a08 Bug 1176642 - Remove unused imports; r=glandium
--HG--
extra : commitid : IZ7JkH4GKW4
extra : rebase_source : 4c3301c5c353be8afed407df4a003a9cac4583e8
2015-06-25 12:16:38 -07:00
Mike Hommey 525ae5030d Bug 1147283 - Replace mozpack.path with mozpath. r=mshal
Back when mozpack.path was added, it was used as:

  import mozpack.path
  mozpack.path.func()

Nowadays, the common idiom is:

  import mozpack.path as mozpath
  mozpath.func()

because it's shorter.

$ git grep mozpath\\. | wc -l
423
$ git grep mozpack.path\\. | wc -l
123

This change was done with:
$ git grep -l mozpack.path\\. | xargs sed -i 's/mozpack\.path\./mozpath./g'
$ git grep -l 'import mozpack.path$' | xargs sed -i 's/import mozpack.path$/\0 as mozpath/'
$ (pat='import mozpack.path as mozpath'; git grep -l "$pat" | xargs sed -i "1,/$pat/b;/$pat/d")
2015-03-27 08:13:16 +09:00
Mike Hommey 417a2977b3 Bug 1076649 - Remove the '+' prefixing from mach commands with allow_all_arguments=True. r=gps
The reason to use '+' prefixing was to distinguish between options to the
mach command itself, and options that are passed down to whatever the
command does (like mach run passing down args to the built application).
That makes things unnecessarily awkward, and quite non-standard.

Instead, use standard '-' prefixing, and pass all the unknown arguments
down. If there is overlap between the known arguments and arguments supported
by the underlying tool (like -remote when using mach run), it is possible to
use '--' to mark all following arguments as being targetted at the underlying
tool.

For instance:
    mach run -- -remote something
would run
    firefox -remote something
while
    mach run -remote something
would run
    firefox something

As allow_all_arguments is redundant with the presence of a argparse.REMAINDER
CommandArgument, allow_all_arguments is removed. The only mach command with a
argparse.REMAINDER CommandArgument without allow_all_arguments was "mach dmd",
and it did so because it didn't want to use '+' prefixes.
2014-10-07 07:36:27 +09:00
Nathan Froyd 4db6e0c4ea Bug 1062518 - ensure that |mach python-test| considers $PWD when finding tests; r=mshal 2014-09-15 13:25:41 -04:00
Nathan Froyd 77b3f5251c Bug 1056862 - make |mach python-test| work even if run from outside the srcdir; r=gps
DONTBUILD because NPOTB
2014-08-21 11:03:26 -04:00
Gregory Szorc fce7b45cdf Bug 952280 - mach python commands now use virtualenv APIs; r=mshal
The Python-related mach commands were written before we had a virtualenv
API exposed to the mach command context. This patch updates those
commands to use the newer APIs. As a bonus, these commands now work
without running configure!

--HG--
extra : rebase_source : ea394d6fc0c5fa2d3a3a6ed25fc59ce6be40690c
extra : amend_source : e841d57a2578c93b778ef73c68c35a8cc7cfde44
2013-12-19 13:48:37 -08:00
Mike Hommey 5cdc0fbec2 Bug 905490 - Avoid "mach python" logging the python command. r=gps 2013-08-15 23:45:09 +09:00
Matt Brubeck ac0a131eac Bug 899695 - Fix exception in "mach python" on Windows [r=gps]
DONTBUILD (not part of the build)
2013-08-08 08:06:02 -07:00
Nick Alexander 7a82c120fd Bug 818744 - mach commands to run Python and Python unit tests. r=gps
DONTBUILD because NPOTB
2013-07-02 17:33:48 -07:00