Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Modifying dates with REBOL

From: greggirwin:mindspring at: 25-Jan-2003 12:47

Hi Mat, MB> So it occurred to me that I could somehow alter the modified stamps via MB> ftp after scanning the time stamps off the local files with REBOL. MB> Yet... I can't seem to find any details in REBOL of modifying dates on MB> files, let alone via FTP. I don't think this will work over FTP, but it's a start for you. touch: func [ {Set the modification timestamp of the file.} files [file! block!] "The file, or files, you want to stamp" time [date!] "The date and time to stamp them with" /local rd-only ][ ; We have to turn off the read-only attribute if it's on. foreach item compose [(files)] [ rd-only: not get-modes item 'owner-write set-modes to-file item [owner-write: true modification-date: time] if rd-only [set-modes item [owner-write: false]] ] ] -- Gregg