Skip to content

Commit

Permalink
chore: cleanup lockfiles
Browse files Browse the repository at this point in the history
- Delete package-lock.json. Bull currently has both yarn.lock and
package-lock.json files. When both are present, TravisCI uses yarn,
so in practice npm has not been used by CI. But the presence of a
package-lock.json file meant that contributors were not sure which
lock file, if any, needed to be updated. Yarn also logs a scary
warning if it detects a package-lock.json file.

- Cache yarn dependencies in TravisCI. This should make CI jobs
somewhat faster.

- Update yarn.lock file and ensure that it remains in sync with
package.json changes by using `--frozen-lockfile`.
  • Loading branch information
gabegorelick committed Nov 8, 2019
1 parent c87e8cc commit 0376356
Show file tree
Hide file tree
Showing 4 changed files with 196 additions and 5,680 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ node_modules
tmp
coverage
*.rdb
.vscode
.vscode
package-lock.json
12 changes: 12 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ language: node_js

sudo: false

cache:
yarn: true

# test on node.js versions
node_js:
- '12'
Expand All @@ -11,6 +14,15 @@ node_js:
services:
- redis-server

before_install:
# Use a specific version of yarn in CI. This ensures yarn.lock format doesn't change.
- curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version 1.19.1
- export PATH="$HOME/.yarn/bin:$PATH"

install:
# ensure unexpected changes to yarn.lock break the build
- yarn install --frozen-lockfile --non-interactive

script:
- npm run prettier -- --list-different
- npm run test
Expand Down
Loading

0 comments on commit 0376356

Please sign in to comment.