mIRC Home    About    Download    Register    News    Help

Print Thread
#52699 06/10/03 02:37 AM
Joined: Oct 2003
Posts: 4
D
Self-satisified door
OP Offline
Self-satisified door
D
Joined: Oct 2003
Posts: 4
How about a nice txt file with the version in on the site.
i.e www.mirc.com/version.txt and it at the moment it would just say 6.1?

#52700 06/10/03 03:24 AM
Joined: Sep 2003
Posts: 15
R
Pikka bird
Offline
Pikka bird
R
Joined: Sep 2003
Posts: 15
If you know how to script you can open a socket to the mirc homepage and filter *mIRC * has been released* to get the current version and date.

#52701 06/10/03 03:40 AM
Joined: Dec 2002
Posts: 1,527
_
Hoopy frood
Offline
Hoopy frood
_
Joined: Dec 2002
Posts: 1,527
are u referring to something like this http://www.mirc.co.uk/versions.txt ... you could then use the top line i believe to get the version from ..... either that or maybe in the whatsnew link u could pull it in there. if all your wanting is a txt file to retrieve version info to make an updater script from im going to guess that would be about the only current method i can think of.


D3m0nnet.com
#52702 06/10/03 03:41 AM
Joined: Jan 2003
Posts: 3,012
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
If you were to read the first line of (http://www.mirc.co.uk/versions.txt) that file, you would notice it has the up-to-date version number at the top. Perhaps this is what you are looking for?

EDIT: touche` d3m0n >:D Also, my reply was tot he previous poster, not the second >:D

Last edited by KingTomato; 06/10/03 03:42 AM.

-KingTomato
#52703 07/10/03 12:09 AM
Joined: Oct 2003
Posts: 4
D
Self-satisified door
OP Offline
Self-satisified door
D
Joined: Oct 2003
Posts: 4
Can we confirm that versions.txt will always be "date - version"?

#52704 07/10/03 12:25 AM
Joined: Feb 2003
Posts: 2,812
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,812
Yes, but I would recommend referencing a different document on the site for that information.

The versions.txt is one of the larger documents and so would waste the most bandwidth in retrieving. There are other documents such as http://www.mirc.co.uk/whatsnew.txt that are slightly smaller... but I would agree that a currentversion.txt file should be added to the site to save everyone a little bandwidth.

- Raccoon


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
#52705 07/10/03 01:13 AM
Joined: Jan 2003
Posts: 3,012
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
$wildtok(<readline>, *.*, 1, 32)

EDIT: Better yet, use:
$wildtok(<readline>, v*.*, 1, 32)


-KingTomato
#52706 07/10/03 02:37 AM
Joined: Dec 2002
Posts: 2,809
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 2,809
Although Racoon seems to think you can be 100% sure that it will always be date - version, I disagree. versions.txt is meant for reading, not parsing. Maybe one day Khaled might decide version - date looks nicer, it's a text file, that kind of change is something that should be expected. Formats for text files change all the time.

Additionally, saying it will _always_ be that way is imho flat out wrong. You can verify this by looking through the file:
27/04/96 - mIRC v4.1 (final bugfix release)
20/03/96 - mIRC v4.0 (final version)
13/09/95 - released mIRC v3.64 patch
13/08/95 - mIRC v3.51 (minor update)
29/06/95 - mIRC v3.42 (minor update)
21/06/95 - mIRC v3.3, v3.4
26/03/95 - mIRC v2.8c etc...

So you can see that it is NOT true that it will always be date - version because I've just shown 7 examples where it wasn't.

#52707 07/10/03 04:18 AM
Joined: Jan 2003
Posts: 3,012
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
And that would be where my $wiltok example would play a role. Look for the version "template" if you will that always begins with a v, and contains a decimal.


-KingTomato
#52708 07/10/03 07:40 PM
Joined: Dec 2002
Posts: 2,809
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 2,809
Right, but I'm saying, if other parts of the format have changed, what is to say other's won't as well? Maybe he'll drop the "v" one day, maybe he'll make it "version" none of us know, so we shouldn't answer a question such as "will it _always_ be like that" since none of us can answer that with absolute certainty.

#52709 08/10/03 05:14 AM
Joined: Feb 2003
Posts: 2,812
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,812
Thats what regular expressions are for.

And no, it wasn't my intent to suggest that Khaled will always keep the same format, but meant to confirm this is how he has historically formatted the file.

If he's really intent on checking for new versions, I'd suggest comparing the HTTP HEAD info for versions.txt and see if it changes size. That way it only sends 100 bytes or so instead of several K.


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
#52710 08/10/03 05:35 PM
Joined: Dec 2002
Posts: 2,809
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 2,809
Regexp onluy goes so far. I mean what if he decided to change it to
"New Version is 6.1b(released ...)"
Would he change it to a format like that? Probably not, but you really couldn't handle something that handles every case. Even something like doing (.*\..*) well what if instead of MM/DD/YY he does MM.DD.YY, now that will screw up your regex.

#52711 09/10/03 12:26 AM
Joined: Aug 2003
Posts: 1,831
I
Hoopy frood
Offline
Hoopy frood
I
Joined: Aug 2003
Posts: 1,831
Another, even smaller responce, which also allows to d/l the file IF it has been changed,
Get .....
if-modified-since: <day, date time GMT>


Link Copied to Clipboard