Merge pull request #525 from WolframResearch/main #30
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
workflow_dispatch: | |
push: | |
branches: [release/paclet] | |
concurrency: | |
group: ${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
RESOURCE_PUBLISHER_TOKEN: ${{ secrets.RESOURCE_PUBLISHER_TOKEN }} | |
WOLFRAMSCRIPT_ENTITLEMENTID: ${{ secrets.WOLFRAMSCRIPT_ENTITLEMENTID }} | |
jobs: | |
Check: | |
name: Check | |
runs-on: ubuntu-latest | |
timeout-minutes: 15 | |
container: | |
image: wolframresearch/wolframengine:13.3 | |
options: --user root | |
env: | |
WOLFRAM_SYSTEM_ID: Linux-x86-64 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Check | |
run: wolframscript -f Scripts/CheckPaclet.wls | |
- name: Build | |
run: wolframscript -f Scripts/BuildPaclet.wls | |
- name: Test | |
run: wolframscript -f Scripts/TestPaclet.wls | |
Release: | |
name: Release | |
needs: [Check, Submit] | |
runs-on: ubuntu-latest | |
timeout-minutes: 30 | |
container: | |
image: wolframresearch/wolframengine:13.3 | |
options: --user root | |
env: | |
WOLFRAM_SYSTEM_ID: Linux-x86-64 | |
GH_INSTALL_URL: https://github.com/cli/cli/releases/download/v2.33.0/gh_2.33.0_linux_amd64.deb | |
steps: | |
- name: Update Git | |
run: | | |
apt-get update && apt-get install software-properties-common -y | |
add-apt-repository ppa:git-core/ppa -y | |
apt-get update && apt-get install git -y | |
wget ${{ env.GH_INSTALL_URL }} -O gh.deb | |
dpkg -i gh.deb | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Build | |
run: wolframscript -f Scripts/BuildPaclet.wls | |
- name: CreateRelease | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
git config --global --add safe.directory $(pwd) | |
gh release create "${{ env.PACLET_RELEASE_TAG }}" "${{ env.PACLET_PATH }}#${{ env.PACLET_FILE }}" \ | |
--target="${{ github.ref }}" \ | |
--repo="${{ env.GITHUB_REPOSITORY }}" \ | |
--title="Release ${{ env.PACLET_RELEASE_TAG }}" \ | |
--generate-notes | |
Submit: | |
name: Submit | |
needs: [Check] | |
runs-on: ubuntu-latest | |
timeout-minutes: 30 | |
container: | |
image: wolframresearch/wolframengine:13.3 | |
options: --user root | |
env: | |
WOLFRAM_SYSTEM_ID: Linux-x86-64 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: BuildMX | |
run: wolframscript -f Scripts/BuildMX.wls | |
- name: Submit | |
uses: WolframResearch/[email protected] | |
- name: UploadArtifact | |
uses: actions/upload-artifact@v3 | |
with: | |
path: ${{ env.PACLET_BUILD_DIR }} | |
if-no-files-found: ignore |