Jump to content

Thunderbird 2.0.0.19 AdvancedINF Install


Acheron

Recommended Posts

I posted previously the scripts I use to install Firefox unattended. Making Thunderbird 2.0.0.x unattended is not very different. My script also sets Thunderbird as the default email and news client

install.inf

[Version]
Signature="$Windows NT$"

[DefaultInstall]
AddReg = Thunderbird.AddReg
CopyFiles = Thunderbird.CopyFiles,GrePrefs.CopyFiles
RunPostSetupCommands = Thunderbird.Install:1
UpdateInis = override.ini

[DestinationDirs]
;Thunderbird install dir
Thunderbird.CopyFiles = 16422,"Mozilla Thunderbird"
GrePrefs.CopyFiles = 16422,"Mozilla Thunderbird\greprefs"

[Thunderbird.CopyFiles]
;General config file
"thunderbird.cfg"

[GrePrefs.CopyFiles]
;Enable general config file
"_config.js"

[Thunderbird.Install]
;Mozilla Thunderbird 2.0.0.19
"""%01%\Thunderbird20019%LANG_ID%.exe"" /INI=%16422%\Mozilla Thunderbird\override.ini"
;Create default profile
"""%16422%\Mozilla Thunderbird\Thunderbird.exe"" -CreateProfile default"
;Install addons
"cmd /c for %%e in (""%01%\Addons\*.xpi"") do start ""Installing Thunderbird addons"" /wait ""%%programfiles%%\Mozilla Thunderbird\thunderbird.exe"" -install-global-extension ""%%e"""
;Install themes
"cmd /c for %%e in (""%01%\Themes\*.jar"") do start ""Installing Thunderbird themes"" /wait ""%%programfiles%%\Mozilla Thunderbird\thunderbird.exe"" -install-global-theme ""%%e"""

[Thunderbird.AddReg]
;Set thunderbird as default mail and news handler
HKCR,".eml",,0x0,"ThunderbirdEML"
HKCR,"CLSID\{29F458BE-8866-11D5-A3DD-00B0D0F3BAA7}",,0x0,"Mozilla MAPI"
HKCR,"CLSID\{29F458BE-8866-11D5-A3DD-00B0D0F3BAA7}\LocalServer32",,0x0,"%16422%\Mozilla Thunderbird\thunderbird.exe /MAPIStartUp"
HKCR,"CLSID\{29F458BE-8866-11D5-A3DD-00B0D0F3BAA7}\VersionIndependentProgID",,0x0,"MozillaMapi"
HKCR,"mailto\DefaultIcon",,0x0,"%16422%\Mozilla Thunderbird\thunderbird.exe,0"
HKCR,"mailto\shell\open\command",,0x0,"""%16422%\Mozilla Thunderbird\thunderbird.exe"" -osint -compose ""%%1"""
HKCR,"news\DefaultIcon",,0x0,"%16422%\Mozilla Thunderbird\thunderbird.exe,0"
HKCR,"news\shell\open\command",,0x0,"""%16422%\Mozilla Thunderbird\thunderbird.exe"" -osint -mail ""%%1"""
HKCR,"nntp\DefaultIcon",,0x0,"%16422%\Mozilla Thunderbird\thunderbird.exe,0"
HKCR,"nntp\shell\open\command",,0x0,"""%16422%\Mozilla Thunderbird\thunderbird.exe"" -osint -mail ""%%1"""
HKCR,"snews\DefaultIcon",,0x0,"%16422%\Mozilla Thunderbird\thunderbird.exe,0"
HKCR,"snews\shell\open\command",,0x0,"""%16422%\Mozilla Thunderbird\thunderbird.exe"" -osint -mail ""%%1"""
HKLM,"SOFTWARE\Clients\Mail",,0x0,"Mozilla Thunderbird"
HKLM,"SOFTWARE\Clients\Mail\Mozilla Thunderbird\shell\properties",,0x0,"%TB_OPTIONS%"
HKLM,"SOFTWARE\Clients\News",,0x0,"Mozilla Thunderbird"

[override.ini]
"%16422%\Mozilla Thunderbird\override.ini","Install",,"CloseAppNoPrompt=true"
"%16422%\Mozilla Thunderbird\override.ini","Install",,"DesktopShortcut=false"
"%16422%\Mozilla Thunderbird\override.ini","XRE",,"EnableProfileMigrator=false"

[Strings]
TB_OPTIONS="Thunderbird &Options"

