3 # create a disposable firefox session
5 # Remark: this script expects the firefox sessions
6 # to be stored in ~/.mozilla/firefox
9 # pick the next profile number
10 PROFILE_NUMBER=$(new_firefox_profile_id.py)
11 PROFILE_PATH=$(basename $(mktemp -d ~/.mozilla/firefox/XXXXXXXX.os_user_${PROFILE_NUMBER}))
12 PROFILE_TIMESTAMP="$(date +%s)000"
13 PROFILE_NAME=$(echo ${PROFILE_PATH} | awk -F '.' '{ print $NF; }')
15 # create a fake times.json
16 cat > ~/.mozilla/firefox/${PROFILE_PATH}/times.json << __EO_TIMES_JSON__
18 "created": ${PROFILE_TIMESTAMP}
22 # add our new "profile" to firefox
23 cat >> ~/.mozilla/firefox/profiles.ini << __EO_PROFILES_INI__
24 [Profile${PROFILE_NUMBER}]
33 firefox -P ${PROFILE_NAME} -no-remote $@