-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathff
More file actions
executable file
·28 lines (22 loc) · 699 Bytes
/
ff
File metadata and controls
executable file
·28 lines (22 loc) · 699 Bytes
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
#!/bin/bash
# Firefox magic!
set -euo pipefail
# set -x
POLICIES="/Applications/Firefox.app/Contents/Resources/distribution/policies.json"
FF_PROFILE="CruX"
if [[ -f "${POLICIES}" ]]; then
echo "ERROR! Policies file exists and shouldn't!"
echo "${POLICIES}"
exit 1
fi
if [[ ! -d "/Applications/Firefox.app/Contents/Resources/distribution/" ]]; then
policies_dir=$(dirname ${POLICIES})
echo "WARNING! Policies dir didn't exist and should!"
mkdir -p "${policies_dir}"
echo "Created ${policies_dir}"
fi
echo "MAGIC!"
echo "{}" > "${POLICIES}"
/Applications/Firefox.app/Contents/MacOS/firefox -P "${FF_PROFILE}" -new-instance >/dev/null 2>&1 &
sleep 5
rm "${POLICIES}"