github-action-benchmark
github-action-benchmark copied to clipboard
Use NCC
I've noticed for your v1
branch you've had to commit the node_modules folder into VC for your js scripts to work.
You can use ncc instead, this will package up everything into a single file, you can then just ship that.
I use it here: https://github.com/jasonwilliams/criterion-compare-action/blob/master/package.json#L8
Thank you for the suggestion but I'm not understanding the benefit to make a single executable for GitHub Action. JavaScript action is assumed to be Node.js module so having multiple sources would be OK. And I already prepared a small script to make release and it works well.
Since GitHub Action is run in virtual environment, it's hard to debug. I want to avoid extra code transforming (e.g. bundling with webpack) as much as possible.
Thank you for the suggestion but I'm not understanding the benefit
I think the main benefit is not having to commit the hundreds of JS files from node_modules into VC.
JavaScript action is assumed to be Node.js module so having multiple sources would be OK. And I already prepared a small script to make release and it works well.
Fair enough
I think the main benefit is not having to commit the hundreds of JS files from node_modules into VC.
How is the difference? Is there any performance regression when using node_modules
directory with bunch of npm packages in your case?
I tried to check size of the v1
branch as follows:
$ git clone --depth=1 --branch v1 https://github.com/rhysd/github-action-benchmark
$ tar cf tmp.tar ./github-action-benchmark
$ ls -lh tmp.tar
and the size was 5.5 MB. I feel it is not so large. So until it is clear that there is a real benefit, I don't think we should not add another transformation like bundling or minifying since it has obvious downside that it introduces additional complexity to release artifacts.
Closing because of no response. Feel free to reopen.