Skip to content

build-on-command

build-on-command #20

Workflow file for this run

name: build-on-command
on:
workflow_dispatch:
#push:
# tags:
# - '*'
# paths:
# - http-wasm.gr
# - plugin.gr
# - Makefile
# - icon.png
# - .traefik.yml
permissions:
packages: write
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Set up Git
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
- name: Install Grain
run: |
sudo curl -L --output /usr/local/bin/grain https://github.com/grain-lang/grain/releases/download/grain-v0.6.3/grain-linux-x64
sudo chmod +x /usr/local/bin/grain
- name: Install WABT
run: sudo apt-get install -y wabt
- name: Build Grain Plugin WASM
run: |
make clean
make ENV=--release
- name: Build Grain docs
run: make docs
- name: Commit WASM files
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git pull origin
git add ./plugin.wasm
git add ./*.md
git diff --quiet && git diff --staged --quiet || git commit -m "Update WASM from build [${{ github.workflow }}]"
git push origin
- name: Save Build Artifacts
uses: actions/upload-artifact@v4
with:
name: build-results
path: "./*"
- name: Save Build Artifacts
uses: actions/upload-artifact@v4
with:
name: dist-traefik-wasm-plugin
path: |
.traefik.yml
plugin.wasm
icon.png
README.md