2023-07-27 15:24:49 +00:00
|
|
|
"use strict";
|
|
|
|
|
|
|
|
const blogURL = process.env.BLOG_URL;
|
|
|
|
|
|
|
|
if ( !blogURL || !blogURL.startsWith( "https://blog.jquery.com/" ) ) {
|
|
|
|
throw new Error( "A valid BLOG_URL must be set in the environment" );
|
|
|
|
}
|
|
|
|
|
|
|
|
module.exports = {
|
2024-07-12 19:43:41 +00:00
|
|
|
preReleaseBase: 1,
|
2023-07-27 15:24:49 +00:00
|
|
|
hooks: {
|
2024-07-11 16:23:10 +00:00
|
|
|
"before:init": "bash ./build/release/pre-release.sh",
|
2023-07-27 15:24:49 +00:00
|
|
|
"after:version:bump":
|
2024-07-11 16:23:10 +00:00
|
|
|
"sed -i 's/main\\/AUTHORS.txt/${version}\\/AUTHORS.txt/' package.json",
|
2024-07-17 13:32:02 +00:00
|
|
|
"after:bump": "cross-env VERSION=${version} npm run build:all",
|
|
|
|
"before:git:release": "git add -f dist/ dist-module/ changelog.md",
|
2024-07-17 14:13:53 +00:00
|
|
|
"after:release": "echo 'Run the following to complete the release:' && " +
|
|
|
|
`echo './build/release/post-release.sh $\{version} ${ blogURL }'`
|
2023-07-27 15:24:49 +00:00
|
|
|
},
|
|
|
|
git: {
|
2024-07-17 14:13:53 +00:00
|
|
|
|
|
|
|
// Use the node script directly to avoid an npm script
|
|
|
|
// command log entry in the GH release notes
|
|
|
|
changelog: "node build/release/changelog.js ${from} ${to}",
|
2023-07-27 15:24:49 +00:00
|
|
|
commitMessage: "Release: ${version}",
|
|
|
|
getLatestTagFromAllRefs: true,
|
2024-07-17 14:13:53 +00:00
|
|
|
pushRepo: "git@github.com:jquery/jquery.git",
|
2023-07-27 15:24:49 +00:00
|
|
|
requireBranch: "main",
|
|
|
|
requireCleanWorkingDir: true
|
|
|
|
},
|
|
|
|
github: {
|
2024-07-17 14:13:53 +00:00
|
|
|
pushRepo: "git@github.com:jquery/jquery.git",
|
2023-07-27 15:24:49 +00:00
|
|
|
release: true,
|
|
|
|
tokenRef: "JQUERY_GITHUB_TOKEN"
|
|
|
|
},
|
|
|
|
npm: {
|
|
|
|
publish: true
|
|
|
|
}
|
|
|
|
};
|