mirror of
https://github.com/YunoHost-Apps/searxng_ynh.git
synced 2024-09-03 20:26:00 +02:00
Refractor
This commit is contained in:
parent
4141d4355b
commit
69c1c0f52b
1 changed files with 5 additions and 4 deletions
|
@ -16,9 +16,10 @@ myynh_source_searxng () {
|
||||||
|
|
||||||
# Download source
|
# Download source
|
||||||
sudo -i -u $app bash << EOF
|
sudo -i -u $app bash << EOF
|
||||||
|
mkdir "$install_dir/searxng-src"
|
||||||
git clone -n "$repo_fullpath" "$install_dir/searxng-src"
|
git clone -n "$repo_fullpath" "$install_dir/searxng-src"
|
||||||
pushd "$install_dir/searxng-src"
|
pushd "$install_dir/searxng-src"
|
||||||
ynh_exec_fully_quiet git checkout "$commit_sha"
|
git checkout "$commit_sha"
|
||||||
popd
|
popd
|
||||||
EOF
|
EOF
|
||||||
}
|
}
|
||||||
|
@ -49,14 +50,14 @@ EOF
|
||||||
myynh_upgrade_venv_directory () {
|
myynh_upgrade_venv_directory () {
|
||||||
|
|
||||||
# Remove old python links before recreating them
|
# Remove old python links before recreating them
|
||||||
find "$install_dir/bin/" -type l -name 'python*' \
|
find "$install_dir/searxng-pyenv/bin/" -type l -name 'python*' \
|
||||||
-exec bash -c 'rm --force "$1"' _ {} \;
|
-exec bash -c 'rm --force "$1"' _ {} \;
|
||||||
|
|
||||||
# Remove old python directories before recreating them
|
# Remove old python directories before recreating them
|
||||||
find "$install_dir/lib/" -mindepth 1 -maxdepth 1 -type d -name "python*" \
|
find "$install_dir/searxng-pyenv/lib/" -mindepth 1 -maxdepth 1 -type d -name "python*" \
|
||||||
-not -path "*/python${py_required_version%.*}" \
|
-not -path "*/python${py_required_version%.*}" \
|
||||||
-exec bash -c 'rm --force --recursive "$1"' _ {} \;
|
-exec bash -c 'rm --force --recursive "$1"' _ {} \;
|
||||||
find "$install_dir/include/site/" -mindepth 1 -maxdepth 1 -type d -name "python*" \
|
find "$install_dir/searxng-pyenv/include/site/" -mindepth 1 -maxdepth 1 -type d -name "python*" \
|
||||||
-not -path "*/python${py_required_version%.*}" \
|
-not -path "*/python${py_required_version%.*}" \
|
||||||
-exec bash -c 'rm --force --recursive "$1"' _ {} \;
|
-exec bash -c 'rm --force --recursive "$1"' _ {} \;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue