PortableApps.com Installer Configuration in AppInfo.ini (2008-05-01)

John T. Haller's picture
Submitted by John T. Haller on May 1, 2008 - 7:20pm

I wanted to get some opinions on including the instructions for the PortableApps.com Installer within the appinfo.ini files directly, which should eliminate the need for coding installers for most developers. It'll still be using the PortableApps.com Installer as it is now and it will still be GPLed with exceptions (and more exceptions with 1.0), but the code will be autogenerated. I'm thinking the following section at the bottom of AppInfo.ini:

[Installation]
DeleteAppDirectory=true
DeleteDataDirectory=false
DeleteOtherDirectory=true
DeleteRootDirectoryFiles=false
KeepDirectoryCount=2
KeepDirectory1=App\firefox\plugins
KeepDirectory2=App\firefox\searchplugins
CheckRunningCount=2
CheckRunning1=FirefoxPortable.exe
CheckRunningName1=Mozilla Firefox, Portable Edition
CheckRunning2=Firefox.exe
CheckRunningName2=Mozilla Firefox
InstallerComments=For additional details, visit PortableApps.com.
InstallerFileName=Firefox_Portable_2.0.0.14_en-us
InstallerLicenseAgreement=eula.rtf

In addition, the Details section will be expanded with ShortName and Trademarks:

[Details]
Name=Mozilla Firefox, Portable Edition
ShortName=FirefoxPortable
Publisher=Mozilla & PortableApps.com
Homepage=PortableApps.com/FirefoxPortable
Category=Internet
Description=Mozilla Firefox, Portable Edition is the popular Mozilla Firefox web browser packaged with a PortableApps.com Launcher as a portable app, so you can take your bookmarks, extensions and saved passwords with you.
Trademarks=Firefox is a Trademark of The Mozilla Foundation.

The above will then be used within the installer itself to fully build the installer. For most apps, deleting the App/Other directories will be sufficient to be able to avoid having to do a WinMerge comparison on old/new releases and manually deleting files.

The KeepDirectory entries serve two purposes. First, they let the installer preserve directories used for user plugins, additional fonts, etc without the developer having to keep track of all files. Second, they let the installer more accurately calculate the space taken up by apps for upgrades.

Let's open up the floor...


( categories: )

Version?

Curious... why no version in the details section?

It's kinda sad when my desktop is messier than my room.

Version section

It goes in the version section, as it does now. For the above snippets, it'd be:

[Version]
PackageVersion=2.0.0.140
DisplayVersion=2.0.0.14

Live with purpose.

Oh

Okay, sorry, I just saw there was some more lines, and was thinking maybe you merged everything. Thanks.

It's kinda sad when my desktop is messier than my room.

Why would this have any

Why would this have any advantage over having an installer.ini in the Other directory?

aka MISIIM
What is worship without hard rock!

Simplification

It simplifies things a lot. Since all apps will be using the installer, it's essentially part of the format. And there's overlap with the two. So, why not combine them into one thing. That way, when you're updating an app, the only place you need to update a version number, etc is in one file.

Live with purpose.

Good for smaller apps..

I think this would work well for smaller apps, however with larger apps like GnuCash or OO.org the installation time would increase by quite a bit if the entire app directory was deleted with each release install.

Also I assume there would be more entries to handle the multi installer and perhaps updaters? I would think you would need at least an InstallerType (standard, multi...).

formerly rayven01

Yeah

I'm not so sure I like the idea of deleting those folders.

It's kinda sad when my desktop is messier than my room.

That or Code Required

It's either that or coding is required.... or really complicated INIs. Most apps are essentially cases of ditching all of App on each upgrade anyway with small exceptions (like plugins in Firefox).

Live with purpose.

Suggestion

How about adding the opposite of the "KeepDirectory" structure for deletion:

DeleteDirectoryCount=2
DeleteDirectory1=App\firefox\plugins
DeleteDirectory2=App\firefox\searchplugins

And also for individual files:

DeleteFileCount=1
DeleteFile1=App\firefox\firefox.exe

formerly rayven01

Nope

It'll make it more complicated to calculate install size. And, generally, most apps are ditch all of app types with small exceptions for keeping individual directories (like plugins, searchplugins, etc).

Live with purpose.

Not Too Bad / How bout...

It isn't too bad in terms of time increase. I used OO Portable as an extreme test (since it's our biggest app)... and on a drive where OOP takes about 14 minutes to install it only added about a minute to the install time. And the updater shows the files being deleted... so it doesn't just sit there doing nothing.

MultiInstallers we should probably add now... perhaps the following at the end:

MultipleInstallerOptions=true
MultiInstallerTitleMain=GIMP Portable (English) [Required]
MultiInstallerDescriptionMain=GIMP Portable's program files and English translation
MultiInstallerTitleOptional1=Additional Languages
MultiInstallerDescriptionOptional1=Additional Languages

Cleanup bits could be handled manually as they are now. The installer will already have a PortableApps.comInstallerPreInstall.nsh and PortableApps.comInstallerPostInstall.nsh in Other\Source for apps needing extra custom stuff... we could do the same as a PortableApps.comInstallerMultiCleanup.nsh.

As for updaters, we can just use the standard installer with App, etc set not to delete. Updaters should only be used exceedingly rarely and only for minor errors like an incorrect file being included.

Live with purpose.

Yeah.

This gives me ideas:

  • We can then do a reinstall without the installer if we make a reinstaller, useful for test apps.
  • I also think there should be a package of Dev utils, including an installer auto-compiler, NSIS Portable, Regshot, etc.
  • What kind of other exceptions???
  • What about Pre-Install and Post-Install code? I suppose you could do something like DeleteFiles= and have them separate the folders and the files with a ||
  • I hope the new specs will be able to be transformed from the old specs with minimal actions

I'm bored.

Somebody give me a portable video editor... Please!
If ya wanna see my email, go to digitxpsemail.tk (at least for now!)
My dad saved over $850 a month, by switching to Geico! :P

Good idea

I like it if things get simplified :)
And I wondered how long it would be doable to have the installers in their current form as it gets increasingly complicated to include all the files that have to be deleted while updating from different versions.
So if an App doesn't store any additional personal settings (like dictionaries or plugins) in the App folder that cant get moved, I think deleting the whole App folder is a good idea to ensure that the most recent files are there. And for those Apps who do have plugins, the KeepDirectory entry is the way to go.

And its definitively better&easier to have only one ini to update.

EDIT

Whats the benefit of having the ability to delete the /Data folder?

"What about Love?" - "Overrated. Biochemically no different than eating large quantities of chocolate." - Al Pacino in The Devils Advocate

Deleting the Data folder

Deleting the Data folder could be useful if the base app moved to a new standard for saving it's settings. Of course we would have to include a message informing the user that their data would be lost.

The developer formerly known as ZGitRDun8705