Page 1 of 1

Does a Sparkle-like library exist for LiveCode?

Posted: Sat Dec 25, 2010 6:09 am
by garynunes
In the Cocoa universe there exists a framework called Sparkle. It allows the embedding of a self-updating capability within an application. If you've used many applications you've seen it in action (even if you don't realize it).

It's a great framework for Cocoa. It's free and worthy of support (I'm not associated with it, just a fan).

Is there anything like that for the LiveCode universe (if you're still not sure what I'm talking about see (http://sparkle.andymatuschak.org/)?

Regards,
Gary Nunes

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Sun Dec 26, 2010 2:49 pm
by Janschenkel
You may be interested in the GLX Application framework as it sports such an auto-update mechanism.

Jan Schenkel.

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Sun Dec 26, 2010 5:24 pm
by FourthWorld
If you plan on submitting to Apple's app store you may want to skip this: their guidelines prohibit apps that download code, so any app that keeps itself up to date for the user would seem likely to be rejected.

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Mon Dec 27, 2010 4:31 am
by garynunes
Jan,
Thanks for the response. I will look into GLX.

Richard (FourthWorld),
Thanks Richard, I did realize that but I like the idea of Sparkle more than the idea of the MacApp store <g> ... or, slightly more seriously, the Sparkle updating experience is superior to the iPhone/iPad app store updating experience ... and, I'll bet, to the soon to be MacApp store updating experience. At least one developer I know of (for Cocoa, not LiveCode) is maintaining two code bases, MacApp store and non-MacApp store, so that he doesn't have to "dumb down" his application for his existing users. I hope others will be as thoughtful to their customers.

Regards,
Gary Nunes

P.S.
guidelines, Wikipedia definition:
A guideline is any document that aims to streamline particular processes according to a set routine. By definition, following a guideline is never mandatory (protocol would be a better term for a mandatory procedure). Guidelines are an essential part of the larger process of governance.

Apple can call them guidelines if they want to (apparently they can do anything ... look at the history of iOS development in general and LiveCode's iOS component in particular) but, since I can't ignore them and be in the app stores, they aren't guides, they're regulations.

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Mon Dec 27, 2010 6:00 am
by FourthWorld
garynunes wrote:Thanks Richard, I did realize that but I like the idea of Sparkle more than the idea of the MacApp store <g>
Quite a lot of us value delivering convenience to our users over complying with arbitrary limitations. ;)
At least one developer I know of (for Cocoa, not LiveCode) is maintaining two code bases, MacApp store and non-MacApp store, so that he doesn't have to "dumb down" his application for his existing users. I hope others will be as thoughtful to their customers.
I like it. May do the same. More than a few of my clients are considering split pricing, raising their Mac prices to better reflect the higher cost of developing for that platform. A brave new world we're entering....

GLX can be useful. If you find it a bit unwieldy for the relatively small bit you need please let us know and we'll help you craft a solution. One great thing about LiveCode is that it's pretty simply to factor out an app into various stack files, and updating those stack files using the built-in "get url" command is a snap.

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Fri Jan 14, 2011 2:02 pm
by trevordevore
LiveCode is that it's pretty simply to factor out an app into various stack files, and updating those stack files using the built-in "get url" command is a snap.
While the basic operation of replacing a stack file using get url is simple enough, does it work in environments where the application isn't running with Admin privileges? It seems like it would fail if the running application didn't have elevated privileges.

--
Trevor DeVore
Blue Mango Learning Systems
ScreenSteps: http://www.screensteps.com
LiveCode Resources for Developers: http://livecode.bluemangolearning.com

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Sat Jan 15, 2011 10:27 pm
by AndyP
As long as the stacks to be updated are placed in the users app directory and not the programs directory there should be no problem.

Most of my progs consist of an exe launcher in the program folder which launches the stacks in the users app directory. This arragement allows all of the stacks to be updated and even the updater stack as this is also in this directory.

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Sat Jan 15, 2011 10:33 pm
by trevordevore
True Andy. What do you do about scenarios where there are other users on the system? Do you make each person update the application separately? Also, how does the uninstall process work in the multi-user setup?

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Sat Jan 15, 2011 10:39 pm
by FourthWorld
Trevor, how does the GLX framework handle that?

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Sat Jan 15, 2011 10:50 pm
by trevordevore
The framework downloads an update package (this is auto generated by a packaging application) to a directory and unpacks it. Once all of the files are ready to copy over an elevated process is launched and the main application quits. The elevated process copies the files into the application directory and then relaunches the application. The application cleans up after itself on relaunch.

Right now the elevated process is a VBScript though I'm looking at moving over to an executable at some point.

Re: Does a Sparkle-like library exist for LiveCode?

Posted: Sun Jan 16, 2011 11:15 am
by AndyP
Hi Trevor,
I've only built per user apps so it hasn't been a problem I've had to deal with yet.

Some installers elevate user rights during the install but this generally has to be Admin approved.
It' a problem and there is lots of traffic in developer forums and the solution?.. well their dosn't seem to be one!

It looks like a lot of People are resorting to using the pubic documents folder, not ideal.
The common app folder is the obvious choice one would think, however a user trying to mod this who was not the owner when the app was installed may not have the rights to write to this folder...aghhh

It used to be so easy with XP. :?