.github/downstream.d/certbot-josepy.sh
raw| 1 | #!/bin/bash -ex |
| 2 | |
| 3 | case "${1}" in |
| 4 | install) |
| 5 | git clone --depth=1 https://github.com/certbot/josepy |
| 6 | cd josepy |
| 7 | git rev-parse HEAD |
| 8 | curl -sSL https://install.python-poetry.org | python3 - |
| 9 | "${HOME}/.local/bin/poetry" self add poetry-plugin-export |
| 10 | "${HOME}/.local/bin/poetry" export -f constraints.txt --dev --without-hashes -o constraints.txt |
| 11 | pip install -e . pytest -c constraints.txt |
| 12 | ;; |
| 13 | run) |
| 14 | cd josepy |
| 15 | pytest tests |
| 16 | ;; |
| 17 | *) |
| 18 | exit 1 |
| 19 | ;; |
| 20 | esac |