Comment

Comment by bluebarbet

Profiles are great. I've used them for years. Much better than containers, which separate your data sort-of-but-not-quite. A profile folder has everything. You can copy it, back it up, plug it into a completely new Firefox installation later.

That portability is a killer feature, but scriptability needs to be improved. The manual says you can do:

>`firefox --profile <path> Start with profile at <path>`

But that will not work as expected if you have more than one profile (which is the whole point). At present the only workable solution is to fiddle with a GUI thru `about:profiles` (or `firefox --ProfileManager`) in order to create the profiles and give them all-important UIDs. And then do:

>`firefox -P <UID>`

It may seem small, but I've found that this is a serious roadblock. I wish it could be fixed so as to make profiles entirely scriptable.

PS: to be clear, after the futzing with the GUI to create the profiles, my script works (well!) at opening windows in the right profile, this way: (1) Check if the given profile is already launched: `ps -eo args | grep -E ".(firefox).(-P $UID)" | grep -v grep > /dev/null` (2) Do `firefox -P $UID --new-instance $url` if it isn't, and `--new-tab` if it is. Inelegant, but very reliable.

parent bluebarbet 1 year ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton