---
title: "nsh - A tool to run .NET source files like script files."
url: "https://osherove.com/blog/2003/9/27/nsh-a-tool-to-run-net-source-files-like-script-files.md"
canonical: "https://osherove.com/blog/2003/9/27/nsh-a-tool-to-run-net-source-files-like-script-files.html"
published: "2003-09-27T21:42:00"
updated: "2003-09-27T21:42:00"
tags: [".Net Quotations", "Cool Tools"]
author: "Roy Osherove"
description: "nsh - A tool to run .NET source files like script files. [ Larkware ] From the site: .NET currently lacks a freely-available scripting language (like WSH VBScript / JScript). nsh allows you to compile and run a .NET…"
usage: "Licensed under CC BY 4.0 — reuse, quote and adapt with attribution (Roy Osherove, link to the original page)."
license: "https://creativecommons.org/licenses/by/4.0/"
---

# nsh - A tool to run .NET source files like script files.

By Roy Osherove September 27, 2003 In [.Net Quotations](https://osherove.com/blog/category/net-quotations), [Cool Tools](https://osherove.com/blog/category/cool-tools)

**Historical article** · Originally published September 27, 2003; technical details may be outdated.

[nsh](http://www.codeproject.com/useritems/nscript.asp) - A tool to run .NET source files like script files.

\[[Larkware](http://www.larkware.com/)\]

From the site:

_.NET currently lacks a freely-available scripting language (like WSH VBScript / JScript). nsh allows you to compile and run a .NET sourcefile with nearly the same convenience as running a WSH script, and better enables using .NET for scripting tasks. It's especially useful for running .NET scripts on servers that may not have VS.NET installed. An alternative to the NAnt build tool for simple ad-hoc needs._

_There are other similar tools (see Related Articles below)--this one primarily differs in being implemented in vbscript / wsh, since one primary goal was to have an any-server-friendly "xcopy deploy" (no setup or registrations). It supports optional .config and .configscc files (the latter allows specifying that the latest be pulled from sourcesafe each time before compiled and run). The standard debug .pdb file is always generated, so any .NET debugger may be used if desired with the generated .exe._

I like it. I can see some very powerful things done with this, and it's pretty darn simple to use.

## More in .Net Quotations

[All posts in .Net Quotations](https://osherove.com/blog/category/net-quotations)

- Sep 29, 2003

    ### [Creating Doc-Centric Apps in WinForms, part 1 of 3](https://osherove.com/blog/2003/9/29/creating-doc-centric-apps-in-winforms-part-1-of-3.html)

- Sep 29, 2003

    ### [Appsettings can Reference an External Config File](https://osherove.com/blog/2003/9/29/appsettings-can-reference-an-external-config-file.html)

- Sep 26, 2003

    ### [Excellent ASP.NET Identity Matrix reference](https://osherove.com/blog/2003/9/26/excellent-aspnet-identity-matrix-reference.html)

- Sep 26, 2003

    ### [Testing nirvana](https://osherove.com/blog/2003/9/26/testing-nirvana.html)


---

## About the author

**Roy Osherove**: Senior Solutions Architect at AWS working on AI for production and AI-driven development; author of The Art of Unit Testing and Elastic Leadership, with about 20 years of consulting and training on unit testing, TDD, team leadership and continuous delivery.

### Sites

- [RobotPaper](https://robotpaper.ai/): This blog: AI patterns and anti-patterns, AI and coding agents, and engineering leadership.
- [osherove.com](https://osherove.com): Roy's personal site. Author of The Art of Unit Testing and Elastic Leadership; consulting and training on unit testing, TDD, team leadership and continuous delivery, plus about 20 years of blog posts.
- [The Art of Unit Testing](https://www.artofunittesting.com): The Art of Unit Testing, 3rd Edition (Manning): readable, maintainable, trustworthy unit tests, plus TDD workshops in C#, JavaScript, Java and Kotlin.
- [5whys.com](https://www.5whys.com): Roy's writing on software team leadership: self-organizing teams, surviving chaos, learning mode and the Elastic Leadership model.
- [Pipeline Driven](https://pipelinedriven.org): Continuous delivery and DevOps practices: build patterns, pipeline-friendly testing, DevOps metrics and enterprise DevOps.
- [Elastic Leadership](https://www.elasticleadership.com): Elastic Leadership, Roy's framework for software team leaders (survival, learning and self-organizing modes).

### Social

- X: https://x.com/royosherove
- LinkedIn: https://www.linkedin.com/in/osherove/

### Contact

- Contact form: https://forms.gle/jQSx5KoXvrVA1JCK7

### License

Licensed under CC BY 4.0 — reuse, quote and adapt with attribution (Roy Osherove, link to the original page). License: https://creativecommons.org/licenses/by/4.0/
