This commit is contained in:
43
.gitea/workflows/build.yaml
Normal file
43
.gitea/workflows/build.yaml
Normal file
@@ -0,0 +1,43 @@
|
||||
# This starter workflow is for a CMake project running on a single platform. There is a different starter workflow if you need cross-platform coverage.
|
||||
# See: https://github.com/actions/starter-workflows/blob/main/ci/cmake-multi-platform.yml
|
||||
name: CMake on a single platform
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "master" ]
|
||||
|
||||
env:
|
||||
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
|
||||
BUILD_TYPE: Release
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: archlinux
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Stop previous server if running
|
||||
run: ~/stop.sh server-example || echo service was not started
|
||||
|
||||
- name: clear old installation
|
||||
run: xargs rm < ~/build/server-example/install_manifest.txt || echo previous installation not found
|
||||
|
||||
- name: clear old builddir
|
||||
run: rm -rf ~/build/server-example || echo previous installation not found
|
||||
|
||||
- name: update submodule
|
||||
run: git submodule update --init --recursive
|
||||
|
||||
- name: Configure CMake
|
||||
run: cmake -B ~/build/server-example -DCMAKE_INSTALL_PREFIX=~/.local
|
||||
|
||||
- name: Build
|
||||
run: cmake --build ~/build/server-example
|
||||
|
||||
- name: install
|
||||
run: make -C ~/build/server-example install
|
||||
|
||||
- name: Start server
|
||||
run: ~/start.sh server-example
|
||||
|
Reference in New Issue
Block a user