Skip to content

Instantly share code, notes, and snippets.

Chris Hunt cdhunt

Block or report user

Report or block cdhunt

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
cdhunt / powerlambda
Last active Aug 29, 2015
Trying to create a variable containing a lambda expression
View powerlambda
# Trying to call ListByNameFiltered from
# (input parameters) => expression
# (id) => { return id == 1234; }
if ( [string]::IsNullOrEmpty([psobject].Assembly.GetType("System.Management.Automation.TypeAccelerators")::get["Expression"]) )
cdhunt / WatiNonPSate.ps1
Created Mar 27, 2014
Running automated browser tests with WatiN and PSate.
View WatiNonPSate.ps1
Add-Type -Path C:\WatiN\bin\net40\WatiN.Core.dll
if ( [string]::IsNullOrEmpty([psobject].Assembly.GetType("System.Management.Automation.TypeAccelerators")::get["Find"]) )
[psobject].Assembly.GetType("System.Management.Automation.TypeAccelerators")::add("Find", "WatiN.Core.Find")
Describing 'Bing Search' {
Given 'Search for "Automated Ops"' {
cdhunt / PoshImageProcessor
Created May 22, 2014
Posh Wrapper for the .Net ImageProcessor library
View PoshImageProcessor
Short description
Long description
Example of how to use this cmdlet
Another example of how to use this cmdlet
cdhunt / PerfmonCountersDrive
Last active Aug 29, 2015
Perfmon Counter Provider
View PerfmonCountersDrive
root {
Get-Counter -ListSet * | Select-Object -ExpandProperty CounterSetName | foreach-object {
$content = $_;
script $content {
Get-Counter -ListSet $content
View Register-HistoryInfoCustomType
function Register-HistoryInfoCustomType
Update-TypeData -TypeName Microsoft.PowerShell.Commands.HistoryInfo `
-MemberType ScriptProperty `
-MemberName TotalExecutionTime `
-value { $this.EndExecutionTime - $this.StartExecutionTime} `
View blockchain id
Verifying that +cdhunt is my blockchain ID.
cdhunt / Mount Outlook Drive
Last active Nov 1, 2015
Browse your email from PowerShell like a folder
View Mount Outlook Drive
Import-Module Simplex
New-PSDrive mail -psprovider simplex -root "C:\Temp\outlookprov.ps1"
cd mail:\Inbox
View tvdbapiconsumer
Add-Type -Path C:\Scripts\Modules\SimpleDb\SimpleDb.Esent.dll
# Data Model
$episodeClass = @"
using System;
public class Episode
public string Series { get; set; }
public int Id { get; set; }
View Start-PSNodeExample.ps1
PS C:\> Start-PSNode -Server http://localhost:9092/ -AuthenticationType IntegratedWindowsAuthentication -Command {
Get-Process | Select-Object Handle, WorkingSet, Id, Name, UserProcessorTime | ConvertTo-Json
You can’t perform that action at this time.