-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
For a long time, I get issues from new users with QArchive compile errors, mostly from Windows because it's not developer friendly. Also most of the users want to try this out with ease, so I introduce prebuilds for Windows users for now. They should be able to use QArchive without compiling. I also include symbolic constants for QArchive which gives version information. We also reduce tests on ubuntu since it seems redundant and makes tests slow, planning to remove more redundant test to increase test speeds. We also have a special commit which will make a new release itself. I have to run scripts/bump_version.sh to make a new relesae from now on, this is in place to avoid updating the version number in CMake files and meson build. (Like i did in the previous version v2.2.8, which has v2.2.7 in cmake files) Signed-off-by: Divya Antony J R <[email protected]>
- Loading branch information
Showing
9 changed files
with
1,356 additions
and
7 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,129 @@ | ||
name: Deploy Release | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
permissions: | ||
contents: write | ||
|
||
jobs: | ||
check: | ||
runs-on: ubuntu-latest | ||
outputs: | ||
deploy: ${{ steps.git.outputs.deploy }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Install Python3 | ||
run: | | ||
sudo apt install -y python3 | ||
- id: git | ||
name: Check Commit Message | ||
run: | | ||
git clone https://github.com/antony-jr/QArchive qarc | ||
cd qarc | ||
git tag > /tmp/tags.txt | ||
cd .. | ||
rm -rf qarc | ||
cat /tmp/tags.txt | ||
result=$(python3 scripts/check.py "$(git log -1 --pretty=%B)" "/tmp/tags.txt") | ||
echo "deploy=$result" >> $GITHUB_OUTPUT | ||
- id: make_rel | ||
if: steps.git.outputs.deploy != 'false' | ||
name: Make Relase | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
tag: ${{ steps.git.outputs.deploy}} | ||
run: | | ||
git show -s --format="%b" | head -n -2 > body.md | ||
gh release create "$tag" \ | ||
--repo="$GITHUB_REPOSITORY" \ | ||
--title="$tag" \ | ||
--notes-file body.md | ||
notify: | ||
runs-on: ubuntu-latest | ||
name: Notify Qt Modules Repository | ||
needs: [windows-msvc] | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Trigger | ||
env: | ||
GITHUB_TOKEN: $${{ secrets.QTMODULES_TOKEN }} | ||
run: gh api repos/antony-jr/qtmodules/dispatches --raw-field event_type=qarchive | ||
|
||
windows-msvc: | ||
runs-on: windows-2019 | ||
needs: check | ||
if: needs.check.outputs.deploy != 'false' | ||
name: windows-msvc-v${{ matrix.toolset }}-${{ matrix.arch }}-qt-${{ matrix.qt_version }}-${{ matrix.build_type }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
qt_version: [5.15.2] | ||
arch: [x64, x86] | ||
build_type: [Release, Debug] | ||
toolset: [14.0, 14.2] | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: CMake | ||
uses: lukka/get-cmake@latest | ||
|
||
- name: MSVC | ||
uses: TheMrMilchmann/setup-msvc-dev@v2 | ||
with: | ||
arch: ${{ matrix.arch }} | ||
toolset: ${{ matrix.toolset }} | ||
|
||
- name: Install Conan | ||
id: conan | ||
uses: turtlebrowser/get-conan@main | ||
with: | ||
version: 1.62.0 | ||
|
||
- name: Make Output Directory | ||
run: | | ||
mkdir -p ${{github.workspace}}/output/QArchive | ||
mkdir -p ${{github.workspace}}/upload | ||
- name: Build | ||
run: | | ||
set QT_VERSION=${{ matrix.qt_version }} | ||
python3 scripts/write_conan.py | ||
mkdir build | ||
cd build | ||
cmake -DQARCHIVE_QT_VERSION_MAJOR=5 -DQARCHIVE_CONAN_BUILD=ON -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} .. | ||
cmake --build . --config ${{ matrix.build_type }} | ||
cmake --install . --prefix=${{ github.workspace }}/output/QArchive --config ${{ matrix.build_type }} | ||
cd .. | ||
- name: Check Contents | ||
working-directory: ${{github.workspace}} | ||
run: ls -R ${{ github.workspace }}/output | ||
|
||
- name: Zip Files | ||
run: | | ||
cd ${{ github.workspace }}/output/ | ||
7z a ${{ github.workspace }}/upload/windows-msvc-v${{ matrix.toolset }}-qt-${{ matrix.qt_version }}-${{ matrix.arch }}-${{ matrix.build_type }}.zip QArchive | ||
- id: upload_rel | ||
name: Upload Asset | ||
working-directory: ${{ github.workspace }}/upload | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
tag: ${{ needs.check.outputs.deploy }} | ||
run: | | ||
gh release upload "$tag" \ | ||
--repo="$GITHUB_REPOSITORY" \ | ||
windows-msvc-v${{ matrix.toolset }}-qt-${{ matrix.qt_version }}-${{ matrix.arch }}-${{ matrix.build_type }}.zip |
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
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
Oops, something went wrong.