Skip to content
Merged
Show file tree
Hide file tree
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
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
104 changes: 54 additions & 50 deletions .github/workflows/cppcmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,75 +2,79 @@ name: C/C++ CI

on:
push:
branches:
- main
tags:
- v*.*
- v*.*
pull_request:
branches:
- main
- main

jobs:
build:
name: ${{ matrix.config.name }}
permissions:
contents: read
runs-on: ${{ matrix.config.os }}
strategy:
matrix:
config:
- {name: "ubuntu-latest", os: ubuntu-latest, cmake_extra: ""}
- {name: "windows-x64", os: windows-latest, cmake_extra: "-T v143"}
- {name: "windows-32", os: windows-latest, cmake_extra: "-T v143 -A Win32"}
- {name: "macOS-latest", os: macOS-latest, cmake_extra: ""}
- { name: "ubuntu-latest", os: ubuntu-latest, cmake_extra: "" }
- { name: "windows-x64", os: windows-latest, cmake_extra: "-T v143" }
- {
name: "windows-x32",
os: windows-latest,
cmake_extra: "-T v143 -A Win32",
}
- { name: "macOS-latest", os: macos-latest, cmake_extra: "" }
fail-fast: false

steps:
- uses: actions/checkout@v3

- name: CMake version
run: cmake --version

- name: Configure CMake
shell: bash
run: |
cmake -S . -B build ${{ matrix.config.cmake_extra }} -DCMAKE_INSTALL_PREFIX=${PWD}/build/install -DCPACK_PACKAGE_DIRECTORY=${PWD}/build/package -DCPACK_DEBIAN_PACKAGE_SHLIBDEPS=ON

- name: Make
run: cmake --build build --config Release -j

- name: Install
run: cmake --build build --config Release -j --target install

- name: Package
run: cmake --build build --config Release -j --target package

- name: Upload Artifact
uses: actions/upload-artifact@v3
# if: "!startsWith(github.ref, 'refs/heads')"
with:
name: pkg-${{ matrix.config.name }}
path: |
- uses: actions/checkout@v6

- name: CMake version
run: cmake --version

- name: Configure CMake
shell: bash
run: |
cmake -S . -B build ${{ matrix.config.cmake_extra }} -DCMAKE_INSTALL_PREFIX=${PWD}/build/install -DCPACK_PACKAGE_DIRECTORY=${PWD}/build/package -DCPACK_DEBIAN_PACKAGE_SHLIBDEPS=ON

- name: Make
run: cmake --build build --config Release -j

- name: Install
run: cmake --build build --config Release -j --target install

- name: Package
run: cmake --build build --config Release -j --target package

- name: Upload Artifact
uses: actions/upload-artifact@v7
with:
name: pkg-${{ matrix.config.name }}
path: |
build/package/*.deb
build/package/*.tar.bz2
build/package/*.zip


release:
needs: build
if: startsWith(github.ref, 'refs/tags/')
runs-on: ubuntu-latest
permissions:
contents: write
steps:

- name: Download Artifacts
if: startsWith(github.ref, 'refs/tags/')
uses: actions/download-artifact@v3

- name: Create Release
if: startsWith(github.ref, 'refs/tags/')
id: create_release
uses: softprops/action-gh-release@v1
env:
- name: Download Artifacts
uses: actions/download-artifact@v8

- name: Create Release
id: create_release
uses: softprops/action-gh-release@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# tag_name: ${{ github.ref }} # ${{ github.ref }} is default
name: Release ${{ github.ref }}
draft: false
prerelease: false
# body_path: CHANGELOG.txt
files: 'pkg-*/*'
with:
name: ${{ github.ref_name }}
draft: false
prerelease: false
files: "pkg-*/*"