You are here

PortableApps.com Application Template 3.5.1 (with default launcher included)

13 posts / 0 new
Last post
John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 41 sec ago
AdminDeveloperModerator
Joined: 2005-11-28 22:21
PortableApps.com Application Template 3.5.1 (with default launcher included)

I'm testing a new style of PortableApps.com Application Template for use with the PortableApps.com Launcher and Installer. The old 2.4 release was just the barebones file structure but includes no example config files. This is of a complete template with config files and a default launcher along with a stub EXE so you can be sure it works by default.

The configuration is setup with an AppID of AppNamePortable, so it uses AppNamePortable.exe as the default launcher and AppNamePortable.ini as its configuration file. There are default settings in the INIs for handling config files that exist locally, config directories that exist locally, config files that move between Data and App, config directories that move between Data and App, and registry key config settings. The necessary lines to handling the moving and backup/restore of local settings as well as portablization of both a standard config file and a .reg file are all included and working for an example app of AppName and ExamplePublisher. The files are all fully commented and a how to txt file is included in the base directory. You can start up just by loading an app without even needing to recompile AppNamePortable.exe. When you're ready to release, instructions for that are included as well.

Download PortableApps.com Application Template 3.5.1

Note that I'm still debating splitting this full version out and doing it along with lighter versions based on just registry and one of just files.

Please test this out, look for any errors, and provide feedback. Suggestions for this particular format are appreciated as well. If we do an automated builder based on interactive Q&A, that will be a separate process from this one (and much more complicated), so please no suggestions along those lines for right now.

Thanks!

Release History
3.5.1 (2018-10-12): Added WorkingDirectory, BaseAppID, and app icon to help.html
3.5.0 (2018-05-21): Updated links to https, improved App directory readme, updated versioning
3.4.1 (2016-11-18): Fixed single word referring to config file instead of registry
3.4 (2016-11-18): Released and announced as official
3.4 Dev Test 2 (2016-11-14): Fixes recommended in Gord's first comment plus default installer.ini
3.4 Dev Test 1 (2016-11-13): Initial release

Gord Caswell
Gord Caswell's picture
Offline
Last seen: 9 hours 16 min ago
DeveloperModerator
Joined: 2008-07-24 18:46
first look

First off, great job!!

Thanks for putting the time into this, it will be certainly be useful for newer developers. Personally, I'll probably stick with the 2.4 updated build at the moment, but that's just me.

Now, some errors & comments:

  • appinfo.ini:

    • Line 3 - "coding" is misspelt
    • The category comment misspells the word "category"
    • EULAVersion: perhaps we should mention that users do not need to agree to GPL or most other OSI licenses prior to running?
    • The DisplayVersion 1.2 DT 1 comment includes a version of 1.99.0.1 - this should be 1.1.99.1 or 1.0.99.1 as 99 > 2, when 1.2.0.0 was released, the platform wouldn't prompt for release. I would also suggest expanding this line to speak to 3- or 4- numbered versions: ie. 4.5.1 DT 1 would be 4.4.1.991, 4.5.1.1 DT 1 would be 4.4.11.991, etc.
  • installer.ini:
    • This is a duplicate of appinfo.ini. not a default installer.ini
  • launcher.ini - or rather, App\Appinfo\Launcher\AppNamePortable.ini:
    • Line 3: coding is misspelt
    • Activate - comment line 1 - "now" should be "know"
    • ENVIRONMENT VARIABLES FOR USE...: "apple" should be "apply"
  • DefaultData whatgoeshere.txt:
    • Based on a recent dev test, and the misunderstanding of a dev regarding the use of DefaultData, this file should likely include mention that DefaultData files should never be modified during normal use of the application

That's it for now, hope it helps!

John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 41 sec ago
AdminDeveloperModerator
Joined: 2005-11-28 22:21
Added in Dev Test 2

I've added all this in with Dev Test 2

Sometimes, the impossible can become possible, if you're awesome!

Gord Caswell
Gord Caswell's picture
Offline
Last seen: 9 hours 16 min ago
DeveloperModerator
Joined: 2008-07-24 18:46
Sorry for missing this

Sorry for missing this earlier, but I just noticed today while prepping a new app.

In Launcher\AppNamePortable.ini, File Write 4-6 are for writing to a .reg file, but refer to writing to a config file.

I wouldn't make a rev 2 just for this, but we can leave it on the list for the next one.

