mirror of
https://github.com/joaquinjsb/gitea-release-please-action
synced 2026-05-12 10:11:35 +02:00
committed by
GitHub
parent
9963ea2aa8
commit
e6d565feb2
50
dist/commit.hbs
vendored
50
dist/commit.hbs
vendored
@@ -1,23 +1,16 @@
|
|||||||
* {{header}}
|
*{{#if scope}} **{{scope}}:**
|
||||||
|
{{~/if}} {{#if subject}}
|
||||||
{{~!-- commit link --}} {{#if @root.linkReferences~}}
|
{{~subject}}
|
||||||
([{{hash}}](
|
|
||||||
{{~#if @root.repository}}
|
|
||||||
{{~#if @root.host}}
|
|
||||||
{{~@root.host}}/
|
|
||||||
{{~/if}}
|
|
||||||
{{~#if @root.owner}}
|
|
||||||
{{~@root.owner}}/
|
|
||||||
{{~/if}}
|
|
||||||
{{~@root.repository}}
|
|
||||||
{{~else}}
|
|
||||||
{{~@root.repoUrl}}
|
|
||||||
{{~/if}}/
|
|
||||||
{{~@root.commit}}/{{hash}}))
|
|
||||||
{{~else}}
|
{{~else}}
|
||||||
{{~hash}}
|
{{~header}}
|
||||||
{{~/if}}
|
{{~/if}}
|
||||||
|
|
||||||
|
{{~!-- commit link --}}{{~#if hash}} {{#if @root.linkReferences~}}
|
||||||
|
([{{shortHash}}]({{commitUrlFormat}}))
|
||||||
|
{{~else}}
|
||||||
|
{{~shortHash}}
|
||||||
|
{{~/if}}{{~/if}}
|
||||||
|
|
||||||
{{~!-- commit references --}}
|
{{~!-- commit references --}}
|
||||||
{{~#if references~}}
|
{{~#if references~}}
|
||||||
, closes
|
, closes
|
||||||
@@ -26,31 +19,12 @@
|
|||||||
{{~#if this.owner}}
|
{{~#if this.owner}}
|
||||||
{{~this.owner}}/
|
{{~this.owner}}/
|
||||||
{{~/if}}
|
{{~/if}}
|
||||||
{{~this.repository}}#{{this.issue}}](
|
{{~this.repository}}{{this.prefix}}{{this.issue}}]({{issueUrlFormat}})
|
||||||
{{~#if @root.repository}}
|
|
||||||
{{~#if @root.host}}
|
|
||||||
{{~@root.host}}/
|
|
||||||
{{~/if}}
|
|
||||||
{{~#if this.repository}}
|
|
||||||
{{~#if this.owner}}
|
|
||||||
{{~this.owner}}/
|
|
||||||
{{~/if}}
|
|
||||||
{{~this.repository}}
|
|
||||||
{{~else}}
|
|
||||||
{{~#if @root.owner}}
|
|
||||||
{{~@root.owner}}/
|
|
||||||
{{~/if}}
|
|
||||||
{{~@root.repository}}
|
|
||||||
{{~/if}}
|
|
||||||
{{~else}}
|
|
||||||
{{~@root.repoUrl}}
|
|
||||||
{{~/if}}/
|
|
||||||
{{~@root.issue}}/{{this.issue}})
|
|
||||||
{{~else}}
|
{{~else}}
|
||||||
{{~#if this.owner}}
|
{{~#if this.owner}}
|
||||||
{{~this.owner}}/
|
{{~this.owner}}/
|
||||||
{{~/if}}
|
{{~/if}}
|
||||||
{{~this.repository}}#{{this.issue}}
|
{{~this.repository}}{{this.prefix}}{{this.issue}}
|
||||||
{{~/if}}{{/each}}
|
{{~/if}}{{/each}}
|
||||||
{{~/if}}
|
{{~/if}}
|
||||||
|
|
||||||
|
|||||||
50
dist/commit1.hbs
vendored
50
dist/commit1.hbs
vendored
@@ -1,15 +1,22 @@
|
|||||||
*{{#if scope}} **{{scope}}:**
|
* {{header}}
|
||||||
{{~/if}} {{#if subject}}
|
|
||||||
{{~subject}}
|
|
||||||
{{~else}}
|
|
||||||
{{~header}}
|
|
||||||
{{~/if}}
|
|
||||||
|
|
||||||
{{~!-- commit link --}}{{~#if hash}} {{#if @root.linkReferences~}}
|
{{~!-- commit link --}} {{#if @root.linkReferences~}}
|
||||||
([{{shortHash}}]({{commitUrlFormat}}))
|
([{{hash}}](
|
||||||
|
{{~#if @root.repository}}
|
||||||
|
{{~#if @root.host}}
|
||||||
|
{{~@root.host}}/
|
||||||
|
{{~/if}}
|
||||||
|
{{~#if @root.owner}}
|
||||||
|
{{~@root.owner}}/
|
||||||
|
{{~/if}}
|
||||||
|
{{~@root.repository}}
|
||||||
|
{{~else}}
|
||||||
|
{{~@root.repoUrl}}
|
||||||
|
{{~/if}}/
|
||||||
|
{{~@root.commit}}/{{hash}}))
|
||||||
{{~else}}
|
{{~else}}
|
||||||
{{~shortHash}}
|
{{~hash}}
|
||||||
{{~/if}}{{~/if}}
|
{{~/if}}
|
||||||
|
|
||||||
{{~!-- commit references --}}
|
{{~!-- commit references --}}
|
||||||
{{~#if references~}}
|
{{~#if references~}}
|
||||||
@@ -19,12 +26,31 @@
|
|||||||
{{~#if this.owner}}
|
{{~#if this.owner}}
|
||||||
{{~this.owner}}/
|
{{~this.owner}}/
|
||||||
{{~/if}}
|
{{~/if}}
|
||||||
{{~this.repository}}{{this.prefix}}{{this.issue}}]({{issueUrlFormat}})
|
{{~this.repository}}#{{this.issue}}](
|
||||||
|
{{~#if @root.repository}}
|
||||||
|
{{~#if @root.host}}
|
||||||
|
{{~@root.host}}/
|
||||||
|
{{~/if}}
|
||||||
|
{{~#if this.repository}}
|
||||||
|
{{~#if this.owner}}
|
||||||
|
{{~this.owner}}/
|
||||||
|
{{~/if}}
|
||||||
|
{{~this.repository}}
|
||||||
|
{{~else}}
|
||||||
|
{{~#if @root.owner}}
|
||||||
|
{{~@root.owner}}/
|
||||||
|
{{~/if}}
|
||||||
|
{{~@root.repository}}
|
||||||
|
{{~/if}}
|
||||||
|
{{~else}}
|
||||||
|
{{~@root.repoUrl}}
|
||||||
|
{{~/if}}/
|
||||||
|
{{~@root.issue}}/{{this.issue}})
|
||||||
{{~else}}
|
{{~else}}
|
||||||
{{~#if this.owner}}
|
{{~#if this.owner}}
|
||||||
{{~this.owner}}/
|
{{~this.owner}}/
|
||||||
{{~/if}}
|
{{~/if}}
|
||||||
{{~this.repository}}{{this.prefix}}{{this.issue}}
|
{{~this.repository}}#{{this.issue}}
|
||||||
{{~/if}}{{/each}}
|
{{~/if}}{{/each}}
|
||||||
{{~/if}}
|
{{~/if}}
|
||||||
|
|
||||||
|
|||||||
10
dist/footer.hbs
vendored
10
dist/footer.hbs
vendored
@@ -1,10 +0,0 @@
|
|||||||
{{#if noteGroups}}
|
|
||||||
{{#each noteGroups}}
|
|
||||||
|
|
||||||
### {{title}}
|
|
||||||
|
|
||||||
{{#each notes}}
|
|
||||||
* {{text}}
|
|
||||||
{{/each}}
|
|
||||||
{{/each}}
|
|
||||||
{{/if}}
|
|
||||||
|
|||||||
10
dist/footer1.hbs
vendored
10
dist/footer1.hbs
vendored
@@ -0,0 +1,10 @@
|
|||||||
|
{{#if noteGroups}}
|
||||||
|
{{#each noteGroups}}
|
||||||
|
|
||||||
|
### {{title}}
|
||||||
|
|
||||||
|
{{#each notes}}
|
||||||
|
* {{text}}
|
||||||
|
{{/each}}
|
||||||
|
{{/each}}
|
||||||
|
{{/if}}
|
||||||
|
|||||||
18
dist/header.hbs
vendored
18
dist/header.hbs
vendored
@@ -1,9 +1,9 @@
|
|||||||
## {{#if isPatch~}} <small>
|
## {{#if @root.linkCompare~}}
|
||||||
{{~/if~}} {{version}}
|
[{{version}}]({{compareUrlFormat}})
|
||||||
{{~#if title}} "{{title}}"
|
{{~else}}
|
||||||
{{~/if~}}
|
{{~version}}
|
||||||
{{~#if date}} ({{date}})
|
{{~/if}}
|
||||||
{{~/if~}}
|
{{~#if title}} "{{title}}"
|
||||||
{{~#if isPatch~}} </small>
|
{{~/if}}
|
||||||
{{~/if}}
|
{{~#if date}} ({{date}})
|
||||||
|
{{/if}}
|
||||||
|
|||||||
18
dist/header1.hbs
vendored
18
dist/header1.hbs
vendored
@@ -1,9 +1,9 @@
|
|||||||
## {{#if @root.linkCompare~}}
|
## {{#if isPatch~}} <small>
|
||||||
[{{version}}]({{compareUrlFormat}})
|
{{~/if~}} {{version}}
|
||||||
{{~else}}
|
{{~#if title}} "{{title}}"
|
||||||
{{~version}}
|
{{~/if~}}
|
||||||
{{~/if}}
|
{{~#if date}} ({{date}})
|
||||||
{{~#if title}} "{{title}}"
|
{{~/if~}}
|
||||||
{{~/if}}
|
{{~#if isPatch~}} </small>
|
||||||
{{~#if date}} ({{date}})
|
{{~/if}}
|
||||||
{{/if}}
|
|
||||||
|
|||||||
37
dist/index.js
vendored
37
dist/index.js
vendored
@@ -148,6 +148,7 @@ async function manifestInstance (github) {
|
|||||||
const versionFile = core.getInput('version-file') || undefined
|
const versionFile = core.getInput('version-file') || undefined
|
||||||
const extraFiles = core.getMultilineInput('extra-files') || undefined
|
const extraFiles = core.getMultilineInput('extra-files') || undefined
|
||||||
const pullRequestTitlePattern = core.getInput('pull-request-title-pattern') || undefined
|
const pullRequestTitlePattern = core.getInput('pull-request-title-pattern') || undefined
|
||||||
|
const pullRequestHeader = core.getInput('pull-request-header') || undefined
|
||||||
const draft = getOptionalBooleanInput('draft')
|
const draft = getOptionalBooleanInput('draft')
|
||||||
const draftPullRequest = getOptionalBooleanInput('draft-pull-request')
|
const draftPullRequest = getOptionalBooleanInput('draft-pull-request')
|
||||||
const changelogType = core.getInput('changelog-notes-type') || undefined
|
const changelogType = core.getInput('changelog-notes-type') || undefined
|
||||||
@@ -186,6 +187,7 @@ async function manifestInstance (github) {
|
|||||||
extraFiles,
|
extraFiles,
|
||||||
includeComponentInTag: monorepoTags,
|
includeComponentInTag: monorepoTags,
|
||||||
pullRequestTitlePattern,
|
pullRequestTitlePattern,
|
||||||
|
pullRequestHeader,
|
||||||
draftPullRequest,
|
draftPullRequest,
|
||||||
versioning,
|
versioning,
|
||||||
releaseAs,
|
releaseAs,
|
||||||
@@ -24766,10 +24768,10 @@ module.exports = function (config) {
|
|||||||
})
|
})
|
||||||
|
|
||||||
return Q.all([
|
return Q.all([
|
||||||
readFile(__nccwpck_require__.ab + "template1.hbs", 'utf-8'),
|
readFile(__nccwpck_require__.ab + "template.hbs", 'utf-8'),
|
||||||
readFile(__nccwpck_require__.ab + "header1.hbs", 'utf-8'),
|
readFile(__nccwpck_require__.ab + "header.hbs", 'utf-8'),
|
||||||
readFile(__nccwpck_require__.ab + "commit1.hbs", 'utf-8'),
|
readFile(__nccwpck_require__.ab + "commit.hbs", 'utf-8'),
|
||||||
readFile(__nccwpck_require__.ab + "footer1.hbs", 'utf-8')
|
readFile(__nccwpck_require__.ab + "footer.hbs", 'utf-8')
|
||||||
])
|
])
|
||||||
.spread((template, header, commit, footer) => {
|
.spread((template, header, commit, footer) => {
|
||||||
const writerOpts = getWriterOpts(config)
|
const writerOpts = getWriterOpts(config)
|
||||||
@@ -24988,10 +24990,10 @@ function conventionalChangelogWriterInit (context, options) {
|
|||||||
includeDetails: false,
|
includeDetails: false,
|
||||||
ignoreReverted: true,
|
ignoreReverted: true,
|
||||||
doFlush: true,
|
doFlush: true,
|
||||||
mainTemplate: readFileSync(__nccwpck_require__.ab + "template.hbs", 'utf-8'),
|
mainTemplate: readFileSync(__nccwpck_require__.ab + "template1.hbs", 'utf-8'),
|
||||||
headerPartial: readFileSync(__nccwpck_require__.ab + "header.hbs", 'utf-8'),
|
headerPartial: readFileSync(__nccwpck_require__.ab + "header1.hbs", 'utf-8'),
|
||||||
commitPartial: readFileSync(__nccwpck_require__.ab + "commit.hbs", 'utf-8'),
|
commitPartial: readFileSync(__nccwpck_require__.ab + "commit1.hbs", 'utf-8'),
|
||||||
footerPartial: readFileSync(__nccwpck_require__.ab + "footer.hbs", 'utf-8')
|
footerPartial: readFileSync(__nccwpck_require__.ab + "footer1.hbs", 'utf-8')
|
||||||
}, options)
|
}, options)
|
||||||
|
|
||||||
if ((!_.isFunction(options.transform) && _.isObject(options.transform)) || _.isUndefined(options.transform)) {
|
if ((!_.isFunction(options.transform) && _.isObject(options.transform)) || _.isUndefined(options.transform)) {
|
||||||
@@ -87137,7 +87139,9 @@ class Manifest {
|
|||||||
this.logger.debug(`type: ${config.releaseType}`);
|
this.logger.debug(`type: ${config.releaseType}`);
|
||||||
this.logger.debug(`targetBranch: ${this.targetBranch}`);
|
this.logger.debug(`targetBranch: ${this.targetBranch}`);
|
||||||
const strategy = strategiesByPath[path];
|
const strategy = strategiesByPath[path];
|
||||||
const release = await strategy.buildRelease(pullRequest);
|
const release = await strategy.buildRelease(pullRequest, {
|
||||||
|
groupPullRequestTitlePattern: this.groupPullRequestTitlePattern,
|
||||||
|
});
|
||||||
if (release) {
|
if (release) {
|
||||||
releases.push({
|
releases.push({
|
||||||
...release,
|
...release,
|
||||||
@@ -88186,9 +88190,10 @@ class LinkedVersions extends plugin_1.ManifestPlugin {
|
|||||||
}
|
}
|
||||||
return collection;
|
return collection;
|
||||||
}, [[], []]);
|
}, [[], []]);
|
||||||
|
this.logger.info(`found ${inScopeCandidates.length} linked-versions candidates`);
|
||||||
// delegate to the merge plugin and add merged pull request
|
// delegate to the merge plugin and add merged pull request
|
||||||
if (inScopeCandidates.length > 0) {
|
if (inScopeCandidates.length > 0) {
|
||||||
const merge = new merge_1.Merge(this.github, this.targetBranch, this.repositoryConfig, `chore\${branch}: release ${this.groupName} libraries`);
|
const merge = new merge_1.Merge(this.github, this.targetBranch, this.repositoryConfig, `chore\${scope}: release ${this.groupName} libraries`);
|
||||||
const merged = await merge.run(inScopeCandidates);
|
const merged = await merge.run(inScopeCandidates);
|
||||||
outOfScopeCandidates.push(...merged);
|
outOfScopeCandidates.push(...merged);
|
||||||
}
|
}
|
||||||
@@ -89731,7 +89736,8 @@ class BaseStrategy {
|
|||||||
* @param {PullRequest} mergedPullRequest The merged release pull request.
|
* @param {PullRequest} mergedPullRequest The merged release pull request.
|
||||||
* @returns {Release} The candidate release.
|
* @returns {Release} The candidate release.
|
||||||
*/
|
*/
|
||||||
async buildRelease(mergedPullRequest) {
|
async buildRelease(mergedPullRequest, options) {
|
||||||
|
var _a;
|
||||||
if (this.skipGitHubRelease) {
|
if (this.skipGitHubRelease) {
|
||||||
this.logger.info('Release skipped from strategy config');
|
this.logger.info('Release skipped from strategy config');
|
||||||
return;
|
return;
|
||||||
@@ -89740,8 +89746,9 @@ class BaseStrategy {
|
|||||||
this.logger.error('Pull request should have been merged');
|
this.logger.error('Pull request should have been merged');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
const mergedTitlePattern = (_a = options === null || options === void 0 ? void 0 : options.groupPullRequestTitlePattern) !== null && _a !== void 0 ? _a : manifest_1.MANIFEST_PULL_REQUEST_TITLE_PATTERN;
|
||||||
const pullRequestTitle = pull_request_title_1.PullRequestTitle.parse(mergedPullRequest.title, this.pullRequestTitlePattern, this.logger) ||
|
const pullRequestTitle = pull_request_title_1.PullRequestTitle.parse(mergedPullRequest.title, this.pullRequestTitlePattern, this.logger) ||
|
||||||
pull_request_title_1.PullRequestTitle.parse(mergedPullRequest.title, manifest_1.MANIFEST_PULL_REQUEST_TITLE_PATTERN, this.logger);
|
pull_request_title_1.PullRequestTitle.parse(mergedPullRequest.title, mergedTitlePattern, this.logger);
|
||||||
if (!pullRequestTitle) {
|
if (!pullRequestTitle) {
|
||||||
this.logger.error(`Bad pull request title: '${mergedPullRequest.title}'`);
|
this.logger.error(`Bad pull request title: '${mergedPullRequest.title}'`);
|
||||||
return;
|
return;
|
||||||
@@ -92530,7 +92537,7 @@ class AppJson extends default_1.DefaultUpdater {
|
|||||||
this.version.minor * 100 +
|
this.version.minor * 100 +
|
||||||
this.version.patch;
|
this.version.patch;
|
||||||
logger.info(`updating Android version from ${parsed.expo.android.versionCode} to ${versionCode}`);
|
logger.info(`updating Android version from ${parsed.expo.android.versionCode} to ${versionCode}`);
|
||||||
parsed.expo.android.versionCode = versionCode.toString();
|
parsed.expo.android.versionCode = versionCode;
|
||||||
}
|
}
|
||||||
return (0, json_stringify_1.jsonStringify)(parsed, content);
|
return (0, json_stringify_1.jsonStringify)(parsed, content);
|
||||||
}
|
}
|
||||||
@@ -94074,7 +94081,7 @@ class VersionRB extends default_1.DefaultUpdater {
|
|||||||
* @returns {string} The updated content
|
* @returns {string} The updated content
|
||||||
*/
|
*/
|
||||||
updateContent(content) {
|
updateContent(content) {
|
||||||
return content.replace(/(["'])[0-9]+\.[0-9]+\.[0-9](-\w+)?["']/, `$1${this.version}$1`);
|
return content.replace(/(["'])[0-9]+\.[0-9]+\.[0-9]+(-\w+)?["']/, `$1${this.version}$1`);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
exports.VersionRB = VersionRB;
|
exports.VersionRB = VersionRB;
|
||||||
@@ -120753,7 +120760,7 @@ module.exports = {};
|
|||||||
/***/ ((module) => {
|
/***/ ((module) => {
|
||||||
|
|
||||||
"use strict";
|
"use strict";
|
||||||
module.exports = {"i8":"14.17.2"};
|
module.exports = {"i8":"14.17.5"};
|
||||||
|
|
||||||
/***/ }),
|
/***/ }),
|
||||||
|
|
||||||
|
|||||||
20
dist/template.hbs
vendored
20
dist/template.hbs
vendored
@@ -1,11 +1,23 @@
|
|||||||
{{> header}}
|
{{> header}}
|
||||||
|
|
||||||
|
{{#if noteGroups}}
|
||||||
|
{{#each noteGroups}}
|
||||||
|
|
||||||
|
### ⚠ {{title}}
|
||||||
|
|
||||||
|
{{#each notes}}
|
||||||
|
* {{#if commit.scope}}**{{commit.scope}}:** {{/if}}{{text}}
|
||||||
|
{{/each}}
|
||||||
|
{{/each}}
|
||||||
|
{{/if}}
|
||||||
{{#each commitGroups}}
|
{{#each commitGroups}}
|
||||||
|
|
||||||
|
{{#if title}}
|
||||||
|
### {{title}}
|
||||||
|
|
||||||
|
{{/if}}
|
||||||
{{#each commits}}
|
{{#each commits}}
|
||||||
{{> commit root=@root}}
|
{{> commit root=@root}}
|
||||||
{{/each}}
|
{{/each}}
|
||||||
|
|
||||||
{{/each}}
|
{{/each}}
|
||||||
|
|
||||||
{{> footer}}
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
20
dist/template1.hbs
vendored
20
dist/template1.hbs
vendored
@@ -1,23 +1,11 @@
|
|||||||
{{> header}}
|
{{> header}}
|
||||||
|
|
||||||
{{#if noteGroups}}
|
|
||||||
{{#each noteGroups}}
|
|
||||||
|
|
||||||
### ⚠ {{title}}
|
|
||||||
|
|
||||||
{{#each notes}}
|
|
||||||
* {{#if commit.scope}}**{{commit.scope}}:** {{/if}}{{text}}
|
|
||||||
{{/each}}
|
|
||||||
{{/each}}
|
|
||||||
{{/if}}
|
|
||||||
{{#each commitGroups}}
|
{{#each commitGroups}}
|
||||||
|
|
||||||
{{#if title}}
|
|
||||||
### {{title}}
|
|
||||||
|
|
||||||
{{/if}}
|
|
||||||
{{#each commits}}
|
{{#each commits}}
|
||||||
{{> commit root=@root}}
|
{{> commit root=@root}}
|
||||||
{{/each}}
|
{{/each}}
|
||||||
|
|
||||||
{{/each}}
|
{{/each}}
|
||||||
|
|
||||||
|
{{> footer}}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user