Sometimes, you need a fresh Firefox. One that is exactly as if you had just installed it. Nothing cached, no cookies, clean. Or perhaps you use different Firefox profiles, for different purposes, and don’t want to have to install all your favourite extensions and configuration changes every time you create a new profile. This post describes one way to achieve both those things. While this post tells how to do it in Linux, you could certainly adapt the methods for Windows or whatever. All you need is Firefox, a way to start it, and a scripting language.
As described in another post, I use Firefox profiles to keep various activities separate – different banks, different AWS accounts and so on. It’s easy enough to use them from the command line, but it is much nicer to just click on an icon and have the right profile start up. Here is how to do that for one window manager, Ubuntu’s Unity.
Out of the box, all your Firefox windows share resources between them. Even with so-called “private browsing” enabled, a lot of what you do is shared between your Firefox tabs and windows. I often want to be logged into Amazon AWS in several different accounts at once, but even if I do that in different tabs or even in different windows of the same browser profile, I can only use one account at a time. All the windows and tabs magically track the most recent login. The answer is to use more than one profile.