aboutsummaryrefslogtreecommitdiff
path: root/chromium-profile
blob: 07c7428fdc6da24fe2a36ae8f0aa524264b713d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#
# Wrapper around chromium to enable extensions
# See https://wiki.debian.org/Chromium#Extensions
#     https://www.chromium.org/developers/creating-and-using-profiles
#     https://www.chromium.org/Home/chromium-security/site-isolation

# Check
if [ -z "$1" ]; then
  cat $0
  exit 1
fi

if which chromium 2> /dev/null; then
  BASE="$HOME/.config/chromium-profiles"
  PROFILE="$BASE/$1"
  mkdir -p "$PROFILE"
  shift

  CHROMIUM_FLAGS="$CHROMIUM_FLAGS --site-per-process --enable-remote-extensions" chromium --user-data-dir="$PROFILE" $*
fi