Choice for Native Windows Scripts

What is a good Windows / xp or Vista scripting language that provides basic functionality similar to what ksh or bsh does for unix? look for simple / quick tasks, build parameters, call executable files (.exe), redirect output.

Thanks.

+4
source share
4 answers

Powershell is an obvious candidate, although everything that you described above can be achieved (with some pain) in plain old batch files. Note that batch files support a variety of shell-style lookups, redirects, and other functions, but they are not as good at this as unix shells. There is a good link for the batch file syntax at http://www.ss64.com/ntsyntax/ ; fooobar.com/questions/84346 / ... contains many links to Powershell resources.

You can also get unix shell ports that run in windows; the most useful are cygwin , unxutils, and Microsoft Windows Services for Unix . Cygwin is a complete environment that is really designed to port unix software to run on Windows. It is quite heavy and maps window letters to a path in the form /cygdrive/c/... , so the paths are incompatible with native win32 commands. Unxutils is based on mscvrt.dll and will use its own win32 C:\ stylesheets, which means that it is compatible with native windows commands. This greatly improves the integration of functions like unix scripts (including sed and awk) with existing Windows command-line utilities.

Windows also comes with a windows script host , which will allow you to script things that support the COM API. It supports vbscript and javascript and has its own API.

Finally, there are a number of third-party scripting languages, such as Python or Perl, that will run on Windows. Good Windows distributions of these languages ​​can be obtained from Activestate - Activestate python is a very mature and stable system. You can also use the .Net version of Python called IronPython , which will use the .Net libraries.

In fact, most scripting languages ​​have a fairly mature Windows port.

+7
source

Looks like you're looking for Windows Powershell

0
source

I would vote for the NXC if I had more votes today. I myself use a little Perl (ActiveState), some batch files and javascript itself. Powershell is the latest addition.

0
source

PowerShell, Ruby, Python, or one of Cygwin and AT & T Research UWIN.

0
source

All Articles