Skip to content

Commit

Permalink
Implemented CI/CD pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
judaew committed Feb 18, 2024
1 parent 3c0d961 commit 79e4734
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Build and Release

on:
push:
branches:
- main

jobs:
build:
runs-on: macos-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Build for x86_64
run: swift build -c release --arch x86_64 -Xswiftc -cross-module-optimization

- name: Build for arm64
run: swift build -c release --arch arm64 -Xswiftc -cross-module-optimization

- name: Archive artifacts for x86_64
run: |
mkdir -p release/x86_64
cp -r .build/x86_64-apple-macosx/release/pbcopyplus release/x86_64/
if: success()

- name: Archive artifacts for arm64
run: |
mkdir -p release/arm64
cp -r .build/arm64-apple-macosx/release/pbcopyplus release/arm64/
if: success()

- name: Upload Release Assets
uses: actions/upload-artifact@v2
with:
name: release
path: release

0 comments on commit 79e4734

Please sign in to comment.