Skip to content

Commit c89b9ed

Browse files
committed
Bump to node v20, updated documentation & dependencies
1 parent 78db035 commit c89b9ed

File tree

10 files changed

+806
-1040
lines changed

10 files changed

+806
-1040
lines changed

.github/workflows/ci-build.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@ jobs:
1010
runs-on: ubuntu-latest
1111
steps:
1212
- name: Checkout Code
13-
uses: actions/checkout@v3
13+
uses: actions/checkout@v4
1414
with:
1515
fetch-depth: 0
1616
- name: Setup Node
17-
uses: actions/setup-node@v3
17+
uses: actions/setup-node@v4
1818
with:
19-
node-version: 16
19+
node-version: 20
2020
cache: npm
2121
- name: Run npm install
2222
run: npm i

.github/workflows/sonar.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@ jobs:
1111
runs-on: ubuntu-latest
1212
steps:
1313
- name: Checkout Code
14-
uses: actions/checkout@v3
14+
uses: actions/checkout@v4
1515
with:
1616
fetch-depth: 0
1717
- name: Setup Node
18-
uses: actions/setup-node@v3
18+
uses: actions/setup-node@v4
1919
with:
20-
node-version: 16
20+
node-version: 20
2121
cache: npm
2222
- name: Run npm install
2323
run: npm i

.github/workflows/testing.yml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
#
2+
# This workflow file is used for testing during local development with the help of
3+
# https://github.com/nektos/act.
4+
#
5+
6+
name: Test GH Action
7+
8+
on:
9+
workflow_dispatch:
10+
11+
jobs:
12+
test:
13+
name: Test Action
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v4
17+
18+
- name: Login
19+
uses: atlassian/gajira-login@v3
20+
env:
21+
JIRA_BASE_URL: ${{ secrets.JIRA_URL }}
22+
JIRA_USER_EMAIL: ${{ secrets.JIRA_EMAIL }}
23+
JIRA_API_TOKEN: ${{ secrets.JIRA_TOKEN }}
24+
25+
- name: Update Fields
26+
id: updatefields
27+
uses: ./
28+
with:
29+
retries: 1
30+
retryDelay: 10
31+
timeout: 2000
32+
failOnError: true
33+
issue: ${{ vars.JIRA_ISSUES }}
34+
summary: Some fancy title
35+
description: Plaintext only
36+
assignee: REMOVE
37+
priority: Major
38+
duedate: REMOVE
39+
resolution: Won't Do
40+
components: |
41+
- Translation
42+
- Search
43+
- Navigation
44+
- Form
45+
fixversions: |
46+
- 1.0.0
47+
- 1.1.0
48+
- 1.2.0
49+
- 1.1.0
50+
labels: |
51+
- security
52+
- sonar
53+
- github
54+
- vanity
55+
customfields: |
56+
10859: unblocked
57+
58+
- name: Print Outputs
59+
run: |
60+
echo "HAS ERRORS: ${{ steps.updatefields.outputs.hasErrors }}"
61+
echo "IDs SUCCESS: ${{ steps.updatefields.outputs.successful }}"
62+
echo "IDs ERROR: ${{ steps.updatefields.outputs.failed }}"

README.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@ jobs:
7171
10050: some value
7272
10051: 2023-01-01
7373
10052: https://github.com/marketplace?type=action
74-
7574
customfieldsJson: |
7675
10057: {"content":[{"content":[{"type":"text","text":"Content for the TextArea custom field"}],"type":"paragraph"}],"type":"doc","version":1}
7776
10058: ["value1", "value2]
@@ -355,3 +354,18 @@ with the action's output.
355354
3. `failed` - A list of IDs of issues that failed to get updated. This may be useful to add comments to the tickets
356355
in question or to report those tickets to a Slack or MSTeams channel. The format is again the same as
357356
with the `issues` option.
357+
358+
## Test Action
359+
360+
This action can be tested during development with the use of https://github.com/nektos/act.
361+
362+
Please adapt the values accordingly both in the workflow file and in the CLI command.
363+
364+
```
365+
act -W .github/workflows/testing.yml \
366+
-j test \
367+
-s JIRA_URL=*** \
368+
-s JIRA_EMAIL=*** \
369+
-s JIRA_TOKEN=*** \
370+
--var JIRA_ISSUES=WEB-123
371+
```

action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,5 +59,5 @@ inputs:
5959
description: A list of custom fields with their respective values in JSON. Supports Atlassian Documents and multiple values.
6060
required: false
6161
runs:
62-
using: node16
62+
using: node20
6363
main: ./dist/index.js

dist/index.js

Lines changed: 108 additions & 104 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)