Desktop features
[1/4] from: ptretter:charter at: 18-Jul-2001 20:27
Ok. Is it just me or is it confusing to get the Desktop to update our sites. I already
have a rebsite called TRET. I want to update the index file but I update a new one to
my website location where the files are but it doesnt seem to update on the desktop.
Is there something else we should do. The Upload Reb icon ask for a username and password
for ftp.rebol.com. ? _<- Insert Tim Allen grunt here. Any of your desktop gurus out
there?
Paul Tretter
[2/4] from: arolls:bigpond:au at: 19-Jul-2001 20:24
Two things you should check:
- that desktop is "alive", not in local mode
- from REBOL.com/Sites/, right click on your site icon to reload it.
(also to get information about the index.r file you have currently
in your public cache.)
To see your cached index file:
index-file: path-thru http://yoursite.com/index.r
probe info? index-file
print read index-file ; etc
delete index-file ; to force desktop to load anew.
[3/4] from: max::ordigraphe::com at: 19-Jul-2001 9:18
Taken from the reb site documentation...
BUT I haven't checked if it works for the top-level "site" icon...
-Max
------------------------------------
11. Auto Updating Icon Files
When the user clicks an icon, the file associated with it will be
downloaded from the network, and it will be stored in a local cache. The
next time the icon is clicked, the file will be retrieved from the
cache, rather than being downloaded from the network again.
What happens if the file is updated on the server? It will not be
downloaded again, and the user will be using the old file. There are two
solutions to this problem:
Give the new file a different name.
Provide a file stats block as part of your index file.
The first solution is obvious. The file will be downloaded because it's
name has been changed and there is no local cached copy of the file.
The second solution is more powerful. It compares the cached file's
datestamp and file size with those known by the server. This information
can be provided within the icon specification in the index file. The
file will only be downloaded if it needs to be.
To enable this auto updating of files, the index file must include
additional information for every icon that you want updated. Each icon
must include a block that specifies its file size and date. The date
must be in standard REBOL date/time/zone format. Here is an example:
icon "name" %file.r [2345 10-Apr-2000/10:20-7:00]
A simple way to create this block is to use REBOL. Here is an example
script that does so. Cut and paste the result into your index file.
REBOL [Title: "Create Icon Date/Size Stats"]
file: %desktop.txt
probe reduce [size? file modified? file]
halt
[4/4] from: ptretter:charter at: 19-Jul-2001 10:44
Excellent information. I will give this a try. They should really fix that
mechanism over at RT in a future release or patch.
Paul Tretter