CodeBetter.Com
CodeBetter.Com
RSS 2.0 via Feedburner
           Do you Twitter? Follow us @CodeBetter

Jeffrey Palermo (.com)

Blog moved to www.jeffreypalermo.com

Palermo .Net Scripter utility replaces CSScripter by offering full support for C#, VB.Net and JScript.Net command-line scripting - level 200

Earlier, I posted my C# Scripter command-line utility.  I only have a need to script C#, so that's all the capability I added initially, but there was some interest in scripting VB.Net, so I refactored and enhanced my scripter, and I've renamed it "netscripter.exe".  No need to install it.  Just drop it in your tools directory and use it against any file with .Net code in it.  It now supports C#, VB.Net, and JScript.Net.  It's switches on the file extension, so name your script files .cs, .vb, and .js respectively.  The script file must be compilable into a console app to be compatible, and that's very simple to do.  With the download, I've included a sample script file for each of the languages. You can use those as references.  I'm not sure what features can be added to this simple tool beyond what is there, but I'm open for suggestions.  Just in the last few days, this tool has saved my team a _ton_ of time with mechanical task that are just a little to complicated for shell files, but simple to do with .Net.

You can download the new NetScripter here.

Don't forget to leave me feedback.



Comments

David Neal said:

Very, very cool. I can already think of several things I could use this for. I can also imagine using this scripting capability in some of my own apps. Here's my vote for you giving us the source code :)
# October 12, 2005 1:07 PM

Jon Galloway said:

Installed! ;-)

I added the folder to my path and added the following batch file, which I titled ns.bat:
TITLE NetScripter %1
pushd %~dp0
netscripter %1 %2 %3 %4 %5 %6 %7 %8 %9
popd

Now I can throw all my scripts in c:\utils\NetScripter\, and execute any of them from Start / Run by typing: ns jeffery.cs param1 param2
# October 12, 2005 3:53 PM

Jeffrey Palermo said:

Very cool indeed. Less to type. I'd be interested to know what type of things you are using it for. I'm using it for information filters. I have many C# scripts that do a Regex looking for a pattern. Upon find it, it does a little something. I'm doing this on a folder structure with 1000s of files. A real time-saver and a whole lot easier than do this with shell scripting.
# October 12, 2005 5:28 PM

Jeff Atwood said:

Why do you guys hate Monad so much?

I'm just saying!
# October 12, 2005 8:07 PM

Jeffrey Palermo said:

I listened to a webcast about Monad, and it sounds very promising, and I look forward to using it when it is available, but it's not right now.

I'm not sure what you mean by "Why do you guys hate Monad so much?". Reading the text above, I don't see where Monad was every mentioned, and I'm not sure who you are referring to (the hater).

Please elaborate.
# October 12, 2005 11:02 PM

Chris Martin said:

This is pretty cool. Kudos. But it really begs the question: Why not just use the great Alintex? http://www.alintex.com/
# October 13, 2005 1:04 AM

Jeffrey Palermo said:

UPDATE:  This utility has been upgraded to support more .Net languages.  See here for the newer...
# October 13, 2005 9:08 AM

Andy said:

Well, you can download Monad Beta 2 right now for free (more at http://www.leeholmes.com/blog/PermaLink,guid,8b26fea1-723d-4bd6-93c1-19d681af9276.aspx). I've been using it for a while now, and I haven't had any problems with it or anything.

From what I've done with it, I would say that Monad is more than just a .NET scripting language. Not only does it pass objects through the pipeline instead of text, but you can also extend existing types with new properties, methods, etc. It's definitely worth it to try it out and play around with it for a while.
# October 22, 2005 11:26 PM

Jeffrey Palermo said:

I appreciate the information, Andy, and I look forward to using it when Microsoft releases and supports it. I'm not able to use any non-supported products except in VPCs right now. It sounds very promising, however, as the replacement for the current DOS shell.
# October 22, 2005 11:39 PM

Rick.Stavanja.com said:

# October 24, 2005 1:53 AM

.Net Adventures said:


Run .Net console class as batch files from the command line with this
utility that will compile...
# November 5, 2005 5:06 PM

.Net Adventures said:


Run .Net console class as batch files from the command line with this
utility that will compile...
# November 5, 2005 5:08 PM

.Net Adventures said:


Run .Net console class as batch files from the command line with this
utility that will compile...
# November 5, 2005 5:30 PM

Rick.Stavanja.com said:

Several of you seemed to enjoy my Links of the Week post a couple weeks ago. Since it's a fairly

# September 14, 2006 1:57 AM

About Jeffrey Palermo

Jeffrey Palermo is a software management consultant and the CTO of Headspring Systems in Austin, TX. Jeffrey specializes in Agile coaching and helps companies double the productivity of software teams. Jeffrey is an MCSD.Net , Microsoft MVP, Certified Scrummaster, Austin .Net User Group leader, AgileAustin board member, INETA speaker, INETA Membership Mentor, Christian, husband, father, motorcyclist, Eagle Scout, U.S. Army Veteran, and Texas A&M University graduate. Check out Devlicio.us!

This Blog

Syndication

News

Headspring Systems

View Jeffrey Palermo's profile on LinkedIn

See my new blog at .jeffreypalermo.com