Skip to content

Update dependencies #25

Update dependencies

Update dependencies #25

Workflow file for this run

name: Publish QPM Package
env:
module_id: chroma
qmodName: Chroma
cache-name: chroma_cache
on:
push:
tags:
- 'v*'
permissions:
pull-requests: write
contents: write
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
name: Checkout
with:
submodules: true
lfs: true
- uses: seanmiddleditch/gha-setup-ninja@v3
# Use canary NDK to avoid lesser known compile bugs
- name: Setup canary NDK
id: setup-ndk
uses: ./.github/actions/canary-ndk
- name: Create ndkpath.txt
run: |
echo ${{ steps.setup-ndk.outputs.ndk-path }} > ${GITHUB_WORKSPACE}/ndkpath.txt
cat ${GITHUB_WORKSPACE}/ndkpath.txt
# - name: Create ndkpath.txt
# run: |
# echo "$ANDROID_NDK_LATEST_HOME" > ${GITHUB_WORKSPACE}/ndkpath.txt
# cat ${GITHUB_WORKSPACE}/ndkpath.txt
- name: Get Tag Version
id: get_tag_version
run: |
echo ${GITHUB_REF#refs/tags/}
echo ::set-output name=TAG::${GITHUB_REF#refs/tags/}
echo ::set-output name=VERSION::${GITHUB_REF#refs/tags/v}
- name: QPM Rust Action
uses: Fernthedev/qpm-rust-action@main
with:
#required
workflow_token: ${{secrets.GITHUB_TOKEN}}
restore: true # will run restore on download
cache: true #will cache dependencies
publish: true
publish_token: ${{secrets.QPM_TOKEN}}
version: ${{ steps.get_tag_version.outputs.VERSION }}
tag: ${{ steps.get_tag_version.outputs.TAG }}
# set to true if applicable, ASSUMES the file is already a release asset
qpm_release_bin: false
qpm_debug_bin: false
# Name of qmod in release asset. Assumes exists, same as prior
qpm_qmod: ${{env.qmodName}}.qmod
- name: Build
run: |
cd ${GITHUB_WORKSPACE}
qpm-rust s build
qpm-rust qmod zip
- name: Get Library Name
id: libname
run: |
cd ./build/
pattern="lib${module_id}*.so"
files=( $pattern )
echo ::set-output name=NAME::"${files[0]}"
- name: Rename debug
run: |
mv ./build/debug/${{ steps.libname.outputs.NAME }} ./build/debug/debug_${{ steps.libname.outputs.NAME }}
- name: Upload to Release
id: upload_file_release
uses: softprops/[email protected]
with:
name: ${{ github.event.inputs.release_msg }}
tag_name: ${{ github.event.inputs.version }}
files: |
./${{ env.qmodName }}.qmod
./build/${{ steps.libname.outputs.NAME }}
./build/debug/debug_${{ steps.libname.outputs.NAME }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Make PR to QeatMods3
id: qmod-release
uses: QuestPackageManager/qmod-repo-publish-action@main
with:
token: ${{secrets.REPO_TOKEN}}
# first asset URL
qmod_url: ${{ fromJSON(steps.upload_file_release.outputs.assets)[0].browser_download_url }}
qmod_repo_owner: 'dantheman827'
qmod_repo_name: 'bsqmods'