Built files ("./dist") in version-control
See original GitHub issueBuilt files are useless redundant noise in the git diff (a lot of it if you can never commit them), and generally make using Git more difficult for everyone
Listing them in the .gitignore does not have any effect because it does not make any sense; garbage in, garbage out.
Built files have no place in version-control (aka source-control, as in source, not build-control).
Package managers are our build-control; they are what we use to distribute/share build-code.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:2
- Comments:20 (18 by maintainers)
Top Results From Across the Web
vue: is it right to track dist files? - Stack Overflow
When I develop vue project, I keep track of files in dist folder. My laptop. I develop vue project -> npm(yarn) run build...
Read more >dist folder not uploaded · Issue #43 · SamKirkland/FTP-Deploy ...
Bug Description I want to use this action for uploading the resulting folder of npm run build which is a dist folder in...
Read more >Don't keep generated files in version control - Perl Maven
This generated file should not be kept in version control, nor should it be included in the distribution. .tidyall.d/ is a directory created ......
Read more >Dist (automake) - GNU.org
For the most part, the files to distribute are automatically found by Automake: all source files are automatically included in a distribution, as...
Read more >Do I include my dist folder when I upload to my github repo?
Binary files (e.g. executables) are not suited to version control. But Github has "releases" so you can tag a commit and upload the...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

t4t5/sweetalert#748 does not apply to this repo, since our unobfuscated dist files are freely accessible on the npm package distribution registry (that is where unpkg.com gets packages from), unlike @t4t5’s sweetalert which only publishes the minfied/obfuscated dist files. Removing files from source-control does not mean they are removed from the package distribution.
Our distribution files are already perfectly accessible for all users and their workflows, minified or unminified, on the condition that the correct dist files are always present when you
npm publishoryarn publish. (You should guard against human error regarding that condition, by running the build automatically before publishing, viascripts.prepublishin package.json)(edit: Correction: If we removed the dist from Git, the Bower workflow would not supported anymore. Thanks for making this point @toverux)
I think/hope I made it clear that something that could use improvement is this package’s internal workflow. I would not complain, but like I said on t4t5/sweetalert#748…
We can easily match that exactly.
Isn’t bower downloading directly from GitHub? In this case, the users wouldn’t have the minified versions. What about the CDNs?
Publishing build artifacts on Git was common before npm. It is also seeked by users who don’t use a package manager and just click on “Download ZIP” (been there). I hate dist/ files too and you can see that all my JS repos are exempt from that, but they are targeting Angular or Node, where people always use npm. Dist files regularly cause pain here and require more work. But that’s still a common distribution system for this type of frontend libraries.
I’m not against removing them from Git because it’s just better for us and our users, but I’m worried this will impact some of them, as well as (if I’m right) the Bower/CDN distributions. It’s not just a “
chore(package)” change in our package.json.