mirror of
https://github.com/veeso/termscp.git
synced 2026-04-12 21:21:33 -07:00
chore: Install with apt if installed
This commit is contained in:
@@ -221,20 +221,18 @@ install_on_debian() {
|
|||||||
local pkg_manager
|
local pkg_manager
|
||||||
if has apt; then
|
if has apt; then
|
||||||
pkg_manager="apt"
|
pkg_manager="apt"
|
||||||
elif has apt-get; then
|
elif has "apt-get"; then
|
||||||
pkg_manager="apt-get"
|
pkg_manager="apt-get"
|
||||||
elif has dpkg; then
|
|
||||||
pkg_manager="dpkg"
|
|
||||||
else
|
else
|
||||||
try_with_cargo "we couldn't find any suitable package manager on your debian distribution" && return $?
|
pkg_manager="dpkg"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
info "Detected $pkg_manager on your system"
|
||||||
case "${ARCH}" in
|
case "${ARCH}" in
|
||||||
x86_64) DEB_URL="$DEB_URL_AMD64" ;;
|
x86_64) DEB_URL="$DEB_URL_AMD64" ;;
|
||||||
aarch64) DEB_URL="$DEB_URL_AARCH64" ;;
|
aarch64) DEB_URL="$DEB_URL_AARCH64" ;;
|
||||||
*) try_with_cargo "we don't distribute packages for ${ARCH} at the moment" && return $? ;;
|
*) try_with_cargo "we don't distribute packages for ${ARCH} at the moment" && return $? ;;
|
||||||
esac
|
esac
|
||||||
info "Detected $pkg_manager on your system"
|
|
||||||
info "Installing ${GREEN}termscp${NO_COLOR} via Debian package"
|
info "Installing ${GREEN}termscp${NO_COLOR} via Debian package"
|
||||||
archive=$(get_tmpfile "deb")
|
archive=$(get_tmpfile "deb")
|
||||||
download "${archive}" "${DEB_URL}"
|
download "${archive}" "${DEB_URL}"
|
||||||
|
|||||||
Reference in New Issue
Block a user