Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SWI-5012 - Upgrading action to run on NodeJS 20 #9

Merged
merged 3 commits into from
Apr 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .github/workflows/release-new-version.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Release new action version

on:
release:
types: [released]
workflow_dispatch:
inputs:
tag-name:
description: 'Tag name that the major tag will point to.'
required: true

env:
TAG_NAME: ${{ github.event.inputs.tag-name || github.event.release.tag_name }}
permissions:
contents: write

jobs:
update-tag:
name: Update the major tag to include the ${{ github.event.inputs.tag-name || github.event.release.tag_name }} changes
runs-on: ${{ fromJSON(vars.SWI_GLORG_PROD_UBUNTU_2204) }}
steps:
- name: Update the ${{ env.TAG_NAME }} tag
uses: actions/publish-action@v0.3.0
with:
source-tag: ${{ env.TAG_NAME }}
15 changes: 10 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
on: [push, pull_request, workflow_dispatch]
on:
workflow_dispatch:
push:
branches:
- main
pull_request:

jobs:
test-success:
runs-on: ubuntu-latest
runs-on: ${{ fromJSON(vars.SWI_GLORG_PROD_UBUNTU_2204) }}
name: Test the action on success
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Success
run: exit 0
Expand All @@ -20,11 +25,11 @@ jobs:
slack-channel: ${{ secrets.SLACK_CHANNEL }}

test-failure:
runs-on: ubuntu-latest
runs-on: ${{ fromJSON(vars.SWI_GLORG_PROD_UBUNTU_2204) }}
name: Test the action on failure
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Failure
run: exit 1
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ See [action.yml](action.yml)

```yaml
steps:
- uses: bandwidth/build-notify-slack-action
- uses: Bandwidth/build-notify-slack-action@v2
with:
job-status: ${{ job.status }}
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ inputs:
slack-channel:
description: 'Destination channel to send messages'
runs:
using: 'node16'
using: 'node20'
main: 'index.js'
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "build-notify-slack-action",
"version": "1.0.0",
"version": "2.0.0",
"description": "",
"main": "index.js",
"scripts": {
Expand Down
Loading