mirror of
https://github.com/certbot/certbot.git
synced 2026-06-09 00:32:12 -04:00
20 lines
521 B
Text
20 lines
521 B
Text
|
|
#!/bin/bash
|
||
|
|
set -e
|
||
|
|
join() {
|
||
|
|
sep=$1
|
||
|
|
first=$2
|
||
|
|
if [ "$first" != "" ]; then
|
||
|
|
shift 2
|
||
|
|
echo -n "${first}"
|
||
|
|
for item in "$@"; do echo -n "${sep}${item}"; done
|
||
|
|
echo
|
||
|
|
fi
|
||
|
|
}
|
||
|
|
|
||
|
|
paths=$(for plugin_snap in $(snap connections certbot|sed -n '2,$p'|awk '$1=="content[certbot-1]"{print $3}'|cut -d: -f1); do echo /snap/$plugin_snap/current/lib/python3.6/site-packages; done)
|
||
|
|
export PYTHONPATH=$(join : $PYTHONPATH $paths)
|
||
|
|
if [ -z "$PYTHONPATH" ]; then
|
||
|
|
unset PYTHONPATH
|
||
|
|
fi
|
||
|
|
exec certbot "$@"
|