Skip to content

Commit

Permalink
CI: use system Python 2.7.
Browse files Browse the repository at this point in the history
  • Loading branch information
jwilk committed Aug 10, 2023
1 parent d8442dd commit 673d896
Showing 1 changed file with 21 additions and 24 deletions.
45 changes: 21 additions & 24 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,26 @@ jobs:
include:
- gamera: gamera-3.4.3
pillow: pillow-3.4.2
container: python:2.7
os: ubuntu-20.04
- gamera: gamera-3.4.4
container: python:2.7
runs-on: ubuntu-latest
container: ${{matrix.container}}
defaults:
run:
shell: bash
os: ubuntu-20.04
runs-on: ${{matrix.os}}
steps:
- uses: actions/checkout@v3
- name: set up APT
run: |
printf '\n\nPackage: *\nPin: release o=Ubuntu\nPin-Priority: 9999\n' | tee -a /etc/apt/preferences
printf 'Apt::Install-Recommends "false";\n' | tee -a /etc/apt/apt.conf
apt-get update
printf '\n\nPackage: *\nPin: release o=Ubuntu\nPin-Priority: 9999\n' | sudo tee -a /etc/apt/preferences
printf 'Apt::Install-Recommends "false";\n' | sudo tee -a /etc/apt/apt.conf
sudo apt-get update
- name: set up Python 2.7
run: |
sudo apt-get install -f python-is-python2 python2-dev
curl https://bootstrap.pypa.io/pip/2.7/get-pip.py > get-pip.py
sudo python get-pip.py
rm get-pip.py
- name: apt install deps
run:
apt-get install -y
sudo apt-get install -y
djvulibre-bin
docbook-xml
docbook-xsl
Expand All @@ -47,11 +49,11 @@ jobs:
CC: ${{matrix.cc || 'gcc'}}
- name: apt install GCC
run:
apt-get install -y ${{env.cc}} ${{env.cxx}}
sudo apt-get install -y ${{env.cc}} ${{env.cxx}}
if: ${{matrix.cc}}
- name: install ccache
run: |
apt-get install -y ccache
sudo apt-get install -y ccache
echo "/usr/lib/ccache:$PATH" >> $GITHUB_PATH
- name: check ccache setup
run: |
Expand All @@ -62,9 +64,9 @@ jobs:
with:
path: ~/.ccache
key:
ccache-${{matrix.container}}-${{env.cc}}-${{matrix.gamera}}-${{matrix.pyexiv2}}
ccache-${{matrix.os}}-${{env.cc}}-${{matrix.gamera}}-${{matrix.pyexiv2}}
restore-keys:
ccache-${{matrix.container}}-${{env.cc}}-${{matrix.gamera}}-
ccache-${{matrix.os}}-${{env.cc}}-${{matrix.gamera}}-
- name: download Gamera
run: |
gamera=${{matrix.gamera}}
Expand All @@ -91,7 +93,7 @@ jobs:
- name: install Gamera
run: |
cd deps/gamera-*/
python setup.py install
python setup.py install --user
- name: remove Gamera source
run:
rm -rf deps
Expand All @@ -104,20 +106,15 @@ jobs:
python -m pip install python-xmp-toolkit
- name: install pyexiv2
run: |
apt-get install -y libboost-python-dev libexiv2-dev
sudo apt-get install -y libboost-python-dev libexiv2-dev
python -m pip install --verbose git+https://github.com/escaped/pyexiv2
if: ${{matrix.pyexiv2}}
- name: set up PyGI
run: |
cp -a /usr/lib/python2.7/dist-packages/gi /usr/local/lib/python2.7/site-packages/
mv -v /usr/local/lib/python2.7/site-packages/gi/_gi{.x86_64-linux-gnu,}.so
- name: install nose
run:
python -m pip install nose
- name: run tests
run:
runuser -u nobody --
make test
make test
continue-on-error: ${{(matrix.broken && true) || false}}
- name: run pydiatra
run: |
Expand All @@ -144,7 +141,7 @@ jobs:
didjvu --help
- name: APT install man-db
run: |
apt-get install -y man-db
sudo apt-get install -y man-db
- name: check whether the man page was installed correctly
env:
MANWIDTH: 80
Expand Down

0 comments on commit 673d896

Please sign in to comment.