Build: Fix pre release matching in compare size regex
[jquery.git] / .release-it.cjs
blobff55b0ef187f68a2aa5f2fc95d85f299ad39e9ef
1 "use strict";
3 const blogURL = process.env.BLOG_URL;
5 if ( !blogURL || !blogURL.startsWith( "https://blog.jquery.com/" ) ) {
6         throw new Error( "A valid BLOG_URL must be set in the environment" );
9 module.exports = {
10         preReleaseBase: 1,
11         hooks: {
12                 "before:init": "bash ./build/release/pre-release.sh",
13                 "after:version:bump":
14                         "sed -i 's/main\\/AUTHORS.txt/${version}\\/AUTHORS.txt/' package.json",
15                 "after:bump": "cross-env VERSION=${version} npm run build:all",
16                 "before:git:release": "git add -f dist/ dist-module/ changelog.md",
17                 "after:release": "echo 'Run the following to complete the release:' && " +
18                         `echo './build/release/post-release.sh $\{version} ${ blogURL }'`
19         },
20         git: {
22                 // Use the node script directly to avoid an npm script
23                 // command log entry in the GH release notes
24                 changelog: "node build/release/changelog.js ${from} ${to}",
25                 commitMessage: "Release: ${version}",
26                 getLatestTagFromAllRefs: true,
27                 pushRepo: "git@github.com:jquery/jquery.git",
28                 requireBranch: "main",
29                 requireCleanWorkingDir: true
30         },
31         github: {
32                 pushRepo: "git@github.com:jquery/jquery.git",
33                 release: true,
34                 tokenRef: "JQUERY_GITHUB_TOKEN"
35         },
36         npm: {
37                 publish: true
38         }