Home
Blog
Downloads
References
Microsoft PowerShell snippets
List of short working PowerShell script samples to get started!
Add a directory to PATH environment variable
Allow all script files executable (dangerous)
Allow signed scripts to be executable
Append output of a command to a file
Change the current directory
Change to alias drive
Change to certificate store drive
Change to function drive
Change to variable drive
Declare a vaiable and store a value to it
Delete a file
Delete a variable
Delete files recursively
Delete items of certain property value
Display 5 most recent events in an EventLog
Display first 5 items in the output
Execute a command from history
Filter the output by a value of a property
Get a value from WMI object
Get the value stored in a variable
Group files in a directory by file extension
Make a copy of a file in a specified directory
Make a copy of a file
Preview the effect of a command without actually commiting it
Search for text using pattern matching (grep)
Sign a script file using a pfx cert stored in a variable
Sort files in a directory
Store a pfx certificate to variable
Test if object has certain property
Test if path exists or not
View abridged help for a command one page at a time
View all help content for a a command
View all running processes that start with letter a
View all running processes
View an environment variable item
View EventLog
View history of commands
View just the list of directories (exlude other types)
View list of all commands one page at a time
View list of all commands
View list of all PowerShell drives
View members of the first object in the directory
View members of the type of objects
View recent command (similar to history)
View sub-keys of a Windows Registry key
View the attributes of a directory
View the content of a file
View the contents of a directory
View the current execution policy
View the list of all environment variables
View the value of an environment variable
Write output of a command to a file (more Powershell style)
Write output of a command to a file
Copyright © 2008 SpiralSpace All rights reserved.