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
using (var session = documentStore.OpenSession()) | |
{ | |
session.Load<Concert>(1) | |
} |
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
param([string]$XenServerPoolMaster) | |
Add-PSSnapIn XenServerPSSnapin | |
. ".\credentials.ps1" | |
. ".\teamcity.ps1" | |
Connect-XenServer -Server $XenServerPoolMaster -Creds (Get-XenServerCredential) -NoWarnNewCertificates -NoWarnCertificates | |
Get-XenServer:VM -Server $XenServerPoolMaster |? { $_.tags -contains 'active' } |? { $_.name_label -ne $env:COMPUTERNAME } |% { |
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
param([String]$XenServerPoolMaster, [String]$TemplateName, [int]$NumberOfBuildAgents) | |
Add-PSSnapIn XenServerPSSnapin | |
. ".\credentials.ps1" | |
. ".\teamcity.ps1" | |
Connect-XenServer -Server $XenServerPoolMaster -Creds (Get-XenServerCredential) -NoWarnNewCertificates -NoWarnCertificates | |
function private:New-BuildAgentVM([string]$XenServerPoolMaster, [string]$templateName, [int]$buildAgentIndex) { |
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
$encryptionKey = (Get-Content "C:\EncryptionKey.txt") | |
$encryptionKey = [System.Text.Encoding]::Unicode.GetBytes($encryptionKey) | |
function Get-MyCredential { | |
$myPassword = Get-PasswordAsSecureString | |
return new-object System.Management.Automation.PSCredential "My.Username", $domainAdminPassword | |
} | |
function Get-PasswordAsSecureString { | |
return ConvertTo-SecureString -Key $encryptionKey "Place string representation of encrypted password 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
2013-05-13 21:44:23.1672 - WARN: *** Detected Unit Test Runner, setting MainThreadScheduler to Immediate *** | |
2013-05-13 21:44:23.1825 - WARN: If we are not actually in a test runner, please file a bug | |
2013-05-13 21:44:23.2136 - ERROR: Couldn't load settings, creating them from scratch | |
EXCEPTION: System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\Users\alastair\AppData\Roaming\SaveAllTheTime\settings.json'. | |
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) | |
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) | |
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) | |
at System.IO.StreamReader |
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
function Ai() { | |
this.UP = 0; | |
this.RIGHT = 1; | |
this.DOWN = 2; | |
this.LEFT = 3; | |
this.ORIGIN = | |
this.init = function() { | |
this.move = this.UP; |
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
function global:build() { | |
param( | |
# The Tasks to execute. An empty list runs the | |
# default task, as defined in build.ps1 | |
[string[]] $Tasks = @(), | |
[string] $Configuration = "Release", | |
[string] $BuildNumber = '0' | |
) | |
RestoreBuildLevelPackages |
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 int WhatDoIDo(int[] numbers) | |
{ | |
return numbers.Count(i => i % 2 == 0) | |
} |
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
param( | |
[Parameter(Mandatory=$true)] | |
[string]$SshKeyFile, | |
[Parameter(Mandatory=$true)] | |
[string]$Location = "westeurope", | |
[string]$ResourceGroup = "k8s-$Location", | |
[string]$ClusterName = "k8s-$Location", | |
[string]$DnsPrefix = "ch360", | |
[int]$MasterCount = 1, | |
[int]$AgentCount = 3, |
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
import { ScreenCap } from "../../helpers/ScreenCap" | |
import { Casper } from "casperjs" | |
export class GitHubSignIn { | |
private readonly OAUTH_AUTHORISATION_FORM = '.oauth-review-permissions form[method=post]'; | |
constructor(private casper: Casper, private screencap: ScreenCap) { } | |
login(username: string, password: string): void { | |
this.casper |