Skip to content
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
16 changes: 10 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,28 @@ name: Release Creation
on:
release:
types: [published]
push:

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v5
with:
node-version: 22
cache: npm
- name: Build
run: npm ci && npm run build
# Get the version from 'module.json'
- name: Get Version
shell: bash
id: get-version
run: echo "::set-output name=version::$(node ./.github/workflows/get-version.js)"
# Get the name from 'module.json'
- name: Get Includes
shell: bash
id: get-includes
run: echo "::set-output name=files::$(node ./.github/workflows/get-includes.js)"
# create a zip file with all files required by the module to add to the release
- name: Zip Files
working-directory: ./dist #SORRY BUT YOU HAVE TO USE DIST JUST LIKE GET OVER IT OR FIGURE OUT A BETTER WAY
run: zip -r ../module.zip ${{steps.get-includes.outputs.files}}
run: zip -r ../module.zip ./*
#Useful only for the template so we can leave the manifest and download urls empty
- name: Substitute Manifest and Download Links For Versioned Ones
id: sub_manifest_link_latest
Expand Down Expand Up @@ -50,6 +52,7 @@ jobs:
- name: Substitute Manifest and Download Links For Versioned Ones
id: sub_manifest_link_version
uses: microsoft/variable-substitution@v1
if: endsWith(github.ref, 'main')
with:
files: './dist/module.json'
env:
Expand All @@ -61,6 +64,7 @@ jobs:
- name: Create Version Release
id: create_version_release
uses: ncipollo/release-action@v1
if: endsWith(github.ref, 'main')
with:
allowUpdates: true # set this to false if you want to prevent updating existing releases
name: Release ${{ steps.get-version.outputs.version }}
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ lerna-debug.log*

node_modules
dist-ssr
dist
*.local

# Editor directories and files
Expand All @@ -23,4 +24,4 @@ dist-ssr
*.sw?

# ignore special files
./stats.html
./stats.html
Loading