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
#!/usr/bin/env python | |
import os, urllib2, re, sys, commands, random, time | |
# -- Changable Variables | |
url = 'http://interfacelift.com/wallpaper/downloads/date/widescreen/2560x1440/' | |
directory = '/Users/brant/Pictures/Wallpaper/InterfaceLift\ 2560x1440/' | |
stoponfind = '1' # Set to 0 to download all files even if the file exists and 1 to stop when it finds where it left off | |
wgetpath = 'wget' #Default on linux systems /usr/local/bin/wget on freebsd | |
# -- Should not need to edit below here unless something stops working -- |
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
data "azurerm_subscriptions" "available" {} | |
output "subscriptions" { | |
value = "${data.azurerm_subscriptions.available.subscriptions}" | |
} | |
/* | |
Sample output: | |
subscriptions = [ | |
{ |
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
goroutine 438210 [running]: | |
runtime/pprof.writeGoroutineStacks(0x140b660, 0xc420338a80, 0x410079, 0xc421817aa0) | |
/usr/local/go/src/runtime/pprof/pprof.go:650 +0xa7 | |
runtime/pprof.writeGoroutine(0x140b660, 0xc420338a80, 0x2, 0xc42005f000, 0x140b440) | |
/usr/local/go/src/runtime/pprof/pprof.go:639 +0x44 | |
runtime/pprof.(*Profile).WriteTo(0x1bd1a40, 0x140b660, 0xc420338a80, 0x2, 0xc420338a80, 0x13014b8) | |
/usr/local/go/src/runtime/pprof/pprof.go:310 +0x3e4 | |
net/http/pprof.handler.ServeHTTP(0xc426b860d1, 0x9, 0x1424100, 0xc420338a80, 0xc426299000) | |
/usr/local/go/src/net/http/pprof/pprof.go:243 +0x20d | |
net/http/pprof.Index(0x1424100, 0xc420338a80, 0xc426299000) |
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
$ModuleManifestName = 'MyModuleName.psd1' | |
$ModuleManifestPath = "$PSScriptRoot\..\$ModuleManifestName" | |
Describe 'Module Manifest Tests' { | |
# Test-ModuleManifest is slooooooow for some reason :( | |
It 'Passes Test-ModuleManifest' -Skip { | |
Test-ModuleManifest -Path $ModuleManifestPath | |
$? | Should Be $true | |
} |
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
rmo Pester -Force | |
ipmo Pester -MaximumVersion '4.0.8' | |
Invoke-Pester .\sut.ps1 | |
rmo Pester -Force | |
ipmo Pester -MaximumVersion '3.6.0' | |
Invoke-Pester .\sut.ps1 | |
<# Output: |
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 'Mocking Azure Powershell cmdlets' { | |
Mock New-AzureRmResource { Write-Host "Mock invoked" } | |
It 'Does not throw an exception' { | |
New-AzureRmResource -Properties @{} -ResourceId foo | |
} | |
} | |
<# | |
Without running Login-AzureRmAccount: |
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 System; // R# Namespace Identifier | |
using System.Dynamic; | |
using System.Linq; // R# Dead code | |
using System.Xml.XPath; | |
// Disable various dead code warnings | |
#pragma warning disable 168 | |
#pragma warning disable 219 | |
// ReSharper disable RedundantAssignment | |
// ReSharper disable SuggestUseVarKeywordEvident |
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 Source { public string Property { get; set; } } | |
public class Dest { public string Property { get; private set; } } | |
[Fact] | |
public void Wat() | |
{ | |
Mapper.CreateMap<Source, Dest>(); | |
var source = new Source {Property = "foo"}; | |
var dest = Mapper.Map<Dest>(source); | |
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
/*package.json | |
{ | |
"volo": { | |
"dependencies": { | |
"jquery": "jquery/jquery" | |
} | |
} | |
} | |
*/ | |
(function (root, factory) { |
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
C:\Users\bbobby\Code>npm install -g grunt | |
npm http GET https://registry.npmjs.org/grunt | |
npm http 304 https://registry.npmjs.org/grunt | |
npm http GET https://registry.npmjs.org/colors | |
npm http GET https://registry.npmjs.org/dateformat/1.0.2-1.2.3 | |
npm http GET https://registry.npmjs.org/glob-whatev | |
npm http GET https://registry.npmjs.org/hooker | |
npm http GET https://registry.npmjs.org/connect | |
npm http GET https://registry.npmjs.org/prompt | |
npm http GET https://registry.npmjs.org/semver |
NewerOlder