On 14/02/2012, at 7:38 AM, Matt Welland wrote:

> 
> 
> On Mon, Feb 13, 2012 at 1:43 PM, Steve Bennett <[email protected]> wrote:
> 
> On 14/02/2012, at 4:22 AM, Matt Welland wrote:
> 
>> I think it may be very useful if it was possible to call tcl scripts stored 
>> in the repo db (revision controlled files or wiki pages?) at pre/post commit 
>> and other interesting times. I know hooks were previously not accepted since 
>> making things consistent between Windows and Linux was difficult.  But that 
>> concern should be addressed if the hooks call tcl or th1 scripts instead of 
>> directly sending commands to the OS. It looks like jimtcl supplies os.fork, 
>> os.wait etc. but I didn't see a posix system, can jimtcl run commands on 
>> Unix?
> 
> Yes, indeed!
> 
> You want the 'exec' command - 
> http://jim.tcl.tk/fossil/doc/trunk/Tcl_shipped.html#_exec
> 
> You can try this out with the 'jimtcl' branch of fossil.
> 
> Hi Steve,
> 
> This sounds cool, so is the mechanism to call a jimtcl routine implemented on 
> various actions and if so then how do I, for example, call a tcl script when 
> sync is completed?

Joe Mistachkin has recently added support for calling TH1 scripts on certain 
actions.
See http://www.fossil-scm.org/index.html/info/0b61e3c019

In the jimtcl branch, TH1 is replaced with Jim Tcl, so any of these scripts has 
the full power of Jim Tcl, including exec.

There is some ongoing work to be done to identify other points where a script 
could/should be called,
what information is available to the script, and what the script can do.

One thing I would like to see is a Tcl interface into fossil so that scripts 
can do queries against fossil without
resorting to direct sql.

Cheers,
Steve

> 
> Thanks,
> 
> Matt
> -=- 
> Cheers,
> Steve
> 
> --
> µWeb: Embedded Web Framework - http://uweb.workware.net.au/
> WorkWare Systems Pty Ltd
> W: www.workware.net.au      P: +61 434 921 300
> E: [email protected]   F: +61 7 3391 6002
> 
> 
> 
> 
> 
> 
> _______________________________________________
> fossil-users mailing list
> [email protected]
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
> 
> 
> _______________________________________________
> fossil-users mailing list
> [email protected]
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

--
µWeb: Embedded Web Framework - http://uweb.workware.net.au/
WorkWare Systems Pty Ltd
W: www.workware.net.au      P: +61 434 921 300
E: [email protected]   F: +61 7 3391 6002





_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to