Skip to content

Commit

Permalink
Convert to a composite action
Browse files Browse the repository at this point in the history
JavaScript actions have no way of supporting Node 18. We want to use
Node 18 to fix #33.

It seems that GitHub will never support `node18` for `actions/runner`,
instead jumping straight to Node 20.
  • Loading branch information
georgeblahblah committed Jul 26, 2023
1 parent 5a61414 commit 04341c4
Showing 1 changed file with 21 additions and 2 deletions.
23 changes: 21 additions & 2 deletions action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,25 @@ inputs:
required: true
description: A list of files/directories to upload to Riff-Raff. An alternative to nesting `sources` inside the `config` input.

# When `actions/runner` supports Node 18 or higher, this could be a Javascript action.
# See https://github.com/guardian/actions-riff-raff/issues/33
runs:
using: "node16"
main: "dist/index.js"
using: composite
steps:
- name: Setup node
uses: actions/setup-node@v3
with:
node-version-file: .nvmrc
- name: Action
run: node ${{ github.action_path }}/dist/index.js
shell: bash
env:
INPUT_APP: ${{ inputs.app }}
INPUT_CONFIG: ${{ inputs.config }}
INPUT_CONFIGPATH: ${{ inputs.configPath }}
INPUT_PROJECTNAME: ${{ inputs.projectName }}
INPUT_DRYRUN: ${{ inputs.dryRun }}
INPUT_BUILDNUMBER: ${{ inputs.buildNumber }}
INPUT_BUILDNUMBEROFFSET: ${{ inputs.buildNumberOffset }}
INPUT_STAGINGDIR: ${{ inputs.stagingDir }}
INPUT_CONTENTDIRECTORIES: ${{ inputs.contentDirectories }}

0 comments on commit 04341c4

Please sign in to comment.