I recently had the need to retrieve the default value for a registry key in a NAnt script. The documentation for <readregistry> doesn't specifically mention how to do this.
Turns out that it is pretty simple -- just add a trailing backslash to the key parameter for the task:
<readregistry key="SOFTWARE\Acme\" hive="LocalMachine" property="acme">
If you just specify "SOFTWARE\Acme" for the key, you will an NAnt Registry Value Not Found! error when executing the script.
Showing posts with label NAnt. Show all posts
Showing posts with label NAnt. Show all posts
Friday, November 7, 2008
Subscribe to:
Posts (Atom)