Skip to content

Commit

Permalink
try to composite action
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Mar 30, 2024
1 parent 8f4798d commit a74904f
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 15 deletions.
10 changes: 1 addition & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,17 +54,9 @@ jobs:
id-token: write

steps:
- name: Checkout
- name: Git Checkout
id: checkout
uses: actions/checkout@v4
- name: Test Local Action
uses: actions/setup-node@v4
with:
node-version: 20.x
registry-url: 'https://registry.npmjs.org'
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Test action
id: test-action
uses: ./
Expand Down
20 changes: 14 additions & 6 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,18 @@ inputs:
required: false
default: 'false'

outputs:
version:
description: 'Published release version'

runs:
using: node20
main: dist/index.js
using: composite
steps:
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20.x
registry-url: 'https://registry.npmjs.org'
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Publish version
uses: ./npm-semver-action.yml
with:
target-branch: ${{ inputs.target-branch }}
provenance: ${{ inputs.provenance }}
3 changes: 3 additions & 0 deletions npm-semver-action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
runs:
using: node20
main: dist/index.js

0 comments on commit a74904f

Please sign in to comment.