March 5th, 2007

Improved Start-Demo Script

PowerShell Team
PowerShell Team

I showed my Start-Demo script to my wife and she wasn’t impressed J. She gave me some good ideas about how to make it better so I’ve updated the script and attached it to this entry. The changes are:

  1. If you typed anything other than <CR>, it added that text to the end of the command that would have been executed and ended up looking very strange. The script now:
    1. Adds a couple of space between the end of the command to be typed and the INPUT field.
    2. Changes the Foreground color to RED during input.
  2. Adds a (B) Backup command which allows you to backup the demo one command at a time.

Jeffrey Snover [MSFT]
Windows PowerShell/MMC Architect
Visit the Windows PowerShell Team blog at: http://blogs.msdn.com/PowerShell
Visit the Windows PowerShell ScriptCenter at: http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx

start-demo.ps1

Category
PowerShell

Author

PowerShell Team
PowerShell Team

PowerShell is a task-based command-line shell and scripting language built on .NET. PowerShell helps system administrators and power-users rapidly automate tasks that manage operating systems (Linux, macOS, and Windows) and processes.

0 comments

Discussion are closed.