Hi Viksit, For production support, I also wanted to "tail -f" a file on a Windows server with no "tail" facility (no one had installed the Windows Resource Kit yet, and executing the install file myself would've been prohibitive (it's a long story)). However, this Windows server did have Java. I thought to write a "tail -f" with clojure until I discovered the JDK installed was 1.4.2.
I found an old version of Jython that was compatible (at the time, I used jython 2.1 and 2.2) and wrote a Jython script that implemented "tail -f" for me. It's not clojure, but it did solve my initial problem, which was doing a "tail -f" on a log file. I didn't build any parsing facility because I was content to have the file write out to a Windows GUI dialog. I realise it's not exactly what you want, but it's ready (with no guarantees that it's safe, as with any code received from strangers) and located in it's entirety at: https://sites.google.com/site/kevinkwoo/work/guitail-fforjython21-1 It should be publicly accessible, but if it's not do let me know! Regards, Kevin On Dec 2, 6:53 pm, viksit <vik...@gmail.com> wrote: > Hi all, > > What would you recommend as the best method to tail a file using > Clojure? Are there any built in functions in contrib or core that > allow a program to read the last line of a file as it is appended to? > If not - how do people solve a problem like this? > > My aim is simple - I've got a log file and I'd like to parse it as it > gets appended to. > > Thanks > Viksit -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en