Before starting the Firefox extension development, its a good practice to create a separate Firefox profile, specially for your development. This ensures that your default FF profile is intact and you can switch it back at any point of time. Also note that, creating a new FF profile is not mandatory, but it is recommended.
Firefox Profile
A Firefox Profile is the file where Firefox stores your personal information such as home page, password, bookmarks etc. When ever you modify these information, the changes are stored into your profile.
Usually the profile files are stored in a different location, other than Firefox’s location, in order to prevent the profiles from getting deleted when you uninstall Firefox. This way, you can restore your information, using profiles, when you reinstall Firefox again.
Enough of the profile-lecture. Now, straight to the Tips & Tricks on Using Firefox Profiles.
Starting Profile Manager:
Profile Manager is the one that manages Firefox’s profiles (duh!). To open Firefox profile manager, you need to pass the command line argument –profilemanager when starting the Firefox. See below for the example.
- In Windows, Select START -> Run.
- Enter firefox.exe -ProfileManager.
- Hit OK and the profile manager will open.
From the opened profile manager, you can create a new profile, rename an existing profile or delete an unwanted profile. The window also has a checkbox Don’t ask at Startup. If unchecked, when ever you open Firefox, the profile manager will be opened first allowing you to choose a firefox profile.
Starting the Firefox always with your custom profile:
If you have created a new profile and wants to open the Firefox always with this profile, then do the below:
- In Windows, create a new shortcut for your Firefox application in somewhere (desktop!?).
- Now right click on the shortcut and select properties menu.
- In Shortcut tab -> Target field, append -P yourprofilename to existing target and save.
To check which Firefox profile you are using:
From Firefox, it is possible to check which profile you are currently using. To do that:
- Go to Tools -> Error Console.
- Type the below script in the code text box and then click Evaluate.
alert(Components.classes["@mozilla.org/file/directory_service;1"]. getService(Components.interfaces.nsIProperties). get("ProfD",Components.interfaces.nsIFile).path); - A message box will be displayed with the path of your current profile.
In the forthcoming posts, I’ll explain more on the Firefox extension development.
{ 1 comment }
Thx for this article, now I can start to create my first Firefox extension …
useless.
Comments on this entry are closed.