blob: a5dc54531b66d2cf210b912f31ddee10b8ea5fb0 (
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
|
#!/bin/bash
#
# Wrapper around firefox
#
# Parameters
BASE="$HOME/.mozilla/firefox"
PROFILES="$BASE/profiles"
# Check
if ! which firefox &> /dev/null; then
echo "Please install firefox"
exit 1
fi
# Dispatch
#if [ ! -z "$1" ] && [ "$1" == "private" ]; then
# firefox -private
if [ ! -z "$1" ]; then
if [ ! -d "$PROFILES/$1" ]; then
firefox -CreateProfile "$1 $PROFILES/$1"
if [ -d "$PROFILES/template" ] && [ "$1" != "template" ]; then
rm -rf $PROFILES/$1 && cp -a $PROFILES/template $PROFILES/$1
fi
fi
firefox -p $1 -new-instance &
else
firefox --profilemanager -new-instance &
fi
|