Skip to content

Commit

Permalink
Merge pull request #77 from ExtendScript/ci/github-actions
Browse files Browse the repository at this point in the history
ci(actions): Setup actions with tests
  • Loading branch information
ff6347 authored Jul 26, 2023
2 parents 5f6b5c0 + 87fd449 commit 02bd014
Show file tree
Hide file tree
Showing 4 changed files with 31,197 additions and 2,917 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# basic nodejs github action to run npm test and build

name: Node.js CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [ 14.x, 16.x, 18.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm test
- run: npm run build --if-present
- run: npm run lint --if-present

release:
release:
name: semantic-release
needs: [build]
runs-on: ubuntu-latest
outputs:
new-release-published: ${{ steps.semantic-release.outputs.new_release_published }}
new-release-version: ${{ steps.semantic-release.outputs.new_release_version }}
steps:
- uses: actions/checkout@v3
with:
persist-credentials: false
- uses: actions/setup-node@v3
with:
node-version-file: '.nvmrc'
- run: npm ci
- id: semantic-release
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
Loading

0 comments on commit 02bd014

Please sign in to comment.