frintjs/frint

Travis-CI: print gzip sizes of dists after successful builds

Open

#270 opened on Aug 20, 2017

View on GitHub
 (0 comments) (0 reactions) (0 assignees)JavaScript (37 forks)batch import
good first issuehelp wanted

Repository metrics

Stars
 (746 stars)
PR merge metrics
 (No merged PRs in 30d)

Description

Currently

We have a Makefile command like this that shows the minified and gzip sizes of our dists:

$ npm run dist
$ make list-dists
original 	 gzipped 	 file
--- 		 --- 		 ---
15.2K 		 3.4K 		 ./packages/frint-compat/dist/frint-compat.min.js
2.6K 		 1.0K 		 ./packages/frint-model/dist/frint-model.min.js
11.8K 		 2.8K 		 ./packages/frint-react/dist/frint-react.min.js
8.6K 		 2.0K 		 ./packages/frint-router-react/dist/frint-router-react.min.js
25.7K 		 7.7K 		 ./packages/frint-router/dist/frint-router.min.js
6.5K 		 2.2K 		 ./packages/frint-store/dist/frint-store.min.js
11.1K 		 2.9K 		 ./packages/frint/dist/frint.min.js

Print dist sizes on Travis-CI

It would be good for historical reasons, to print this info during Travis-CI builds too via .travis.yml file by adding this:

after_success:
  - '...other commands'
  - 'npm run dist'
  - 'make list-dists'

What needs to be done

It was tried before in #261, but since our make list-dists command uses bc, it didn't work properly on Travis-CI. So a workaround needs to be found for that.

Contributor guide