This file contains hidden or 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
| <!-- Assume a data context with all the appropriate bindings --> | |
| <Window | |
| <Window.InputBindings> | |
| <KeyBinding Key="Up" Command="{Binding ZoomIn}" /> | |
| <KeyBinding Key="Down" Command="{Binding ZoomOut}" /> | |
| </Window.InputBindings> | |
| <Grid> | |
| <Image Source="{Binding MyPath}" HorizontalAlignment="Center" | |
| VerticalAlignment="Center" Width="{Binding DisplayedWidth}" > | |
| <Image.Triggers> |
This file contains hidden or 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 Delete-LocalBranches ($Commit = 'HEAD', [switch]$Force) { | |
| git branch | | |
| ? { $_ -notmatch '(^\*)|(^. master$)' } | | |
| % { git branch $(if($Force) { '-D' } else { "-d" }) $_.Substring(2) } | |
| } |
This file contains hidden or 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; | |
| using System.Collections.Generic; | |
| using System.IO; | |
| using System.IO.Compression; | |
| using System.Linq; | |
| using System.Reflection; | |
| using System.Text; | |
| using System.Text.RegularExpressions; | |
| using System.Threading.Tasks; |
This file contains hidden or 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; | |
| using System.Collections.Generic; | |
| using System.Diagnostics; | |
| using System.Linq; | |
| using System.Text; | |
| using System.Threading.Tasks; | |
| namespace ListAllWebApps | |
| { | |
| class Program |
This file contains hidden or 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
| <foreach item="File" property="filename"> | |
| <in> | |
| <items> | |
| <include name="C:\somePath\dbDirectory\**.sql.template"/> | |
| </items> | |
| </in> | |
| <do> | |
| <loadfile file="${filename}" property="fileContents"> | |
| <filterchain> | |
| <replacetokens> |
This file contains hidden or 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; | |
| using System.IO; | |
| using System.Threading.Tasks; | |
| using Microsoft.WindowsAzure.Storage; | |
| using Microsoft.WindowsAzure.Storage.Blob; | |
| namespace PublishClickOnceToAzure | |
| { | |
| public class AzureBlobClient | |
| { |
This file contains hidden or 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; | |
| using Newtonsoft.Json; | |
| using Newtonsoft.Json.Serialization; | |
| using RestSharp; | |
| using RestSharp.Deserializers; | |
| namespace MyAwesomeProject | |
| { | |
| public class JsonDeserializer : IDeserializer | |
| { |
This file contains hidden or 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 static IEnumerable<string> GetFiles(string root, string searchPattern) | |
| { | |
| Stack<string> pending = new Stack<string>(); | |
| pending.Push(root); | |
| while (pending.Count != 0) | |
| { | |
| var path = pending.Pop(); | |
| string[] next = null; | |
| try | |
| { |
This file contains hidden or 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; | |
| using System.Collections; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| namespace Confections | |
| { | |
| public class Pie<T> : IReadOnlyCollection<Slice<T>> | |
| { | |
| readonly List<Slice<T>> slices; |
OlderNewer