Skip to content

split ci into multiple files #1

split ci into multiple files

split ci into multiple files #1

Workflow file for this run

name: Release
on:
release:
types: [ published ]
jobs:
build:

Check failure on line 8 in .github/workflows/release.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/release.yml

Invalid workflow file

You have an error in your yaml syntax on line 8
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN || '' }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID || '' }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }}
AWS_REGION: ${{ secrets.AWS_REGION }}
SOURCE_DIR: '.s3_uploads'
runs-on: ubuntu-4-cores
steps:
- name: Setup project
uses: ./.github/actions/setup
with:
node-version: '18'
npm-version: '8'
# Run unit and visual tests
- name: Test Project
uses: ./.github/actions/unit
# Build the project
- name: Test Build
run: npm run dist
# Append assets to releases
- name: Upload Assets to Release
if: github.event_name == 'release'
uses: softprops/action-gh-release@v1
with:
files: |
./dist/**/*
# Release is published and deployed into s3://bucket-name/v5.22/
- name: Deploy Released Branches
if: github.event_name == 'release' && env.AWS_ACCESS_KEY_ID != ''
uses: ./.github/actions/upload
with:
type: "Release-Branch"
# Same release from previous deployed into s3://bucket-name/release/
- name: Deploy Latest Release
if: github.event_name == 'release' && github.event.release.prerelease == false && env.AWS_ACCESS_KEY_ID != ''
uses: ./.github/actions/upload
with:
type: "Release"
# Publish to NPM
- name: Publish Latest Release
if: github.event_name == 'release' && github.event.release.prerelease == false && env.NODE_AUTH_TOKEN != ''
run: npm run publish-ci
# Publish to NPM with prerelease dist-tag
- name: Publish Latest Prerelease
if: github.event_name == 'release' && github.event.release.prerelease && env.NODE_AUTH_TOKEN != ''
run: npm run publish-ci -- --tag prerelease-v8