Skip to content

Commit

Permalink
correct size calculation
Browse files Browse the repository at this point in the history
`yarn pack` does not output the file name like `npm pack` does. Correct this by explictly setting the filename.
  • Loading branch information
andrew-codes committed Jan 15, 2020
1 parent 78af04d commit 59f577e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -573,8 +573,7 @@ jobs:
working_directory: cli/build
- run:
name: list NPM package contents
working_directory: cli/build
command: yarn size
command: yarn lerna run --scope cypress size
- run:
name: pack NPM package
working_directory: cli/build
Expand Down
2 changes: 1 addition & 1 deletion cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"lint": "eslint --fix *.js scripts/*.js bin/* lib/*.js lib/**/*.js test/*.js test/**/*.js",
"prerelease": "yarn build",
"release": "cd build && releaser --no-node --no-changelog",
"size": "t=\"$(yarn pack)\"; wc -c \"${t}\"; tar tvf \"${t}\"; rm \"${t}\";",
"size": "t=\"cypress-v0.0.0.tgz\"; yarn pack --filename \"${t}\"; wc -c \"${t}\"; tar tvf \"${t}\"; rm \"${t}\";",
"test": "yarn test-unit",
"test-debug": "node --inspect --debug-brk $(yarn bin mocha)",
"test-dependencies": "dependency-check . --no-dev",
Expand Down
2 changes: 1 addition & 1 deletion packages/launcher/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"clean": "node scripts/clean.js || true",
"clean-deps": "rm -rf node_modules",
"clean-js": "yarn clean",
"size": "t=\"$(yarn pack)\"; wc -c \"${t}\"; tar tvf \"${t}\"; rm \"${t}\";",
"size": "t=\"cypress-v0.0.0.tgz\"; yarn pack --filename \"${t}\"; wc -c \"cli/${t}\"; tar tvf \"${t}\"; rm \"${t}\";",
"test": "yarn test-unit",
"test-unit": "mocha --reporter mocha-multi-reporters --reporter-options configFile=../../mocha-reporter-config.json"
},
Expand Down

0 comments on commit 59f577e

Please sign in to comment.