summarylogtreecommitdiffstats
path: root/brave-nightly-bin.sh
blob: 17816b35e05626692dffe8189b5933f81e4dfe34 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/usr/bin/env bash
XDG_CONFIG_HOME="${XDG_CONFIG_HOME:-$HOME/.config}"

# Allow users to override command-line options
USER_FLAGS_FILE="$XDG_CONFIG_HOME/brave-nightly-flags.conf"
if [[ -f $USER_FLAGS_FILE ]]; then
   USER_FLAGS="$(cat $USER_FLAGS_FILE | sed 's/#.*//')"
fi

if [[ -z "${CHROME_USER_DATA_DIR}" ]]; then
    export CHROME_USER_DATA_DIR=~/.config/BraveSoftware/Brave-Browser-Nightly
fi
exec "/opt/brave.com/brave-nightly/brave-browser" "$USER_FLAGS" "$BRAVE_FLAGS" "$FLAG" "$@"