Created
April 23, 2020 08:49
-
-
Save matthewhartman/8b79c666d2cd3edd1237e15bfa1e37bc to your computer and use it in GitHub Desktop.
Generate A Unique JS Bundle Name
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
rm -rf ./dist && | |
parcel build src/index.html && | |
VERSION=$(git rev-parse --short HEAD) | |
cp ./dist/src*.js ./dist/$VERSION.js | |
cp ./dist/src*.js ./dist/default.js |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment