(redirected from DotNet.PowerShell)

 

 

Wikipedia:Windows_PowerShell
Getting Started guide
getting started with Windows PowerShell
http://powershell.com/cs/
http://www.powershellpro.com/powershell-tutorial-introduction/tutorial-windows-powershell-console/
http://www.windowsitpro.com/article/windows-powershell/powershell-101-lesson-4.aspx

 

http://devcentral.f5.com/weblogs/Joe/archive/2009/01/09/powershell-abcs---o-is-for-output.aspx
Write-Host to output to console

 

 

http://huddledmasses.org/register-dll-calling-regsvr32-without-messageboxes-in-powershell/

 

For WinXP and beyond there is the MS Powershell.

 

script for Twitter

 

 

Extension

{scriptname}.ps1 - but who could forget that, right?!!

 

 

Installation

Install powershell on windows Server 2003
Install powershell on Windows Server 2008

  • NOTE: Powershell does come with Server2008, but you may need to install it (see instructions).
  • If you can’t find it, search the programs files, and add it to your PATH variable
  • then powershell should be available on the command-line
  • Set the execution policy
    • Set-ExecutionPolicy RemoteSigned, for example

 

 

Running Scripts

from within PowerShell or running PowerShell from CMD prompt

 

 

Use with Console2

See Programming.Shell#console2

 

NOTE: when configuring Power Shell do NOT use a custom text-color, as this will over-ride custom colors coming out of PS. Unless you like the monochrome look. In which case, go at it.

 

 

 

 

some scripts

delete all visual-source-safe files from a project

Where .\ is the path to you project -- in this case, being executed from within the project root.

get-childitem .\ -force -include "*.scc" -recurse | remove-item -force

 

-force is (probably) required as *.scc files are usually “hidden” files, and -force is the only way to “find” them.

 

Create a new GUID

[guid]::NewGuid() As found here.

 

 

link-dump

accessing environment variables

 

$env:<variable>

 

 

Integrating with Emacs

http://stackoverflow.com/questions/872510/can-i-use-powershell-in-shell-mode-for-emacs

 

 

See Also

PoshGit
Chocolatey has a simple install with Power Shell

 

 

Category Tags

CommandLine Shell PowerShell