mirror of
https://github.com/certbot/certbot.git
synced 2026-06-06 23:32:06 -04:00
find and save certbot version on the certbot side
This commit is contained in:
parent
1825833325
commit
4cbdfbad6f
2 changed files with 6 additions and 4 deletions
|
|
@ -5,7 +5,7 @@ if [ ! -f "$SNAP/certbot-shared/__init__.py" ]; then
|
|||
echo "No certbot version available; not doing version comparison check" >> "$SNAP_DATA/debuglog"
|
||||
exit 0
|
||||
fi
|
||||
cb_installed=$(grep -oP "__version__ = '\K.*(?=')" $SNAP/certbot-shared/__init__.py)
|
||||
cb_installed=$(cat $SNAP/certbot-shared/certbot-version.txt)
|
||||
|
||||
# get required certbot version for plugin
|
||||
cb_required=$(grep -oP "certbot>=\K.*(?=')" $SNAP/setup.py)
|
||||
|
|
|
|||
|
|
@ -85,9 +85,11 @@ parts:
|
|||
shared-metadata:
|
||||
plugin: dump
|
||||
source: .
|
||||
stage: [certbot-metadata/__init__.py]
|
||||
organize:
|
||||
$SNAPCRAFT_PART_SRC/certbot/certbot/__init__.py: certbot-metadata/__init__.py
|
||||
override-pull: |
|
||||
snapcraftctl pull
|
||||
mkdir -p certbot-metadata
|
||||
grep -oP "__version__ = '\K.*(?=')" $SNAPCRAFT_PART_SRC/certbot/certbot/__init__.py > certbot-metadata/certbot-version.txt
|
||||
stage: [certbot-metadata/certbot-version.txt]
|
||||
|
||||
plugs:
|
||||
plugin:
|
||||
|
|
|
|||
Loading…
Reference in a new issue