mirror of
https://github.com/joaquinjsb/gitea-release-please-action
synced 2026-05-13 15:51:41 +02:00
committed by
GitHub
parent
608c16ba34
commit
2840bca340
44
dist/index.js
vendored
44
dist/index.js
vendored
@@ -21,7 +21,7 @@ const signoff = core.getInput('signoff') || undefined
|
|||||||
|
|
||||||
function getGitHubInput () {
|
function getGitHubInput () {
|
||||||
return {
|
return {
|
||||||
fork: core.getBooleanInput('fork'),
|
fork: getOptionalBooleanInput('fork'),
|
||||||
defaultBranch: core.getInput('default-branch') || undefined,
|
defaultBranch: core.getInput('default-branch') || undefined,
|
||||||
repoUrl: core.getInput('repo-url') || process.env.GITHUB_REPOSITORY,
|
repoUrl: core.getInput('repo-url') || process.env.GITHUB_REPOSITORY,
|
||||||
apiUrl: core.getInput('github-api-url') || GITHUB_API_URL,
|
apiUrl: core.getInput('github-api-url') || GITHUB_API_URL,
|
||||||
@@ -30,6 +30,20 @@ function getGitHubInput () {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getOptionalBooleanInput (name) {
|
||||||
|
if (core.getInput(name) === '') {
|
||||||
|
return undefined
|
||||||
|
}
|
||||||
|
return core.getBooleanInput(name)
|
||||||
|
}
|
||||||
|
|
||||||
|
function getOptionalMultilineInput (name) {
|
||||||
|
if (core.getInput(name) === '') {
|
||||||
|
return undefined
|
||||||
|
}
|
||||||
|
return core.getMultilineInput(name)
|
||||||
|
}
|
||||||
|
|
||||||
function getManifestInput () {
|
function getManifestInput () {
|
||||||
return {
|
return {
|
||||||
configFile: core.getInput('config-file') || CONFIG_FILE,
|
configFile: core.getInput('config-file') || CONFIG_FILE,
|
||||||
@@ -113,9 +127,9 @@ function getGitHubInstance () {
|
|||||||
|
|
||||||
async function manifestInstance (github) {
|
async function manifestInstance (github) {
|
||||||
const { fork } = getGitHubInput()
|
const { fork } = getGitHubInput()
|
||||||
const bumpMinorPreMajor = core.getBooleanInput('bump-minor-pre-major')
|
const bumpMinorPreMajor = getOptionalBooleanInput('bump-minor-pre-major')
|
||||||
const bumpPatchForMinorPreMajor = core.getBooleanInput('bump-patch-for-minor-pre-major')
|
const bumpPatchForMinorPreMajor = getOptionalBooleanInput('bump-patch-for-minor-pre-major')
|
||||||
const monorepoTags = core.getBooleanInput('monorepo-tags')
|
const monorepoTags = getOptionalBooleanInput('monorepo-tags')
|
||||||
const packageName = core.getInput('package-name') || undefined
|
const packageName = core.getInput('package-name') || undefined
|
||||||
const path = core.getInput('path') || undefined
|
const path = core.getInput('path') || undefined
|
||||||
const releaseType = core.getInput('release-type', { required: true })
|
const releaseType = core.getInput('release-type', { required: true })
|
||||||
@@ -126,26 +140,26 @@ 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 draft = core.getBooleanInput('draft')
|
const draft = getOptionalBooleanInput('draft')
|
||||||
const draftPullRequest = core.getBooleanInput('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
|
||||||
const versioning = core.getInput('versioning-strategy') || undefined
|
const versioning = core.getInput('versioning-strategy') || undefined
|
||||||
const releaseAs = core.getInput('release-as') || undefined
|
const releaseAs = core.getInput('release-as') || undefined
|
||||||
const skipGithubRelease = core.getBooleanInput('skip-github-release')
|
const skipGithubRelease = getOptionalBooleanInput('skip-github-release')
|
||||||
const prerelease = core.getBooleanInput('prerelease')
|
const prerelease = getOptionalBooleanInput('prerelease')
|
||||||
const component = core.getInput('component') || undefined
|
const component = core.getInput('component') || undefined
|
||||||
const includeVInTag = core.getBooleanInput('include-v-in-tag')
|
const includeVInTag = getOptionalBooleanInput('include-v-in-tag')
|
||||||
const tagSeparator = core.getInput('tag-separator') || undefined
|
const tagSeparator = core.getInput('tag-separator') || undefined
|
||||||
const snapshotLabels = core.getInput('snapshot-labels') ? core.getMultilineInput('snapshot-labels') : undefined
|
const snapshotLabels = getOptionalMultilineInput('snapshot-labels')
|
||||||
const bootstrapSha = core.getInput('bootstrap-sha') || undefined
|
const bootstrapSha = core.getInput('bootstrap-sha') || undefined
|
||||||
const lastReleaseSha = core.getInput('last-release-sha') || undefined
|
const lastReleaseSha = core.getInput('last-release-sha') || undefined
|
||||||
const alwaysLinkLocal = core.getBooleanInput('always-link-local')
|
const alwaysLinkLocal = getOptionalBooleanInput('always-link-local')
|
||||||
const separatePullRequests = core.getBooleanInput('separate-pull-requests')
|
const separatePullRequests = getOptionalBooleanInput('separate-pull-requests')
|
||||||
const plugins = core.getMultilineInput('plugins') || undefined
|
const plugins = core.getMultilineInput('plugins') || undefined
|
||||||
const labels = core.getInput('labels') ? core.getMultilineInput('labels') : undefined
|
const labels = core.getInput('labels') ? core.getMultilineInput('labels') : undefined
|
||||||
const releaseLabels = core.getInput('release-labels') ? core.getMultilineInput('release-labels') : undefined
|
const releaseLabels = getOptionalMultilineInput('release-labels')
|
||||||
const skipLabeling = core.getBooleanInput('skip-labeling')
|
const skipLabeling = getOptionalBooleanInput('skip-labeling')
|
||||||
const sequentialCalls = core.getBooleanInput('sequential-calls')
|
const sequentialCalls = getOptionalBooleanInput('sequential-calls')
|
||||||
const groupPullRequestTitlePattern = core.getInput('group-pull-request-title-pattern') || undefined
|
const groupPullRequestTitlePattern = core.getInput('group-pull-request-title-pattern') || undefined
|
||||||
const releaseSearchDepth = core.getInput('release-search-depth') || undefined
|
const releaseSearchDepth = core.getInput('release-search-depth') || undefined
|
||||||
const commitSearchDepth = core.getInput('commit-search-depth') || undefined
|
const commitSearchDepth = core.getInput('commit-search-depth') || undefined
|
||||||
|
|||||||
Reference in New Issue
Block a user