mirror of
https://github.com/certbot/certbot.git
synced 2026-06-07 07:42:08 -04:00
remove unnecessary extra check, just check if the init file is available
This commit is contained in:
parent
04238e050b
commit
6bde33f707
1 changed files with 6 additions and 7 deletions
|
|
@ -1,14 +1,13 @@
|
|||
#!/bin/sh -e
|
||||
|
||||
first_install="$(snapctl get first-install)"
|
||||
if [ -z "$first_install" ]; then
|
||||
snapctl set first-install="false"
|
||||
echo "first install, not doing any version comparison checks" >> "$SNAP_DATA/debuglog"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "ls $SNAP/certbot-shared:" >> "$SNAP_DATA/debuglog"
|
||||
ls $SNAP/certbot-shared >> "$SNAP_DATA/debuglog"
|
||||
|
||||
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)
|
||||
echo "cb_installed: $cb_installed" >> "$SNAP_DATA/debuglog"
|
||||
snapctl set cb-installed="$cb_installed"
|
||||
|
|
|
|||
Loading…
Reference in a new issue