Skip to content

setting up flow parser #3

setting up flow parser

setting up flow parser #3

Workflow file for this run

name: Build
on: [push]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-13, windows-latest]
steps:
- uses: actions/setup-node@v4
- uses: actions/checkout@v4
- uses: esy/[email protected]
with:
setup-esy-npm-package: 'esy'
setup-esy-version: 'dev'
source-cache-key: 20240515-1
cache-key: ${{ hashFiles('esy.lock/index.json') }}-20240515-1
- uses: esy/[email protected]
id: prepare-npm-artifacts
with:
source-cache-key: 20240515-1
cache-key: ${{ hashFiles('esy.lock/index.json') }}-20240515-1
prepare-npm-artifacts-mode: true
static-build:
runs-on: ubuntu-latest
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build and push
uses: docker/build-push-action@v5
with:
file: ./docker/DevImage.Dockerfile
push: false
tags: user/app:latest
bundle:
permissions:
contents: write
needs:
- build
- static-build
runs-on: macos-latest
steps:
- uses: actions/setup-node@v4
with:
registry-url: 'https://registry.npmjs.org'
- uses: actions/checkout@v4
with:
fetch-depth: 100
fetch-tags: true
- uses: esy/[email protected]
with:
source-cache-key: 20240515-1
cache-key: ${{ hashFiles('esy.lock/index.json') }}-20240515-1
bundle-npm-artifacts-mode: true
- name: Create tarball
run: tar cf npm-release.tgz ./_npm-release
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: npm-release.tgz
- name: Publish to NPM registry
working-directory: _npm-release
run: npm publish --access=public .
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-13, windows-latest]
needs: bundle
steps:
- uses: actions/setup-node@v4
- uses: actions/download-artifact@v4
with:
name: npm-release
- run: npm i --prefix $HOME/prefix -g ./npm-release.tgz
if: ${{ runner.os != 'Windows' }}
shell: bash
- run: echo $HOME/prefix/bin >> "$GITHUB_PATH"
if: ${{ runner.os != 'Windows' }}
shell: bash
- run: npm i -g ./npm-release.tgz
if: ${{ runner.os == 'Windows' }}
- run: hello