Archive: Program to check for updates via web


I am almost done with a small (under 8kb) utility that checks a special web page for product updates. It downloads a formatted text file from a web site (configurable), like this one:


EDGEUPDATE VERSION TRACKER rev. 2
!latest "Crystal Edit" 100 http://somepage.cjb.net/
!latest "Other Product" 24 http://otherpage.cjb.net/
If it doesn't begin with a !, its a comment.
Blah blah blah.
!latest "Other Product 2" 19 http://thirdpage.cjb.net/


I would upload this .txt file to any web host (lets say http://io.spaceports.net/~edge/database.txt). Now I call EdgeUpdate as follows:

EdgeUpdate http://io.spaceports.net/~edge/database.txt "Crystal Edit" 98

So EdgeUpdate downloads and scans the text file, and sees that the latest version of Crystal Edit is version 100. The command line said that the user's version was only 98, so a dialog box pops up and asks, "There is a new version of Crystal Edit available. Would you like more information?". If the user clicks yes, a new internet window opens to http://somepage.cjb.net/. If the user clicks no, nothing happens.

I am working on adding automatic patch downloading before I release this program.

Note that this program does not pop up a dialer window - if there is no existing internet connection, it returns silently without annoying the user.

Anybody interested? :)

Oh, also noteworthy - there are no runtime dependancies. No DLLs or OCXs to worry about - though it does require Internet Explorer 3 to actually work. If IE is not installed, it just fails quietly (no error box).


use jnetlib
hint: use jnetlib so your program won't depend on IE3.

http://www.nullsoft.com/free/jnetlib/

-christophe


I would, but jnetlib can't automatically read the user's proxy settings or detect whether or not there is an internet connection. It also doesn't support transparent redirection, so you can't use a cjb.net url. If I didn't need those features, I probably would have just done basic winsock calls.

Besides, it is a (depressing) fact that every Windows computer shipped since 1997 has IE already installed.


Great tool!!! Just donĀ“t se the direct connection with NSIS...
I thought of fixing this feature for my latest project...
---------
/arune
http://www.arune.f2s.com


Well it's not directly related to NSIS, but I figured anyone who uses NSIS would also be interested in this. It will be free and open source, of course, with a similar license.

Also, I might make patches for the NSIS source code so that the installer checks for a new version before copying files.


if you could make this so it worked with NSIS that would be extremely cool, as ive just discovered NSIS and am now trying to pester someone with some coding skills to make it so it can access the web and download files off it.


I'd be interested in testing this. Especially with
a project I'm working on now. I'm updating every few
days and would like to warn my victims/beta testers
when updates and fixes are available.

Right now I email them which annoys people who are not
actively testing. Love this idea. Where do I go to
sign up?


same here