Update README.md #16
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 and Package SafronCLI | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Dependencies (Linux) | |
if: runner.os == 'Linux' | |
run: sudo apt-get update && sudo apt-get install -y libcurl4-openssl-dev | |
- name: Install Dependencies (macOS) | |
if: runner.os == 'macOS' | |
run: brew install --formula cmake curl | |
- name: Configure CMake (Linux and macOS) | |
if: runner.os != 'Windows' | |
run: | | |
mkdir -p build | |
cd build | |
cmake .. | |
- name: Build (Linux and macOS) | |
if: runner.os != 'Windows' | |
run: | | |
cd build | |
cmake --build . | |
- name: Package | |
run: | | |
cd build | |
cpack | |
- name: Upload Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: safron-${{ runner.os }} | |
path: build/*.{tar.gz,zip} |