extend copyright #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: Build | |
on: | |
- pull_request | |
- push | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: true | |
matrix: | |
os: | |
- ubuntu-20.04 | |
- macos-13 | |
- windows-2019 | |
qt: | |
- version: '5.9.9' | |
modules: 'qtscript' | |
- version: '6.2.3' | |
modules: 'qt5compat' | |
- version: '6.7.2' | |
modules: 'qt5compat' | |
release: true | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Dependencies | |
if: runner.os == 'Linux' | |
run: | | |
sudo apt update | |
sudo apt -y install cmake | |
- name: Install Qt | |
uses: jurplel/install-qt-action@v4 | |
with: | |
version: ${{ matrix.qt.version }} | |
dir: ${{ github.workspace }}/qt | |
modules: ${{ matrix.qt.modules }} | |
cache: true | |
- name: Build | |
run: | | |
cmake -B build | |
cmake --build build --config Release | |
- name: Package | |
id: package | |
if: matrix.qt.release == true && runner.os == 'Windows' | |
run: | | |
cd build | |
cpack | |
- name: Upload Artifacts | |
uses: actions/upload-artifact@v4 | |
if: ${{ steps.package.outcome == 'success' }} | |
with: | |
name: ${{ matrix.os }}-Package | |
path: | | |
build/QTerm-*.exe | |
build/QTerm-*.dmg | |
release: | |
needs: build | |
runs-on: ubuntu-20.04 | |
if: github.event_name == 'push' && startsWith(github.ref,'refs/tags/') | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Download Artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
path: dist | |
merge-multiple: true | |
- name: Create Release | |
run: | | |
awk -v version=${{ github.ref_name }} '$0 == version {p=1;} NF==0 {p=0} p' RELEASE_NOTES > _notes | |
gh release create ${{ github.ref_name }} -F _notes dist/QTerm-* | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |