Skip to content

make it always write all log messages into OpenSource.log #105

make it always write all log messages into OpenSource.log

make it always write all log messages into OpenSource.log #105

Workflow file for this run

name: CMake release build
on: [push, pull_request]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, ubuntu-latest]
steps:
- name: Apt update
if: matrix.os == 'ubuntu-latest'
run: sudo apt update
- name: Install dependencies
if: matrix.os == 'ubuntu-latest'
run: sudo apt install libxfixes-dev mesa-common-dev libgl1-mesa-dev
- name: Checkout
uses: actions/checkout@v2
with:
submodules: true
- name: Create build dir
run: cmake -E make_directory ${{ runner.workspace }}/build
- name: Configure
working-directory: ${{ runner.workspace }}/build
run: cmake ${{ github.workspace }} -DCMAKE_BUILD_TYPE=Release
- name: Build
working-directory: ${{ runner.workspace }}/build
run: cmake --build . --config Release
- name: Prepare release archive
if: matrix.os == 'windows-latest'
run: |
cmake -E make_directory ${{ runner.workspace }}/OpenSource-win64
cmake -E copy ${{ github.workspace }}/misc/hl1.cfg ${{ github.workspace }}/misc/hl2.cfg ${{ github.workspace }}/misc/hl2eps.cfg ${{ github.workspace }}/misc/hl1.bat ${{ github.workspace }}/misc/hl2.bat ${{ github.workspace }}/misc/hl2eps.bat ${{ runner.workspace }}/build/Release/OpenSource.exe ${{ github.workspace }}/README.md ${{ runner.workspace }}/OpenSource-win64
powershell Compress-Archive ${{ runner.workspace }}/OpenSource-win64/* ${{ runner.workspace }}/OpenSource-win64.zip
- name: Upload artifacts
if: matrix.os == 'windows-latest'
uses: actions/upload-artifact@v3
with:
name: OpenSource-win64
path: ${{ runner.workspace }}/OpenSource-win64
- name: Make GitHub release if tagged
if: matrix.os == 'windows-latest' && startsWith(github.ref, 'refs/tags/v')
uses: softprops/action-gh-release@v0.1.5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# Note-worthy description of changes in release
#body: # optional
# Path to load note-worthy description of changes in release from
#body_path: # optional
# Gives the release a custom name. Defaults to tag name
#name: # optional
# Creates a draft release. Defaults to false
draft: true # optional
# Identify the release as a prerelease. Defaults to false
prerelease: true # optional
# Newline-delimited list of path globs for asset files to upload
# TODO prepare proper zip with useful things
files: ${{ runner.workspace }}/OpenSource-win64.zip