Compare commits

...

4 Commits

Author SHA1 Message Date
Angaddeep Singh
111d267f45
Merge 8f92b9c74fc240459b7e49425e1fcb01033c37db into 232b45e6a66753cb9ef8cea6f6ea8dcc045434c1 2025-02-14 10:16:58 +00:00
Chris Titus
232b45e6a6 update version 2025-02-13 15:22:07 -06:00
Angaddeep Singh
8f92b9c74f Update brave.sh 2024-12-11 11:29:20 +05:30
Angaddeep Singh
34d832947d simplifying Brave install 2024-12-11 11:24:35 +05:30
4 changed files with 6 additions and 44 deletions

6
Cargo.lock generated
View File

@ -399,7 +399,7 @@ checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a"
[[package]] [[package]]
name = "linutil_core" name = "linutil_core"
version = "25.1.10" version = "25.2.13"
dependencies = [ dependencies = [
"ego-tree", "ego-tree",
"include_dir", "include_dir",
@ -411,7 +411,7 @@ dependencies = [
[[package]] [[package]]
name = "linutil_tui" name = "linutil_tui"
version = "25.1.10" version = "25.2.13"
dependencies = [ dependencies = [
"clap", "clap",
"linutil_core", "linutil_core",
@ -1299,7 +1299,7 @@ checksum = "d135d17ab770252ad95e9a872d365cf3090e3be864a34ab46f48555993efc904"
[[package]] [[package]]
name = "xtask" name = "xtask"
version = "25.1.10" version = "25.2.13"
dependencies = [ dependencies = [
"linutil_core", "linutil_core",
] ]

View File

@ -1,6 +1,6 @@
[workspace.package] [workspace.package]
license = "MIT" license = "MIT"
version = "25.1.10" version = "25.2.13"
edition = "2021" edition = "2021"
[workspace] [workspace]

View File

@ -5,44 +5,7 @@
installBrave() { installBrave() {
if ! command_exists com.brave.Browser && ! command_exists brave; then if ! command_exists com.brave.Browser && ! command_exists brave; then
printf "%b\n" "${YELLOW}Installing Brave...${RC}" printf "%b\n" "${YELLOW}Installing Brave...${RC}"
case "$PACKAGER" in curl -fsS https://dl.brave.com/install.sh | sh
apt-get|nala)
"$ESCALATION_TOOL" "$PACKAGER" install -y curl
"$ESCALATION_TOOL" curl -fsSLo /usr/share/keyrings/brave-browser-archive-keyring.gpg https://brave-browser-apt-release.s3.brave.com/brave-browser-archive-keyring.gpg
echo "deb [signed-by=/usr/share/keyrings/brave-browser-archive-keyring.gpg] https://brave-browser-apt-release.s3.brave.com/ stable main" | "$ESCALATION_TOOL" tee /etc/apt/sources.list.d/brave-browser-release.list
"$ESCALATION_TOOL" "$PACKAGER" update
"$ESCALATION_TOOL" "$PACKAGER" install -y brave-browser
;;
zypper)
"$ESCALATION_TOOL" "$PACKAGER" install -y curl
"$ESCALATION_TOOL" rpm --import https://brave-browser-rpm-release.s3.brave.com/brave-core.asc
"$ESCALATION_TOOL" "$PACKAGER" addrepo https://brave-browser-rpm-release.s3.brave.com/brave-browser.repo
"$ESCALATION_TOOL" "$PACKAGER" refresh
"$ESCALATION_TOOL" "$PACKAGER" --non-interactive install brave-browser
;;
pacman)
"$AUR_HELPER" -S --needed --noconfirm brave-bin
;;
dnf)
"$ESCALATION_TOOL" "$PACKAGER" install -y dnf-plugins-core
dnf_version=$(dnf --version | head -n 1 | cut -d '.' -f 1)
if [ "$dnf_version" -eq 4 ]; then
"$ESCALATION_TOOL" "$PACKAGER" config-manager --add-repo https://brave-browser-rpm-release.s3.brave.com/brave-browser.repo
else
"$ESCALATION_TOOL" "$PACKAGER" config-manager addrepo --from-repofile=https://brave-browser-rpm-release.s3.brave.com/brave-browser.repo
fi
"$ESCALATION_TOOL" rpm --import https://brave-browser-rpm-release.s3.brave.com/brave-core.asc
"$ESCALATION_TOOL" "$PACKAGER" install -y brave-browser
;;
apk)
checkFlatpak
flatpak install -y flathub com.brave.Browser
;;
*)
printf "%b\n" "${RED}Unsupported package manager: ""$PACKAGER""${RC}"
exit 1
;;
esac
else else
printf "%b\n" "${GREEN}Brave Browser is already installed.${RC}" printf "%b\n" "${GREEN}Brave Browser is already installed.${RC}"
fi fi
@ -50,5 +13,4 @@ installBrave() {
checkEnv checkEnv
checkEscalationTool checkEscalationTool
checkAURHelper
installBrave installBrave

View File

@ -22,7 +22,7 @@ tui-term = { version = "0.2.0", default-features = false }
time = { version = "0.3.36", features = ["formatting", "local-offset", "macros"], default-features = false } time = { version = "0.3.36", features = ["formatting", "local-offset", "macros"], default-features = false }
unicode-width = { version = "0.2.0", default-features = false } unicode-width = { version = "0.2.0", default-features = false }
rand = { version = "0.8.5", optional = true } rand = { version = "0.8.5", optional = true }
linutil_core = { version = "25.1.10", path = "../core" } linutil_core = { version = "25.2.13", path = "../core" }
tree-sitter-highlight = "0.24.4" tree-sitter-highlight = "0.24.4"
tree-sitter-bash = "0.23.3" tree-sitter-bash = "0.23.3"
nix = { version = "0.29.0", features = [ "user" ] } nix = { version = "0.29.0", features = [ "user" ] }