[Strings.0413]
LANG_ID="nl"
TB_OPTIONS="Thunderbird-&opties"

_config.js

pref("general.config.obscure_value", 0);
pref("general.config.filename", "thunderbird.cfg");

thunderbird.cfg

//general settings
defaultPref("extensions.update.notifyUser", false);
defaultPref("font.name.monospace.x-western", "Lucida Console");
defaultPref("font.name.sans-serif.x-western", "Trebuchet MS");
defaultPref("font.name.serif.x-western", "Palatino Linotype");
defaultPref("mail.content_disposition_type", 1);
defaultPref("mail.default_html_action", 2);
defaultPref("mail.forward_message_mode", 2);
defaultPref("mail.html_compose", true);
defaultPref("mail.identity.default.compose_html", true);
defaultPref("mail.identity.default.reply_on_top", 1);
defaultPref("mail.inline_attachments", false);
defaultPref("mail.pop3.deleteFromServerOnMove", true);
defaultPref("mail.phising.detection.enabled", false);
defaultPref("mail.showFolderPaneColumns", true);
defaultPref("mailnews.default_news_sort_order", 2);
defaultPref("mailnews.default_news_sort_type", 22);
defaultPref("mailnews.default_sort_order", 2);
defaultPref("mailnews.default_sort_type", 22);
defaultPref("mail.spam.manualMarkMode", 1);
defaultPref("mail.spam.version", 1);
defaultPref("mailnews.message_display.disable_remote_image", false);
defaultPref("mailnews.ui.junk.firstuse", false);
defaultPref("mailnews.reuse_message_window", false);
defaultPref("mailnews.start_page.enabled", false);
defaultPref("mailnews.thread_pane_column_unthreads", false);
defaultPref("prefs.converted-to-utf8", true);
defaultPref("pref.privacy.disable_button.view_passwords", true);
defaultPref("offline.download.download_messages", 1);
defaultPref("spellchecker.dictionary", "nl");

//Use classic skin
defaultPref("general.skins.selectedSkin", "ThunderBirdDefaultVista");

//Autozip attachments
defaultPref("extensions.AutoZipAttachments.autoZipFileName", "");
defaultPref("extensions.AutoZipAttachments.autoZipStatus", true);
defaultPref("extensions.AutoZipAttachments.confirmAutoZip", true);
defaultPref("extensions.AutoZipAttachments.fileExtensions", "7z zip jar arj rar z gz tgz lha cab");
defaultPref("extensions.AutoZipAttachments.firstrun", true);
defaultPref("extensions.AutoZipAttachments.promptZipFileName", true);
defaultPref("extensions.AutoZipAttachments.zipComment", "");

//Dictionary switcher
defaultPref("extensions.dictionary-switcher.autodetect", true);

//Minimize to tray
defaultPref("extensions.minimizetotray.minimize-on-close", true);
defaultPref("extensions.minimizetotray.two-click-restore", false);
defaultPref("extensions.minimizetotray.with-windows", true);

To install Thunderbird using the AdvancedINF command you simply add the following command to your unattended install script:

"rundll32.exe advpack.dll,LaunchINFSection .\PATH\TO\THUNDERBIRD\install.inf,,1"

Edited by Acheron
Link to comment
Share on other sites


Updated first post. I now have more settings configured, like threaded view, descending sort order etc. Also configured to compose and sent as HTML mail. I just hate Thunderbirds default settings :realmad:

Link to comment
Share on other sites

  • 6 months later...

Hi Acheron,

Although I have been reading it for months, this is my first post on the forum, so bear with me if the following is somewhat of a newbie's question :blushing:.

I have been trying to create a silent install of TB 2.0.0.19 using an .inf file, following your indications here and in your twin Firefox thread, but I guess I must be pretty dumb for it won't install, no matter what I do. I only get the file to create/copy the following files to the expected locations: thunderbird.cfg, override.ini, and _config.js within the "Greprefs" folder; the Registry seems to get updated just fine with the new information. But the actual .exe file simply won't start.

I tried using no /S switch, just in case that was creating the problem, but nothing happened. I then unzipped the file as downloaded from the Mozilla site--which was the one that I had been using so far--and used the setup.exe instead, but that was of no avail either. Since my computer is sometimes peculiar when it comes to paths, I changed the full path for "%01%", which I take to be the folder where the .exe and the .inf file are located (am I correct, incidentally?), but no way.

