ci: debug zip file creation #13
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: | |
push: | |
# tags: | |
# - 'v*.*.*' | |
# Common variables for all platforms (ldc is hardcoded in windows job) | |
env: | |
# List of commands | |
DPlugBuild: ${{ github.workspace }}/Dplug/tools/dplug-build/dplug-build | |
defaults: | |
run: | |
shell: pwsh | |
jobs: | |
Release: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
# - windows-latest | |
- ubuntu-20.04 # for glibc compatibility with systems > 20.04 | |
# - macOS-latest | |
arch: | |
- 'x86_64' | |
compiler: | |
- ldc-latest | |
steps: | |
# Checkout | |
- name: Checkout master branch | |
uses: actions/checkout@v4 | |
# Install | |
- name: Install Dependencies - Ubuntu | |
if: startsWith(matrix.os,'ubuntu') | |
run: | | |
sudo apt-get -yq install libx11-dev | |
# - name: Install Dependencies - Mac | |
# if: startsWith(matrix.os,'macOS') | |
# run: | | |
# brew update | |
- name: Setup Visual Studio Command Prompt - Windows | |
if: startsWith(matrix.os,'windows') | |
uses: ilammy/msvc-dev-cmd@v1 | |
# with: | |
# arch: ${{ matrix.arch }} # 'x64'by default | |
- name: Install compiler | |
uses: dlang-community/setup-dlang@v1 | |
with: | |
compiler: ${{ matrix.compiler }} | |
- name: Get Dplug | |
uses: GuillaumeFalourd/[email protected] | |
with: | |
depth: 1 | |
branch: 'master' | |
owner: 'AuburnSounds' | |
repository: 'Dplug' | |
- name: Install dplug-build | |
run: | | |
dub build | |
working-directory: ./Dplug/tools/dplug-build | |
## Build plugin | |
- name: Build Inflator plugins | |
run: | | |
if ("${{ matrix.os }}" -like 'windows*') { | |
$Plugins = "-c VST3" | |
$BuildPrefix = "Windows-64b" | |
} elseif ("${{ matrix.os }}" -like 'macOS*') { | |
$Plugins = "-c VST3" | |
$BuildPrefix = "macos-64b" | |
} elseif ("${{ matrix.os }}" -like 'ubuntu*') { | |
$Plugins = "-c VST3 -c LV2" | |
$BuildPrefix = "Linux-64b" | |
} | |
$esc = '--%' | |
${{ env.DPlugBuild }} -a ${{ matrix.arch }} $esc $Plugins | |
working-directory: ./plugin | |
# Create release archives | |
- name: Create release archive for Linux | |
run: | | |
zip plugin/builds/linux-64b.zip "plugin/builds/Linux-64b-LV2/Gahel inflator.lv2/" "plugin/builds/Linux-64b-VST3/Gahel inflator.vst3/" | |
ls -R | |
# TODO: other platforms | |
# Create release for each platform | |
# Apparently pattern matching doesn't work here | |
- name: Create release for Linux | |
if: startsWith(matrix.os,'ubuntu') | |
uses: softprops/action-gh-release@v2 | |
with: | |
files: plugin/builds/linux-64b.zip | |
- name: Create release for Windows | |
if: startsWith(matrix.os,'windows') | |
uses: softprops/action-gh-release@v2 | |
with: | |
files: plugin/builds/Windows-64b.zip | |
- name: Create release for macos | |
if: startsWith(matrix.os,'macos') | |
uses: softprops/action-gh-release@v2 | |
with: | |
files: plugin/builds/macos-64b.zip | |