Skip to content

v6.0.1

v6.0.1 #2

Workflow file for this run

name: Release Creation
on:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Extract Version From Tag
id: get_version
uses: battila7/get-version-action@v2
- name: Modify Module Manifest With Release-Specific Values
id: sub_manifest_link_version
uses: microsoft/variable-substitution@v1
with:
files: 'module.json'
env:
version: ${{steps.get_version.outputs.version-without-v}}
manifest: https://github.com/${{github.repository}}/releases/latest/download/module.json
download: https://github.com/${{github.repository}}/releases/download/${{github.event.release.tag_name}}/module.zip
- name: Create Module Archive
run: zip --recurse-paths ./module.zip module.json LICENSE esmodules/ languages/ styles/
- name: Update Release With Files
id: create_version_release
uses: ncipollo/release-action@v1
with:
allowUpdates: true
name: ${{ github.event.release.name }}
draft: ${{ github.event.release.unpublished }}
prerelease: ${{ github.event.release.prerelease }}
token: ${{ secrets.GITHUB_TOKEN }}
artifacts: './module.json, ./module.zip'
tag: ${{ github.event.release.tag_name }}
body: ${{ github.event.release.body }}
- name: Publish Module to FoundryVTT Website
id: publish-to-foundry-website
if: ${{ ! github.event.release.prerelease }}
uses: cs96and/FoundryVTT-release-package@v1
with:
package-token: ${{ secrets.PACKAGE_TOKEN }}
manifest-url: https://github.com/${{github.repository}}/releases/download/${{github.event.release.tag_name}}/module.json