Skip to content

feat ci: add basic macos support in gh CI #4

feat ci: add basic macos support in gh CI

feat ci: add basic macos support in gh CI #4

Workflow file for this run

name: CI
'on':
pull_request:
push:
branches:
- master
- develop
- feature/**
env:
UBSAN_OPTIONS: print_stacktrace=1
ASAN_OPTIONS: detect_odr_violation=2
jobs:
macos:
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Free disk space
run: |
df -h
# TODO
#
- name: Cache Homebrew Packages
id: cache-homebrew-packages

Check failure on line 30 in .github/workflows/macos.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/macos.yml

Invalid workflow file

You have an error in your yaml syntax on line 30
uses: actions/cache@v3
env:
cache-name: homebrew-packages
with:
path: $(brew --prefix)
key: macos-${{ env.cache-name }}-${{ hashFiles('.config/brew/Brewfile') }}
- name: Install packages
run: |
brew install $(cat scripts/docs/en/deps/macos.md | grep -v kafka)
- name: Run cmake
run: |
mkdir build_debug
cd build_debug
cmake ..
- name: Compile
run: |
pwd
cd build_debug
make -j$(nproc)
- name: Run tests (universal)
run: |
echo "UBSAN_OPTIONS=${UBSAN_OPTIONS} ASAN_OPTIONS=${ASAN_OPTIONS}"
cd build_debug
./universal/userver-universal-unittest ${{matrix.tests-flags}}