1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mautrix_signal_ynh.git synced 2024-09-03 19:46:07 +02:00
mautrix_signal_ynh/scripts/_common.sh

41 lines
1.3 KiB
Bash
Raw Normal View History

2021-01-04 12:14:25 +01:00
#!/bin/bash
#=================================================
# COMMON VARIABLES
#=================================================
signald_data="/var/lib/signald"
signald_exe="/usr/bin/signald"
signald_user="signald"
2024-02-26 13:49:53 +01:00
enable_relaybot=true
2022-09-04 22:28:27 +02:00
2021-01-04 12:14:25 +01:00
#=================================================
# PERSONAL HELPERS
#=================================================
2024-02-26 13:49:53 +01:00
_install_rustup() {
export PATH="$PATH:$install_dir/.cargo/bin:$install_dir/.local/bin:/usr/local/sbin"
if [ -e "$install_dir/.rustup" ]; then
ynh_exec_as "$app" env "PATH=$PATH" rustup update
else
ynh_exec_as "$app" bash -c 'curl -sSf -L https://static.rust-lang.org/rustup.sh | sh -s -- -y --default-toolchain=stable --profile=minimal'
fi
}
_mautrix_signal_build_venv() {
python3 -m venv "$install_dir/venv"
"$install_dir/venv/bin/pip3" install --upgrade pip setuptools wheel
"$install_dir/venv/bin/pip3" install --upgrade \
"$install_dir/src/mautrix-signal.tar.gz[metrics,e2be,formattednumbers,qrlink,stickers]"
}
2021-01-04 12:14:25 +01:00
#=================================================
# EXPERIMENTAL HELPERS
#=================================================
#=================================================
# FUTURE OFFICIAL HELPERS
#=================================================