replace npm run calls with yarn

This commit is contained in:
Mike Greiling 2017-02-07 16:57:43 -06:00
parent 469bc859ce
commit 8beb5998a8
3 changed files with 5 additions and 5 deletions

View file

@ -107,7 +107,7 @@ setup-test-env:
<<: *dedicated-runner
stage: prepare
script:
- npm install
- yarn install
- bundle exec rake gitlab:assets:compile
- bundle exec ruby -Ispec -e 'require "spec_helper" ; TestEnv.init'
artifacts:
@ -326,7 +326,7 @@ lint:javascript:
stage: test
image: "node:7.1"
script:
- npm --silent run eslint
- yarn run eslint
lint:javascript:report:
<<: *dedicated-runner
@ -337,7 +337,7 @@ lint:javascript:report:
image: "node:7.1"
script:
- find app/ spec/ -name '*.js' -or -name '*.js.es6' -exec sed --in-place 's|/\* eslint-disable .*\*/||' {} \; # run report over all files
- npm --silent run eslint-report || true # ignore exit code
- yarn run eslint-report || true # ignore exit code
artifacts:
name: eslint-report
expire_in: 31d

View file

@ -1,7 +1,7 @@
unless Rails.env.production?
desc "GitLab | Run ESLint"
task :eslint do
system("npm", "run", "eslint")
system("yarn", "run", "eslint")
end
end

View file

@ -11,7 +11,7 @@ unless Rails.env.production?
desc 'GitLab | Karma | Run JavaScript tests'
task :tests do
sh "npm run karma" do |ok, res|
sh "yarn run karma" do |ok, res|
abort('rake karma:tests failed') unless ok
end
end