aboutsummaryrefslogtreecommitdiff
path: root/share/trashman/brave-browser/unix/linux/debian/install
blob: 02ffbdea84bece9c4259b9f8a4b709176db7592b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/bash
#
# Trashman installer for debian systems.
#

# Parameters
SHARE="$1"
LIB="$2"
REQUIREMENTS="curl apt-transport-https"

# Include basic functions
. $LIB/trashman/functions || exit 1
. $LIB/trashman/debian    || exit 1

DISTRO="`trashman_distro`"
APP="brave-browser"

# Requirements
trashman_apt_install $REQUIREMENTS

# Install pubkey
#curl -fsSLo /usr/share/keyrings/$APP-archive-keyring.gpg https://$APP-apt-release.s3.brave.com/$APP-archive-keyring.gpg
trashman_install_apt_key $SHARE/$APP/unix/linux/$DISTRO/pubkey.gpg \
  $APP-archive-keyring.gpg \
  /usr/share/keyrings/$APP-archive-keyring.gpg

# Create sources.list entry
echo "deb [signed-by=/usr/share/keyrings/$APP-archive-keyring.gpg] https://$APP-apt-release.s3.brave.com/ stable main" | \
  tee /etc/apt/sources.list.d/$APP-release.list

# Update and install
trashman_apt_install $APP || exit 1

# Done
trashman_run_with $APP