Install gpg python bindings #149
Workflow file for this run
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
# WARNING: This workflow is deactivated until the gpg dependency problem from | |
# issue 1630 (see | |
# https://github.com/pazz/alot/issues/1630#issuecomment-1938174029 and | |
# onwards) is fixed. The problem was introduced in c1137ea9: the gpg | |
# dependency is required with version > 1.10.0 and such a version is not | |
# currently available on PyPI but must be build from hand. | |
name: Run tests | |
on: | |
- push | |
- pull_request | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
# https://notmuchmail.org/releases/ notmuch-0.38.3.tar.xz | |
- name: Install dependencies for the gpg and notmuch python package | |
run: | | |
set -e | |
sudo apt-get update | |
sudo apt-get install -y --no-install-recommends \ | |
libgpgme-dev libxapian-dev libgmime-3.0-dev libtalloc-dev swig | |
env: | |
DEBIAN_FRONTEND: noninteractive | |
# - name: Update the gpg dependency in the pyproject file | |
# # 1.16 is the version of gpgme that is currently available in ubuntu-latest (currently 22.04) | |
# run: sed -i 's|gpg>1.10.0|gpg @ https://dev.gnupg.org/source/gpgme.git@gpgme-1.16.0|' pyproject.toml | |
- name: Clone the gpgme repository | |
run: git clone --depth 1 --branch gpgme-1.17.0 https://dev.gnupg.org/source/gpgme.git gpgme | |
- name: Build the gpgme bindings | |
run: | | |
set -e | |
./autogen.sh | |
./configure --enable-maintainer-mode --enable-languages=python | |
make | |
sudo make install | |
working-directory: gpgme | |
- name: debug gpgme result | |
run: find | |
working-directory: gpgme | |
- name: Install gpgme python bindings | |
run: pip install . | |
working-directory: gpgme/lang/python | |
- name: clone the notmuch repository | |
run: git clone --depth 1 https://git.notmuchmail.org/git/notmuch notmuch | |
- name: build the notmuch bindings | |
run: | | |
set -e | |
# Make and install the library. | |
./configure --without-bash-completion \ | |
--without-api-docs \ | |
--without-emacs \ | |
--without-desktop \ | |
--without-ruby \ | |
--without-zsh-completion | |
make | |
sudo make install | |
working-directory: notmuch | |
- name: Install notmuch python bindings | |
run: pip install . | |
working-directory: notmuch/bindings/python-cffi | |
- name: Install dependencies | |
run: pip install . | |
- name: Run tests | |
run: python3 -m unittest --verbose |