2024-09-30 21:52:15 +01:00
|
|
|
#!/bin/sh -e
|
|
|
|
|
2024-10-31 19:07:20 +00:00
|
|
|
. ../../common-script.sh
|
2024-09-30 21:52:15 +01:00
|
|
|
|
|
|
|
installOnlyOffice() {
|
|
|
|
if ! command_exists onlyoffice-desktopeditors; then
|
|
|
|
printf "%b\n" "${YELLOW}Installing Only Office..${RC}."
|
|
|
|
case "$PACKAGER" in
|
|
|
|
apt-get|nala)
|
|
|
|
curl -O https://download.onlyoffice.com/install/desktop/editors/linux/onlyoffice-desktopeditors_amd64.deb
|
|
|
|
"$ESCALATION_TOOL" "$PACKAGER" install -y ./onlyoffice-desktopeditors_amd64.deb
|
|
|
|
;;
|
|
|
|
zypper|dnf)
|
|
|
|
. ./setup-flatpak.sh
|
|
|
|
flatpak install -y flathub org.onlyoffice.desktopeditors
|
|
|
|
;;
|
|
|
|
pacman)
|
|
|
|
"$AUR_HELPER" -S --needed --noconfirm onlyoffice
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
printf "%b\n" "${RED}Unsupported package manager: ""$PACKAGER""${RC}"
|
|
|
|
exit 1
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
else
|
|
|
|
printf "%b\n" "${GREEN}Only Office is already installed.${RC}"
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
checkEnv
|
|
|
|
checkEscalationTool
|
|
|
|
checkAurHelper
|
|
|
|
installOnlyOffice
|