-
-
Notifications
You must be signed in to change notification settings - Fork 11
37 lines (35 loc) · 1.29 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: CI
on: [ push, pull_request ]
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Install dependencies (Ubuntu)
if: ${{ matrix.os == 'ubuntu-latest' }}
run: sudo apt-get -y install python3 help2man imagemagick
- name: Install dependencies (macOS)
if: ${{ matrix.os == 'macos-latest' }}
run: |
brew install libpaper tox imagemagick
# Prepend optional brew binary directories to PATH
echo "$(brew --prefix)/opt/imagemagick/bin:$(brew --prefix)/opt/python/libexec/bin" >> $GITHUB_PATH
- name: Install libpaper from source
if: ${{ matrix.os == 'ubuntu-latest' }}
run: |
git clone https://github.com/rrthomas/libpaper.git ~/libpaper
cd ~/libpaper && ./bootstrap && ./configure --quiet --enable-silent-rules && sudo make install
if test ${{ matrix.os }} = ubuntu-latest; then sudo ldconfig; fi
paper --version
- name: Build
run: |
if [ "$RUNNER_OS" = "macOS" ]; then
export MAGICK_HOME="$(brew --prefix)/opt/imagemagick/"
tox --skip-missing-interpreters -e py311,py312
else
pip install tox
tox --skip-missing-interpreters
fi