Skip to content

Build audioMotion.js distribution in GitHub Action pipeline #102

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions .github/workflows/build-dist.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Build Distribution

on:
push: # Run on every commit to any branch
branches: ['**']
workflow_dispatch: # Also allow manual trigg

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '22'
- name: Install dependencies
run: npm install

- name: Build project
run: npm run build

- name: Create dist folder
run: |
mkdir dist
cp README.md dist/
cp -r docs dist/docs
cp -r public dist/public

- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: audioMotion.js
path: dist

- name: Add artifact link to summary
run: echo "[⬇️ Download audioMotion.js distribution](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }})" >> $GITHUB_STEP_SUMMARY
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
**/node_modules
package-lock.json

# Build files
public/audioMotion.js
public/audioMotion.js.LICENSE.txt
public/vendors.js
public/vendors.js.LICENSE.txt

# User configuration
public/config.yaml
2 changes: 0 additions & 2 deletions public/audioMotion.js

This file was deleted.

30 changes: 0 additions & 30 deletions public/audioMotion.js.LICENSE.txt

This file was deleted.

2 changes: 0 additions & 2 deletions public/vendors.js

This file was deleted.

38 changes: 0 additions & 38 deletions public/vendors.js.LICENSE.txt

This file was deleted.