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

[REBOL] Re: read ftp:// error

From: agem:crosswinds at: 1-Jun-2001 7:26

>>>>>>>>>>>>>>>>>> Ursprüngliche Nachricht <<<<<<<<<<<<<<<<<<
Am 01.06.01, 04:01:04, schrieb "GS Jones" <[gjones05--mail--orion--org]> zum Thema [REBOL] Re: read ftp:// error:
> Hi, Thorsten, Sterling, Volker, > VN> Great to see this volleyball-programming in the list :) > Yes, it takes a hard hit to get the volleyball all the way from
> US to central Europe!
> VN> my $0.02: > VN> would work > VN> system/schemes/ftp: make system/schemes/ftp[ > VN> the-new-functions > VN> ] > VN> ? > This would be a great idea if the critical part were not buried with
> a function of a function. > VN> if ftp playes clean with contexts, it should work after that. > VN> Small enough for the user.r ? > This was exactly what I was looking for. I am certain that I am as > skilled as you, Volker. You will probably show me a nice short way to > do this.
Sorry. I thought you used full source for better patching. it was Thorsten who asked for a shorter version. Of course i should wait for you to tell, but there was the ball, quick coming, iam standing ready.. ;-) Playing with the parts of my swiss-knife, for the nice part: p: second get in system/schemes/ftp/handler 'parse-files p: first find/tail p [add-date: func[]] insert next p [convert-month] ? p for the short, no chance. I was below. You are to picky :)
> What I was wanting to do was to surgically implant a patch in the FTP > scheme. It took a lot of peeking, poking and hacking to figure this > out, but I believe that I have it. > I have looked the world over (OK, maybe only a tiny fraction of the > world) for a comprehensive list of month abbreviations. I give up!!!! > I have at least assured myself that my earlier list seems OK except
> I am still unsure about the June and July issue (Juin and Juillet -> Jui > and Jui???). I think I'll just leave it as Sterling left it in his > script. > Here is the proposed script and patch, with the buglet fixed in the > script. > ;;;;;;;;; > ;Sterling's script > convert-month: func [month [string!] /local conv seek] [ > conv: [ > "Ene" "Gen" ["Jan"] > "Fév" "Fev" ["Feb"] > "Mär" ["Mar"] > "Avr" "Abr" ["Apr"] > "Mag" "Mai" ["May"] > "Jui" "Giu" ["Jun"] > "Lug" ["Jul"] > "Aoû" "Ago" ["Aug"] > "Set" ["Sep"] > "Ott" "Out" ["Oct"] > ; ["Nov"] ; none here > "Dic" "Déc" "Dez" ["Dec"] > ] > if seek: find conv month [return first first find seek block!] > month > ] > ;Scott's surgical insertion patch tool > ;note, this will likely need to be on one line > ;changes {month: first pdate} to {month: convert-word first pdate} > insert next find pick pick get in system/schemes/ftp/handler > 'parse-files 2 31 to-set-word 'month 'convert-month
could not be shorter.
> ;;;;;;;; > This leaves the 'convert-month script in the global namespace, which > would be an benefit if needed elsewhere. I guess it could also be put > into the FTP scheme object block. My surgical insertion tool is > admittedly fragile in that it is not checking for versions. I started > out putting in a version checker, but left it out in the end. If this > "blowout" will be fixed in the next release, then the user would have
> specifically remember to remove this patch from the user.r file or
> corrupting the code.
The saw and the screwdriver and the - ah here: v: system/version v/4: v/5: 0 if 1.2.0 <> v [request/confirm "BANG?"] ;write/append %hidden-patches-log "i patched ftp-scheme!!" ? :-)
> Thorsten can check it out, and you are all welcome to comment. > --Scott Jones