-
Notifications
You must be signed in to change notification settings - Fork 275
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Need CI/CD setup to build new releases #569
Comments
Take a look at this webpack plugin https://webpack.js.org/plugins/define-plugin/ and this comment webpack/webpack#237 (comment) |
Would it be possible to use... module.exports = function factory() {
var Twig = {
VERSION: require('../package.json').version
}; ? In addition, I'm more than happy to help with maintaining releases. |
@RobLoach I gave some thought to that approach, but the package.json version doesn't increment until the npm version script runs, which is run after the code is bundled, so the version the bundler sees would always be one version behind :( |
@dave-irvine That would fully depend on the flow used while creating a new release. Adding a
Alternatively you could switch around steps 3 and 4, the bundles themselves are not checked into Git, so there should be no difference between the git data before or after the build. |
Yikes, shows how behind I am on npm, I don't think it even had prepare the last time I checked! Thanks @JorgenEvens I'll investigate. |
@dave-irvine Would you like some help with maintaining releases? I'd be willing to help publish this current one if you add me as a maintainer. |
look what I found: https://github.com/semantic-release/semantic-release |
At the moment building and releasing new versions of twig is a real pain.
Step 1) Update changelog.md with a summary of things fixed
Step 2) Change version number in https://github.com/twigjs/twig.js/blob/master/src/twig.factory.js#L6
Step 3) Run
npm run build
Step 4) Run
npm version <major¦minor¦patch>
Step 5) Git push
The biggest immediate issue is Step 2, which requires guessing what the next version is going to be and updating the source. If someone can think of a way to add a version tag to the source that comes from the package.json or something similar that'd be great.
https://github.com/zeit/release might resolve Step 1.
Then we just need to automate Steps 3,4,5.
The text was updated successfully, but these errors were encountered: