Skip to content

Adding to GitHub

Adding to GitHub #1

Workflow file for this run

name: "Test"
on:
workflow_dispatch:
push:
jobs:
test:
name: "Test"
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: "Checkout"
uses: actions/checkout@v4
- name: "Test Local Action"
id: test
uses: ./
with:
url: https://httpbin.org/get
- name: "Echo Outputs"
run: |
echo '${{ steps.test.outputs.status }}'
echo '${{ steps.test.outputs.data }}'
lint:
name: "Lint"
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: "Checkout"
uses: actions/checkout@v4
- name: "Setup Node"
uses: actions/setup-node@v4
with:
node-version: 20
- name: "ESLint"
run: |
npm install
npm run lint
build:
name: "Build"
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: "Checkout"
uses: actions/checkout@v4
- name: "Setup Node"
uses: actions/setup-node@v4
with:
node-version: 20
- name: "Build"
run: |
npm install
npm run build
- name: "Verify"
run: |
git status --porcelain dist/
if [ ! -d "dist" ];then
echo "Missing dist directory, run: npm build"
exit 1
fi
if [ -n "$(git status --porcelain dist)" ];then
echo "Build was not run, run: npm build"
exit 1
fi