Upgrade Mac CI/CD to macos-14 (#5856)

This commit is contained in:
SoftFever
2024-06-25 23:24:39 +08:00
committed by GitHub
parent 63dcf82f15
commit 7e85eb0d7d
5 changed files with 24 additions and 18 deletions

View File

@@ -75,23 +75,24 @@ jobs:
# Mac
- name: Install tools mac
if: inputs.os == 'macos-12'
if: inputs.os == 'macos-14'
run: |
brew install cmake git gettext tree ninja
brew install cmake
brew install tree ninja libtool
brew list
mkdir -p ${{ github.workspace }}/deps/build_${{inputs.arch}}
mkdir -p ${{ github.workspace }}/deps/build_${{inputs.arch}}/OrcaSlicer_dep_${{inputs.arch}}
tree ${{ github.workspace }}/deps/build_${{inputs.arch}}/OrcaSlicer_dep_${{inputs.arch}}
- name: Build slicer mac
if: inputs.os == 'macos-12'
if: inputs.os == 'macos-14'
working-directory: ${{ github.workspace }}
run: |
./build_release_macos.sh -s -n -x -a ${{inputs.arch}} -t 10.15
./build_release_macos.sh -s -n -x -a ${{inputs.arch}} -t 10.15 -1
# Thanks to RaySajuuk, it's working now
- name: Sign app and notary
if: (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/')) && inputs.os == 'macos-12'
if: (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/')) && inputs.os == 'macos-14'
working-directory: ${{ github.workspace }}
env:
BUILD_CERTIFICATE_BASE64: ${{ secrets.BUILD_CERTIFICATE_BASE64 }}
@@ -117,21 +118,21 @@ jobs:
xcrun stapler staple OrcaSlicer_Mac_${{inputs.arch}}_${{ env.ver }}.dmg
- name: Create DMG without notary
if: github.ref != 'refs/heads/main' && inputs.os == 'macos-12'
if: github.ref != 'refs/heads/main' && inputs.os == 'macos-14'
working-directory: ${{ github.workspace }}
run: |
ln -s /Applications ${{ github.workspace }}/build_${{inputs.arch}}/OrcaSlicer/Applications
hdiutil create -volname "OrcaSlicer" -srcfolder ${{ github.workspace }}/build_${{inputs.arch}}/OrcaSlicer -ov -format UDZO OrcaSlicer_Mac_${{inputs.arch}}_${{ env.ver }}.dmg
- name: Upload artifacts mac
if: inputs.os == 'macos-12'
if: inputs.os == 'macos-14'
uses: actions/upload-artifact@v4
with:
name: OrcaSlicer_Mac_${{inputs.arch}}_${{ env.ver }}
path: ${{ github.workspace }}/OrcaSlicer_Mac_${{inputs.arch}}_${{ env.ver }}.dmg
- name: Deploy Mac release
if: github.ref == 'refs/heads/main' && inputs.os == 'macos-12'
if: github.ref == 'refs/heads/main' && inputs.os == 'macos-14'
uses: WebFreak001/deploy-nightly@v3.1.0
with:
upload_url: https://uploads.github.com/repos/SoftFever/OrcaSlicer/releases/137995723/assets{?name,label}