Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
69 changes: 69 additions & 0 deletions core/tabs/applications-setup/browsers/helium-browser.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
#!/bin/sh -e

. ../../common-script.sh

installHeliumBrowser() {
if ! command_exists Helium && ! command_exists helium; then
printf "%b\n" "${YELLOW}Installing Helium Browser...${RC}"
case "$PACKAGER" in
pacman)
"$AUR_HELPER" -S --needed --noconfirm helium-browser-bin
;;
dnf)
"$ESCALATION_TOOL" "$PACKAGER" copr enable imput/helium
"$ESCALATION_TOOL" "$PACKAGER" install -y helium-bin
;;
nala | apt-get)
"$ESCALATION_TOOL" "$PACKAGER" install -y curl
curl -fsSL https://raw.githubusercontent.com/imputnet/helium-linux/main/pubkey.asc | "$ESCALATION_TOOL" gpg --dearmor -o /usr/share/keyrings/helium.gpg
echo "deb [signed-by=/usr/share/keyrings/helium.gpg] https://pkg.helium.computer/deb stable main" | "$ESCALATION_TOOL" tee /etc/apt/sources.list.d/helium.list
"$ESCALATION_TOOL" "$PACKAGER" update
"$ESCALATION_TOOL" "$PACKAGER" install -y helium-bin
;;
*)
printf "%b\n" "${RED}Helium doesn't support ${PACKAGER}${RC}"
;;
esac
else
printf "%b\n" "${GREEN}Helium Browser is already installed.${RC}"
fi
}

uninstallHeliumBrowser() {
if command_exists Helium || command_exists helium; then
printf "%b\n" "${YELLOW}Removing Helium Browser...${RC}"
case "$PACKAGER" in
pacman)
"$ESCALATION_TOOL" "$PACKAGER" -R --noconfirm helium-browser-bin
;;
dnf)
"$ESCALATION_TOOL" "$PACKAGER" remove -y helium-bin
"$ESCALATION_TOOL" "$PACKAGER" copr disable imput/helium
;;
nala | apt-get)
[ -f "/usr/share/keyrings/helium.gpg" ] && "$ESCALATION_TOOL" rm "/usr/share/keyrings/helium.gpg"
[ -f "/etc/apt/sources.list.d/helium.list" ] && "$ESCALATION_TOOL" rm "/etc/apt/sources.list.d/helium.list"
"$ESCALATION_TOOL" "$PACKAGER" update
"$ESCALATION_TOOL" "$PACKAGER" purge -y helium-bin
;;
esac
else
printf "%b\n" "${GREEN}Helium Browser is not installed.${RC}"
fi
}

main() {
printf "%b\n" "${YELLOW}Do you want to Install or Uninstall Helium Browser?${RC}"
printf "%b\n" "1. ${YELLOW}Install Helium Browser${RC}"
printf "%b\n" "2. ${YELLOW}Uninstall Helium Browser${RC}"
printf "%b" "Enter your choice [1-2]: "
read -r CHOICE
case "$CHOICE" in
1) installHeliumBrowser ;;
2) uninstallHeliumBrowser ;;
*) printf "%b\n" "${RED}Invalid choice.${RC}" && exit 1 ;;
esac
}

checkEnv
main
6 changes: 6 additions & 0 deletions core/tabs/applications-setup/tab_data.toml
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,12 @@ description = "Zen Browser is a privacy-focused web browser designed for enhance
script = "browsers/zen-browser.sh"
task_list = "I"

[[data.entries]]
name = "Helium Browser"
description = "Helium Browser is a free, privacy-focused and open-source chromium-based browser designed for enhanced security and a seamless browsing experience."
script = "browsers/helium-browser.sh"
task_list = "I"

[[data]]
name = "Alacritty"
description = "Alacritty is a modern terminal emulator that comes with sensible defaults, but allows for extensive configuration. By integrating with other applications, rather than reimplementing their functionality, it manages to provide a flexible set of features with high performance. The supported platforms currently consist of BSD, Linux, macOS and Windows. This command installs and configures alacritty terminal emulator."
Expand Down
Loading