Skip to content

Commit

Permalink
release #50
Browse files Browse the repository at this point in the history
  • Loading branch information
yousefvand committed Nov 29, 2024
1 parent 27d88fd commit 97b4444
Showing 1 changed file with 13 additions and 18 deletions.
31 changes: 13 additions & 18 deletions .github/workflows/cmake-multi-platform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,18 +41,18 @@ jobs:
-DCMAKE_BUILD_TYPE=Release \
-G "Ninja" \
-S "${{ github.workspace }}"
- name: Build application (Ubuntu)
- name: Build Notepad-- (Ubuntu)
if: matrix.os == 'ubuntu-latest'
run: cmake --build "${{ github.workspace }}/build" --config Release
- name: Package application (Ubuntu)
- name: Package Notepad-- (Ubuntu)
if: matrix.os == 'ubuntu-latest'
run: |
BUILD_DIR="${{ github.workspace }}/build"
TEMP_DIR="/tmp/build_copy"
rm -rf $TEMP_DIR
rsync -a "$BUILD_DIR/" "$TEMP_DIR/"
cd $TEMP_DIR
tar -czvf application.tar.gz ./*
tar -czvf Notepad--.tar.gz ./*
# macOS Section
- name: Install dependencies (macOS)
Expand All @@ -66,23 +66,18 @@ jobs:
-DCMAKE_BUILD_TYPE=Release \
-G "Ninja" \
-S "${{ github.workspace }}"
- name: Build application (macOS)
- name: Build Notepad-- (macOS)
if: matrix.os == 'macos-latest'
run: cmake --build "${{ github.workspace }}/build" --config Release
- name: Package application (macOS)
- name: Package Notepad-- (macOS)
if: matrix.os == 'macos-latest'
run: |
cd "${{ github.workspace }}/build"
hdiutil create -volname Application -srcfolder . -ov -format UDZO application.dmg
zip application.zip application.dmg
hdiutil create -volname Notepad-- -srcfolder . -ov -format UDZO Notepad--.dmg
zip Notepad--.zip Notepad--.dmg
# Windows Section
- name: Install dependencies (Windows)
if: matrix.os == 'windows-latest'
run: |
choco install ninja -y
choco install cmake --installargs 'ADD_CMAKE_TO_PATH=System' -y
- name: Install Qt using Install Qt Action
if: matrix.os == 'windows-latest'
uses: jurplel/install-qt-action@v4
with:
Expand All @@ -101,21 +96,21 @@ jobs:
-S "${{ github.workspace }}"
shell: cmd

- name: Build application (Windows)
- name: Build Notepad-- (Windows)
if: matrix.os == 'windows-latest'
run: cmake --build "${{ github.workspace }}\\build" --config Release

- name: Package application (Windows)
- name: Package Notepad-- (Windows)
if: matrix.os == 'windows-latest'
run: |
cd "${{ github.workspace }}\\build"
Compress-Archive -Path . -DestinationPath application.zip
Compress-Archive -Path . -DestinationPath Notepad--.zip
# Upload Artifacts
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: application-${{ matrix.os }}
name: Notepad---${{ matrix.os }}
path: |
${{ github.workspace }}/build/application.${{ matrix.artifact_extension }}
/tmp/build_copy/application.tar.gz
${{ github.workspace }}/build/Notepad--.${{ matrix.artifact_extension }}
/tmp/build_copy/Notepad--.tar.gz

0 comments on commit 97b4444

Please sign in to comment.