I know about command.com and .bat files, but I would very much like to
hear about your experiences and the issues involved.
My goal is to make the moodss threshold scripts functionality
(http://jfontain.free.fr/moodss.htm#menus.edit.thresholds.script) work
transparently on windows.
Many thanks in advance,
--
Jean-Luc Fontaine mailto:jfon...@free.fr http://jfontain.free.fr/
Jean-Luc Fontaine a écrit :
I have shell scripting working from Tcl very nicely on UNIX platforms (a
shell script is launched through exec'ing sh) and I was wondering if
such a functionality is easily portable on windows platforms.I know about command.com and .bat files, but I would very much like to
hear about your experiences and the issues involved.
What i did was the following:
I can say that I have never investigated a crash or hang that could be traced back to tclsh itself, although I presume, since there are bugfix releases for Tcl, that it is possible to encounter such an event. When I say "tclsh" here, I mean tclsh80, tclsh81, tclsh82 and tclsh83.
By way of comparison, I have had Linux based data acquisition jobs doing the same type of thing running 24/7 since about the same time, and I have never seen a crash or hang of the Linux box. My conclusions are, therefore, the following:
I have done a lot of Windows development, particularly with Tcl/Tk
extensions. There is no doubt that that environment has some distinct benefits,
especially where graphics animation and file system performance over a
network are concerned.
About a year ago I moved to a cross-platform GUI development environment for my extensions, which was originally intended to save me time and effort for extension porting and maintenance. I have since, however, concluded that the Linux environment is so much more stable that its a waste of time bothering with Windows, so I have just installed RH 7.2 on top of W95/W98/WME and NT. I have not seen a Blue Screen of Death since. I have not even seen a hang or a crash since!
-- Iain B. Findleton http://pages.infinit.net/cclients (514)457-0744 The motto "Honi soit qui mal y pense" is found frequently on devices of death and distruction! The motto "E pluribus unum" is found on an item that strongly distinguishes those that have it from those who don't!
Hello, Jean-Luc!
In my opinion, generally, using "shell scripting" on windows is asking
for trouble.
Scripting facilities of command.com are very weak. There is nothing
we can do with command.com that's hard to do in tcl itself.
Cmd.exe (on Windows NT) is another thing. It's much more flexible than
command.com (but beyond compare with normal UNIX shells), and it's
32-bit application. And we can expect that some experienced users of
Windows NT will find CMD.EXE-scripting functionality very useful.
At home, I use the cygwin environment (when I use Windows). It seems to
be a good idea for moodss to use cygwin shell when it's available on
user's machine. So it will be able to execute unix-oriented shell scripts
not only on unix, but also on Windows with installed cygwin.
> Many thanks in advance,
--
Good luck!
Anton Kovalenko.
> Hi,
> Why not using cygwin ?
> You only need to distribute the bash.exe, cygwin.dll, and the commands
> you use in your shell scripts ( cat.exe, ls.exe, ...), with your
> program.
> I did this several times, the advantage is that you use the same shell
> code for Unix, and windows. That means less work for you, and more time
> for the rest.
> Stephane,
Thank you for the idea.
Unfortunately, I cannot expect Windows users to install such tools, but
rather use what they know...
I will include it in the FAQ though.
Thanks again.
Jean-Luc
By example, I have to distribute a Tk/Tcl prog using some bash scripts,
and the cat, ls and find commands.
In the MyTclProgDistrib/bin directory of my distribution, I put bash.exe,
cat.exe, ls.exe, find.exe and cygwin1.dll. You don't need more and
the user doesn't need to know that the program uses bash scripts and cygwin.
Stéphane,
mmm, sorry, not many good ideas, only negativity.
SLAP me!
jooky