John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 41 sec ago
AdminDeveloperModerator
Joined: 2005-11-28 22:21
Fixed in 3.4.1

I fixed it in 3.4.1 so new folks aren't confused. It doesn't need a news story and isn't pushed via the updater, so we can make minor fixes to this more easily than to apps.

Sometimes, the impossible can become possible, if you're awesome!

rdd
rdd's picture
Offline
Last seen: 1 day 19 hours ago
Translator
Joined: 2013-03-22 06:59
help.html

In help.html the word portablizes must be portabilizes - missing 'i'

Gord Caswell
Gord Caswell's picture
Offline
Last seen: 9 hours 16 min ago
DeveloperModerator
Joined: 2008-07-24 18:46
Not required, means same thing

Both portablize and portabilize are used to mean the same thing: making an application portable.
Around here, the one in common use is portablize, coming from the root portable - dropping the e and adding ize.
Portabilize, on the other hand, comes from the root portability - dropping the ty and adding ze.

JarlPenguin
JarlPenguin's picture
Offline
Last seen: 3 days 17 hours ago
Joined: 2018-04-30 09:17
_how_to.txt versioning

In the _how_to.txt file, the version is still listed as 3.4, not 3.5

Best Regards,
JarlPenguin

Derpish
Offline
Last seen: 1 month 3 weeks ago
Joined: 2018-08-22 15:16
Weird behaviour when packing a Template 3.5 App

Hello,

I'm trying to make a portable version of Signal Desktop, I've been able to make the launcher using PAL, but when I want to make the installer I get a weird error like this:

Processing script file: "LONG_PATH\SignalPortable\Other\Source\PortableApps.comInstaller.nsi" (UTF8)
File: failed opening file "..\..\App\Signal\resources\app.asar.unpacked\node_modules\@journeyapps\sqlcipher\build\Release\obj\global_intermediate\sqlcipher-amalgamation-3020001\openssl-include\openssl\applink.c"
Error in script "LONG_PATH\SignalPortable\Other\Source\PortableApps.comInstaller.nsi" on line 1550 -- aborting creation process

It seems like PAI is treating "applink.c" as a special script and is not just packing it like the other files. First I deleted the "openssl" folder then tried to compile, it compiled without errors.
I also found out that PAI had no problem making the installer in a shorter path like "C:\SignalPortable" without deleting the "openssl" folder.

John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 41 sec ago
AdminDeveloperModerator
Joined: 2005-11-28 22:21
Path is too long

The path is too long for NSIS to handle. LONG_PATH should *not* be a long path if the app itself has immense paths inside. (yes, "resources\app.asar.unpacked\node_modules\@journeyapps\sqlcipher\build\Release\obj\global_intermediate\sqlcipher-amalgamation-3020001\openssl-include\openssl\applink.c" is an immense path)

Sometimes, the impossible can become possible, if you're awesome!

Derpish
Offline
Last seen: 1 month 3 weeks ago
Joined: 2018-08-22 15:16
Thanks for the explanation.

Thanks for the explanation.
What is the NSIS limit and is there a way to fix this ?

John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 41 sec ago
AdminDeveloperModerator
Joined: 2005-11-28 22:21
Move To A Shorter Path

To compile your specific app you mentioned above, you can move it to a shorter path to create the installer. Move it to C:\PortableApps\SignalPortable and compile the installer there and it should work without issue. NSIS has a maximum string length of 1024 characters. It uses that string for the full path to its compiler plus the full path of the thing you're compiling plus the full path to where the installer will be created plus command line switches. Without the LONG_PATH you mention above, you're already at 192 characters just for the path length from SignalPortable to applink.c. Add in triple the LONG_PATH since it appears in LONG_PATH\PortableApps.comInstaller and LONG_PATH\SignalPortable and LONG_PATH\SignalPortable_1.2.3.paf.exe which are passed in the command line and you can see why it gets way too long.

Sometimes, the impossible can become possible, if you're awesome!

John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 41 sec ago
AdminDeveloperModerator
Joined: 2005-11-28 22:21
3.5.1 Release

For today's release, I added in a WorkingDirectory example since it hadn't yet been included, added an example for BaseAppID for the platform 16.x taskbar pinning feature, and added an app icon to the default help.html file that automatically points to the appicon_128.png.

Sometimes, the impossible can become possible, if you're awesome!

Log in or register to post comments