Skip to content

update README

update README #1

Workflow file for this run

name: update-html

Check failure on line 1 in .github/workflows/update_html.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/update_html.yaml

Invalid workflow file

`update-html` is not a valid event name
on:
push:
branches: [main]
tags: ["v*"]
pull_request:
branches: [main]
workflow_dispatch:
update-html:
name: Build plugin binaries
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
package:
name: Package Plugin
runs-on: ubuntu-latest
needs: build
if: github.event_name == 'push'
steps:
- name: Install Spin
uses: rajatjindal/setup-actions/spin@main
with:
version: ${{ env.SPIN_VERSION }}
- name: Install Pluginify
run: spin plugins install --url https://github.com/itowlson/spin-pluginify/releases/download/canary/pluginify.json --yes
- name: set the release version (tag)
if: startsWith(github.ref, 'refs/tags/v')
run: echo "RELEASE_VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
- name: set the release version (main)
if: github.ref == 'refs/heads/main'
run: echo "RELEASE_VERSION=canary" >> $GITHUB_ENV
- name: Download artifacts
uses: actions/download-artifact@v4
- name: Display structure of downloaded files
run: ls -R
- name: pluginify it
run: |
spin pluginify --merge --release-url-base https://github.com/fermyon/otel-plugin/releases/download/${{ env.RELEASE_VERSION }}/ >${{ env.PROGRAM_NAME }}.json
- name: Display merged manifest
run: cat ${{ env.PROGRAM_NAME }}.json
- name: Archive Combined Manifest
uses: actions/upload-artifact@v4
with:
path: ${{ env.PROGRAM_NAME }}.json
- name: Gather all new release files
run: |
mkdir release-assets
find . -name "*.tar.gz" -exec cp {} release-assets/ \;
cp ${{ env.PROGRAM_NAME }}.json release-assets/
ls release-assets/
# Handle versioned release
- name: Create versioned release
if: startsWith(github.ref, 'refs/tags/v')
run: gh release create ${{ env.RELEASE_VERSION }} --title "${{ env.RELEASE_VERSION }}" --repo ${{ github.repository }} release-assets/*
env:
GH_TOKEN: ${{ github.token }}
# Handle canary release
- name: Delete canary release
if: github.ref == 'refs/heads/main'
run: gh release delete ${{ env.RELEASE_VERSION }} --repo ${{ github.repository }} --cleanup-tag || echo "Release not found, continuing..."
env:
GH_TOKEN: ${{ github.token }}
- name: Recreate canary release
if: github.ref == 'refs/heads/main'
run: gh release create ${{ env.RELEASE_VERSION }} --title "${{ env.RELEASE_VERSION }}" --prerelease --repo ${{ github.repository }} release-assets/*
env:
GH_TOKEN: ${{ github.token }}