ContributeMost Recent Contributions (feed)
- Untitled
- 13 hours ago
-
A simple cached RSS reader. Fetches RSS feeds, displays mutliple feeds merged in date order, opens items in browser.
- Get-Payment
- 16 hours ago
-
Calculates a loan payment amount given Loan Amount, Interest Rate/Period (i.e. 7.5%/12) and Total number of payments.
Get-Payment 20000 .00625 60
- Get-ADMapObject
- 18 hours ago
-
Map Active Directory objects using the Show-NetMap script from Doug Finke. Running the script creates three functions Get-ADMapObject (which takes a string or array of strings of the AD object classes), Get-ADObjectClassName (recurses through your Active Directory and returns the names of the object classes), and New-SourceTarget (to get the ADMapObjects into the format that Show-Netmap wants).
Before the script runs, it will check for the dependencies (Doug’s script and the NetMap dll’s) and advise you if there are any missing.
- Start-Demo 3.3.3
- 19 hours ago
-
This is an overhaul of Jeffrey Snover’s original Start-Demo script … I’ve switched it to use ReadKey, which saves you some typing and makes the whole thing seem more natural when you’re demoing, (at least to me). I’ve also added a bunch of command-line options and a couple of features in the process (see the Revision History in the script).
- Get-GrowthRate
- 22 hours ago
-
Calculates percentage growth rate given a starting value, ending value, and number of periods in the range.
stahler thx! Corrected period variable name -djryan
- Highlight-Syntax 1.0
- 24 hours ago
-
The Get-Command cmdlet reveals all that you need to know about PowerShell.
By Jeffery Hicks
A terrific PowerShell feature is its ability to reveal its capabilities to you through help files and cmdlets like Get-Member. There is another cmdlet you’ll want to explore that can also reveal a lot about PowerShell, called Get-Command. If you run Get-Command at a PowerShell prompt, by default it will display all of the cmdlets available in your current PowerShell session.
But Get-Command can do much more. It can also display other “executables” like applications and scripts. Try this in your PowerShell session:
PS C:\> Get-command -commandtype application
The command might run for a while, but it will display all non-PowerShell programs including .exe, .dll and .txt files that are in your environment path.
Want to see all the functions currently defined? You can use Get-Command:
PS C:\> Get-command -commandtype function
The other command type you might be interested in is “externalscript”:
PS C:\> Get-command -commandtype externalscript
This will list all PowerShell scripts that exist in any directory in your path. But wait…there’s more.
You should be familiar with the cmdlets Verb-Noun naming convention. Curious about all the cmdlets that start with the verb “Get”?
PS C:\> get-command -verb get
Or perhaps you want to see all the cmdlets related to processes:
PS C:\> get-command -noun process
Here’s a nifty trick to get a list of all the verbs and nouns. Try these commands to see for yourself:
PS C:\> get-command | select verb -unique
PS C:\> get-command | select noun -unique
You should get a list of verbs and a list of nouns.
Finally, try a command like this:
PS C:\> get-command get-process | select *
You should get all the information about Get-Process that Get-Command can tell you. One of the properties you’ll notice is PSSnapin. You can use Get-Command to discover what cmdlets belong to a particular snapin. One way you can accomplish this is to use the -pssnapin parameter:
PS C:\> get-command -pssnapin Microsoft.PowerShell.Utility
Or use Get-Command to build a report for all your snapins:
PS C:\> get-command | sort pssnapin | format-table -groupby pssnapin Name
So the next time you’re trying to figure out what cmdlets you have or what they can do, take command with Get-Command.
- Get-GrowthRate
- 31 hours ago
-
Calculates percentage growth rate given a starting value, ending value, and number of periods in the range. @stahler thx!
- Get-ActivesyncUsers
- 38 hours ago
-
Script to retreive all users with an active sync device partnership
- cd command with history
- 2 days ago
-
I got this script originally from Jim Truher and have tweaked it a bit over time (nothing major). Basically it replaces your CD function with one that keeps a history.
- elevate-process (sudo)
- 2 days ago
-
As a former UNIX guy, I love the non-admin stuff in Vista, but got annoyed keeping two shells open (one admin and one non-admin). I wanted sudo! PowerShell made that easy. Just put this in your $profile script. Enjoy!
PowerShell Code Repository