This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public partial class CustomService : ServiceBase | |
{ | |
protected override void OnStop() | |
{ | |
//normal shutdown code here | |
} | |
protected override void OnStart(string[] args) | |
{ | |
//normal startup code here |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Consider this, both dates below are in the past. One of these will show up, the other one will not. | |
*/ | |
INSERT INTO articles (PublishedDate) VALUES ('2011-09-20 07:15:25') | |
--this one will show up | |
INSERT INTO articles (PublishedDate) VALUES ('2011-09-20 00:00:00') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Object1 | |
{ | |
public int Id { get; set; } | |
public string FirstField { get; set; } | |
public string SecondField { get; set; } | |
} | |
public class WhenMappingTwoItemsOfTheSameType : Spec | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try { | |
$toolsDir = $(Split-Path -parent $MyInvocation.MyCommand.Definition) | |
$topDir = Split-Path -parent $toolsDir | |
$resharperPluginDir = Join-Path $topDir 'rs60\plugins' | |
$processor = Get-WmiObject Win32_Processor | |
$is64bit = $processor.AddressWidth -eq 64 | |
$progFiles = [System.Environment]::GetFolderPath('ProgramFiles') | |
if ($is64bit) {$progFiles = "$progFiles (x86)"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmd /C "webpicmdline\webpicmdline.exe /AcceptEula /SuppressReboot /Products:WindowsInstaller31" | |
cmd /C "webpicmdline\webpicmdline.exe /AcceptEula /SuppressReboot /Products:WindowsInstaller45" | |
# Powershell | |
cmd /C "webpicmdline\webpicmdline.exe /AcceptEula /SuppressReboot /Products:PowerShell" | |
cmd /C "webpicmdline\webpicmdline.exe /AcceptEula /SuppressReboot /Products:PowerShell2" | |
# .NET | |
cmd /C "webpicmdline\webpicmdline.exe /AcceptEula /SuppressReboot /Products:NETFramework20SP2" | |
cmd /C "webpicmdline\webpicmdline.exe /AcceptEula /SuppressReboot /Products:NETFramework35" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Let’s start with a story. Two guys, Bob and Richard need to get their computers ready to do some development work with Git. Neither Bob or Richard have worked with Git before. This is a story about the process they each go through to get Git. | |
Richard goes off to research. After a while he learns the tool he wants to install for Windows is mSysGit. He searches, downloads the latest version and goes to install it. He realizes he downloaded the wrong one and starts over. He may not have his settings set up properly. So then he spends time trying to figure out what his settings should be. After a process of maybe a whole morning, he finally has Git installed and hopes he is set up properly. And Richard only knows about mSysGit and not any other tools that may have helped him with using Git. | |
Bob has recently installed this neat tool called Chocolatey. He heads out to chocolatey.org and searches for Git. He learns that there are several cool tools for working with Git on Windows. He decides that he wants to use |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Describe "When installing packages from a packages.config manifest" { | |
$script:chocolatey_nuget_was_called = $false | |
$script:chocolatey_rubygem_was_called = $false | |
$script:chocolatey_webpi_was_called = $false | |
$script:packageName = '' | |
$script:version = '' | |
# content here | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Automated Testing, but Like for PowerShell | |
========================================== | |
PS \> Invoke-TestThisShiz.ps1 | |
So you say automated testing is important? | |
And you are kind of digging the awesome power of PowerShell | |
and want to learn more? What if there was some way to really test | |
PowerShell scripts in a behavior driven way? We'll explore the | |
concepts of automated testing (unit, integration, etc) and how |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// one way mapping shown for clarity sake and lots of ForMember() relationships removed | |
public class AutoMapperProfileWeb : Profile | |
{ | |
public override string ProfileName | |
{ | |
get { return "SomeApp.Web"; } | |
} | |
protected override void Configure() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
windows updates | |
msmq | |
visual studio | |
beyond compare | |
.gitconfig | |
.bash_profile | |
erlang->rabbitmq? |