As for how to run the inf file, I have tried the "mouse right click > Install" option, as well as using these two commands on the console:

[Version]
Signature="$Windows NT$"

[DefaultInstall]
RunPreSetupCommands = Thunderbird.Install:1
RunPostSetupCommands = Thunderbird.Config:1
AddReg = Thunderbird.AddReg
CopyFiles = Thunderbird.CopyFiles,GrePrefs.CopyFiles
UpdateInis = SkipOEMigration

[DestinationDirs]
;Thunderbird install dir
Thunderbird.CopyFiles = 16422,"Internet\Mozilla\Thunderbird"
GrePrefs.CopyFiles = 16422,"Internet\Mozilla\Thunderbird\greprefs"

[Thunderbird.CopyFiles]
;General config file
"thunderbird.cfg"

[GrePrefs.CopyFiles]
;Enable general config file
"_config.js"

[Thunderbird.Install]
;Mozilla Thunderbird 2.0.0.19
"""%01%\Thunderbird20019.exe"" /S"

[Thunderbird.AddReg]
;Set thunderbird as default mail and news handler
HKCR,".eml",,0x0,"ThunderbirdEML"
HKCR,"CLSID\{29F458BE-8866-11D5-A3DD-00B0D0F3BAA7}",,0x0,"Mozilla MAPI"
HKCR,"CLSID\{29F458BE-8866-11D5-A3DD-00B0D0F3BAA7}\LocalServer32",,0x0,"%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe /MAPIStartUp"
HKCR,"CLSID\{29F458BE-8866-11D5-A3DD-00B0D0F3BAA7}\VersionIndependentProgID",,0x0,"MozillaMapi"
HKCR,"mailto\DefaultIcon",,0x0,"%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe,0"
HKCR,"mailto\shell\open\command",,0x0,"""%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe"" -osint -compose ""%%1"""
HKCR,"news\DefaultIcon",,0x0,"%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe,0"
HKCR,"news\shell\open\command",,0x0,"""%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe"" -osint -mail ""%%1"""
HKCR,"nntp\DefaultIcon",,0x0,"%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe,0"
HKCR,"nntp\shell\open\command",,0x0,"""%16422%\Mozilla Thunderbird\thunderbird.exe"" -osint -mail ""%%1"""
HKCR,"snews\DefaultIcon",,0x0,"%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe,0"
HKCR,"snews\shell\open\command",,0x0,"""%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe"" -osint -mail ""%%1"""
HKLM,"SOFTWARE\Clients\Mail",,0x0,"Mozilla Thunderbird"
HKLM,"SOFTWARE\Clients\Mail\Mozilla Thunderbird\shell\properties",,0x0,"Thunderbird-&opties"
HKLM,"SOFTWARE\Clients\News",,0x0,"Mozilla Thunderbird"

[Thunderbird.Config]
;Install addons
"cmd /c for %%%%e in (""%01%\Addons\*.xpi"") do ""%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe"" -install-global-extension ""%%%%e"""
;Install themes
"cmd /c for %%%%e in (""%01%\Themes\*.jar"") do ""%16422%\Internet\Mozilla\Thunderbird\thunderbird.exe"" -install-global-theme ""%%%%e"""

[SkipOEMigration]
"%16422%\Internet\Mozilla\Thunderbird\override.ini","XRE",,"EnableProfileMigrator=false"

BTW: as so many people on the forum, I am completing an unattended installation of WinXP together with an assortment of applications that I normally use (I use WPI through the post-$OEM$ system; I prefer this to integration via srvpack as I can easily select what to install at any time). So far I have run the inf on a virtual machine. Should there be any difference installing this from an .iso file?

Any help is appreciated. Thanks in advance and keep up the good work!

Link to comment
Share on other sites

The default inf install command is different from the one I use, that's why it's called 'Advanced'.

Here's a registry tweak to add the Advanced Inf Install command to the right click menu:

advancedinf.reg

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\inffile\shell\AdvInstall]
@="Install (&AdvancedINF)"

[HKEY_CLASSES_ROOT\inffile\shell\AdvInstall\command]
@="%SystemRoot%\\System32\\rundll32.exe advpack,LaunchINFSection %1"

P.S. When calling the advpack.dll LaunchINFSection dll function don't add quotes around the path. It's an exception to the general rule to add quotes when you have spaces in the path.

