-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction.yml
72 lines (72 loc) · 2.82 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: "Changelog CLI"
description: "Create a change log based of git commit history"
inputs:
service-name:
description: "Name of the service being released"
required: true
github-release:
description: "Create a github release? (True or false)"
required: true
github-update:
description: "Update the github release instead of creating it? (True or false)"
required: false
default: false
github-token:
description: "Github token used for generating releases"
required: true
github-tag-pattern:
description: "Regex pattern used for matching tag patterns (group 1 in the pattern should match the 'version') - example `processor-(.*)`"
required: false
github-path-exclude-pattern:
description: "Regex pattern used for matching file patch for which commits should not be included. I.e. if a commit only contains files that match this, it will not be in the change log - example `^gateway/`"
required: false
jira-app-name:
description: "Name of the Jira app used for generating Jira issue links"
required: false
output:
description: "Output mode (console,slack)"
required: true
version-mode:
description: "version format mode (SemVer,DateVer)"
required: false
default: "DateVer"
slack-token:
description: "Slack App API Token used for publishing changelog"
required: true
slack-channel:
description: "Which slack channel should this be published to"
required: false
slack-channels:
description: "A comma-separated list of Slack channels to post the changelog to"
required: false
runs:
using: "composite"
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install curl
run: sudo apt-get update && sudo apt-get install -y curl git
shell: bash
- name: Download changelog cli
run: |
curl -L -o changelog-cli https://github.com/monta-app/changelog-cli/releases/download/v1.6.2/changelog-cli
chmod +x ./changelog-cli
shell: bash
- name: Run changelog cli
env:
CHANGELOG_SERVICE_NAME: ${{ inputs.service-name }}
CHANGELOG_GITHUB_RELEASE: ${{ inputs.github-release }}
CHANGELOG_GITHUB_UPDATE: ${{ inputs.github-update }}
CHANGELOG_GITHUB_TOKEN: ${{ inputs.github-token }}
CHANGELOG_JIRA_APP_NAME: ${{ inputs.jira-app-name }}
CHANGELOG_VERSION_MODE: ${{ inputs.version-mode }}
CHANGELOG_GITHUB_TAG_PATTERN: ${{ inputs.github-tag-pattern }}
CHANGELOG_GITHUB_PATH_EXCLUDE_PATTERN: ${{ inputs.github-path-exclude-pattern }}
CHANGELOG_OUTPUT: ${{ inputs.output }}
CHANGELOG_SLACK_TOKEN: ${{ inputs.slack-token }}
CHANGELOG_SLACK_CHANNEL_NAME: ${{ inputs.slack-channel }}
CHANGELOG_SLACK_CHANNELS: ${{ inputs.slack-channels }}
run: ./changelog-cli
shell: bash