Skip to content

Commit

Permalink
github-actions: create linux release
Browse files Browse the repository at this point in the history
  • Loading branch information
norberttak authored Dec 14, 2022
1 parent deb4638 commit abd41a4
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 3 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,3 +72,10 @@ jobs:

- name: Install
run: cmake --build build --target install

- name: Upload built plugin (Linux)
if: matrix.os == 'ubuntu-latest'
uses: actions/upload-artifact@v3
with:
name: built-plugin-linux
path: ${{ github.workspace }}/install/XPanel/64/*
19 changes: 16 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ jobs:
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAG: v${{ inputs.release-version }}
RELEASE_PLUGIN_ZIP: xpanel_v${{ inputs.release-version }}.zip
WINDOWS_RELEASE_PLUGIN_ZIP: xpanel_windows_v${{ inputs.release-version }}.zip
LINUX_RELEASE_PLUGIN_ZIP: xpanel_linux_v${{ inputs.release-version }}.zip
SAMPLE_CONFIG_ZIP: sample_configs_v${{ inputs.release-version }}.zip

steps:
Expand All @@ -35,6 +36,12 @@ jobs:
name: built-plugin-windows
path: built-plugin-windows/plugins/XPanel/64/

- name: Download built plugin (Linux)
uses: actions/download-artifact@v3
with:
name: built-plugin-linux
path: built-plugin-linux/plugins/XPanel/64/

- name: Copy 3rd party dlls (Windows)
run: |
cp LUA/lua54.dll built-plugin-windows/plugins/XPanel/64/
Expand All @@ -44,7 +51,12 @@ jobs:
- name: Create release plugin zip (Windows)
run: |
cd built-plugin-windows
zip -r ../${RELEASE_PLUGIN_ZIP} .
zip -r ../${WINDOWS_RELEASE_PLUGIN_ZIP} .
- name: Create release plugin zip (Linux)
run: |
cd built-plugin-linux
zip -r ../${LINUX_RELEASE_PLUGIN_ZIP} .
- name: Create sample configs zip
run: |
Expand All @@ -58,5 +70,6 @@ jobs:
--title "v${{ inputs.release-version }} release" \
--generate-notes \
${TAG} \
${RELEASE_PLUGIN_ZIP} \
${WINDOWS_RELEASE_PLUGIN_ZIP} \
${LINUX_RELEASE_PLUGIN_ZIP} \
${SAMPLE_CONFIG_ZIP}

0 comments on commit abd41a4

Please sign in to comment.