I have also updated the opening post for Thunderbird 2.0.0.19. Note I still have to fix the addon install issue (first addon won't get installed).

Edited by Acheron
Link to comment
Share on other sites

Acheron, this is fast service! Thank you so much for the tip; the quotes were the main problem, it seems. I didn't know about it and put it as a matter of course--my mistake, then. Now TB does install silently, but it refuses to do it into the folder assigned via the Install.inf file, and stubbornly goes into "%ProgramFiles%\Mozilla Thunderbird". Any ideas? I had a path mistake on the inf file that I posted earlier, but that was corrected before running the inf and everything pointed to "%ProgramFiles%\Internet\Mozilla\Thunderbird"... or so I thought! :lol:

Incidentally: I added the tweak that you supplied but whenever I use it, a window pops up with the "Access denied" message. Not a big deal really since I will probably install the program via WPI as I said on my other post...

Link to comment
Share on other sites

Hi again,

My idea is to install Thunderbird, along with several other applications, in the post-$OEM$ stage, i.e. just after the desktop is loaded for the first time after a clean XP install; all my attempts with the .inf file so far have yet been done on the VM where I usually do all the dirty work--as so many of us I guess. To be on the safest side and avoid unnecessary hassle, I made a full install of a Spanish WinXP Prox86 SP2 (I mean without "nLite-ing" it other than using the Unattended Setup feature--am I lazy, boy! :lol:) in the virtual machine: no extra Java stuff, no DaemonTool, no CCleaner, no regtweaks, no nothing; just XP Pro as pristine as ever dreamt by the Redmond people... I even kept the bloody Tour! Unfortunately, the problem remained.

I also used the .inf method to install Firefox 3.0.6 to see what happened, only to get the same results. No new path, theme or addons, although the Adobe plugin did make it, tho'. Incidentally, and as reported by some in the appropriate thread, for some reason my XP complained about the "-setDefaultBrowser -silent" switches, even though it did install silently.

I then thought of installing Firefox using your script without any modification (I even changed the name of the original installer to "Firefox306nl" :yes:, and this time it did install all right including the .cfg info (Google as startup page and so forth); still, the icon got into the desktop and the addons did not make it either. Although no expert, I daresay that the problem lies in the different path that I gave in my script, or else it's some weird problem with the locale. I thought that perhaps some mod of my config file was not making XP too happy, but on the other hand both FF and TB resist to install in the correct folders, although they of course run different cfg files! So I'm taking the liberty to PM you my files (TB and FF) so that you can have a deep look at them; I have deleted addons, themes, etc. to make it a tidier little 7z file, but have kept the folder structure just in case it has a bearing on the matter. Thanks in advance for all the trouble, Acheron; I'm depending on you, mate! I only trust that all this is of help to someone other than me in the future...

Edited by Svarabhakti
Link to comment
Share on other sites

Have you tried the /D switch on the commandline? If it doesn't work you might want to check Mozilla's documentation about changing the default install directory. Normally I don't care where software get's installed, as long as it is in the Program Files directory.

Link to comment
Share on other sites

Hi again,

This is just to tell you that the problem was yet another issue with the darn quotes; I guess I have a trauma with them and always use them the wrong way :wacko:. For the information of future users of the inf system, bear in mind that the /D switch will work only if the full path is stated, as per here, with no quotes wrapping the path. So in my case, the appropriate line in Install.inf reads as follows (in a single line):

"""%01%\Thunderbid20019.exe"" /S /D=C:\Archivos de programa\Internet\Mozilla\Thunderbird"

This also works with Firefox, incidentally.

Edited by Svarabhakti
Link to comment
Share on other sites

  • 2 weeks later...
  • 2 months later...

I have been trying to pre-configure Thunderbird with .cfg file, BUT despite using defaultPref users are later unable to change the preferences if they wish.

For example let's imagine a situation when user WANTS to have webpage diplayed on startup - if they enable it from Tools -> Options it gets written into prefs.js, but when TB (2.0.0.21) starts it still has no startup page (and next exit writes that also in prefs.js). Seems to be true for all general options, but not for options that I have set up for specific account.

Any idea?

edit: seems to be known bug, defaultPref has conflict with application defaults https://bugzilla.mozilla.org/show_bug.cgi?id=439695

also - it might be good to mention that the first line of .cfg file is never interpreted, using it for a comment (like here) is good idea. https://bugzilla.mozilla.org/show_bug.cgi?id=308029

Edited by petskratt
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...