Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 63 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
name: build Community Shaders for dist
on:
push:
tags:
- 'v*'
workflow_dispatch:
permissions:
contents: write

env:
VCPKG_COMMIT_ID: 9edb1b8e590cc086563301d735cae4b6e732d2d2
CMAKE_BUILD_TYPE: Release

jobs:
compile:
name: build plugin
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
with:
submodules: 'true'

- uses: actions/cache@v3
with:
path: |
build
key: ${{ runner.os }}-cmake-${{ hashFiles('CMakeLists.txt') }}
restore-keys: |
${{ runner.os }}-cmake-
${{ runner.os }}-

- uses: ilammy/msvc-dev-cmd@v1.10.0

- uses: lukka/run-vcpkg@v11
with:
vcpkgGitCommitId: ${{ env.VCPKG_COMMIT_ID }}

- name: check the stamp file
run: cmake -S . --preset=ALL --check-stamp-file "build\CMakeFiles\generate.stamp"

- name: run cmake to build
run: cmake --build build --config Release

- name: copy build artifacts into place
shell: bash
run: |
mkdir -p CommunityShaders/SKSE/Plugins
cp -p build/release/*.dll CommunityShaders/SKSE/Plugins
cp -p build/release/*.pdb CommunityShaders/SKSE/Plugins
cp -rp package/* CommunityShaders/

- name: 7zip compress it
run: 7z a "CommunityShaders_${{ github.ref_name }}.7z" ./CommunityShaders

- name: create a tagged release and upload the archive
uses: ncipollo/release-action@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
name: Community Shaders ${{ github.ref_name }}
tag: ${{ github.ref_name }}
draft: true
artifacts: "CommunityShaders_${{ github.ref_name }}.7z"