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 InstallService ($p,$s,$n,$e,$v) { | |
| $stop = "$p\$s stop --environment=$e" | |
| $uninstall = "$p\$s uninstall --environment=$e" | |
| $install = "$p\$s install --environment=$e" | |
| $start = "$p\$s start --environment=$e" | |
| $serviceName = "$n$" + $e | |
| $service = Get-WmiObject -Class Win32_Service -Filter "Name='$serviceName'" |
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
| var dataSource = new SqlServerDataSource | |
| { | |
| ConnectionString = "server=server;database=database;User Id=id; Password=password;" | |
| }; | |
| var procedure = new StoredProcedure("SomeAwesomeProcedure"); | |
| procedure.AddInput("Input1", "bar"); | |
| procedure.AddInput("Input2", "baz"); | |
| dataSource.Execute(procedure, t => |
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 class EmberPipelineModifier : IBundlePipelineModifier<HtmlTemplateBundle> | |
| { | |
| public IBundlePipeline<HtmlTemplateBundle> Modify(IBundlePipeline<HtmlTemplateBundle> pipeline) | |
| { | |
| pipeline.Add(new EmberCompatabilityProcessor()); | |
| return pipeline; | |
| } | |
| } |
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
| [TestFixture] | |
| public class Example | |
| { | |
| public class Bus | |
| { | |
| public void SubscribeAsync<T>(string subscriptionId, Func<T, Task> onMessage) { } | |
| } | |
| public static MethodInfo GetMethod<T>(Expression<Action<T>> methodSelector) | |
| { |
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 class SignalJsonSerializer : IJsonSerializer | |
| { | |
| public class DefaultingJsonContractResolver : IContractResolver | |
| { | |
| private readonly Assembly _assembly; | |
| private readonly IContractResolver _camelCaseContractResolver; | |
| private readonly IContractResolver _defaultContractSerializer; | |
| public DefaultingJsonContractResolver() | |
| { |
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
| Ember.Handlebars.registerBoundHelper('timeSince', function (value) { | |
| var when = moment(value).fromNow(); | |
| return new Handlebars.SafeString('<span data-livestamp="' + value + '">' + when + '</span>'); | |
| }); |
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
| {{view App.SimpleTableView rowsBinding="results" columnsBinding="columns"}} |
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
| App.WorkersIndexController = Ember.ArrayController.extend | |
| refresh: -> | |
| console.log 'refreshing workers' | |
| @set 'refreshing', App.Worker.find() | |
| update: (-> | |
| refreshing = @get 'refreshing' | |
| return unless refreshing.get('isLoaded') | |
| Ember.run => | |
| @set 'content', refreshing |
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
| Import-Module WebAdministration | |
| ########################### | |
| # externally configured variables | |
| ########################### | |
| $subdomain = 'subdomain' # e.g. subdomain.yourdomain.com | |
| $appPoolName = 'Awesome App Pool!!!' | |
| $appPoolFrameworkVersion = "v4.0" | |
| $domain = 'yourdomain.com' |
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
| param($installPath, $toolsPath, $package) | |
| # notify the user we're going to be doing something destructive | |
| # find out where to put the files, we're going to assume that the | |
| # solution file is in a ./src directory and we want to put | |
| # everything in a ./build directory at the same level. | |
| $rootDir = (Get-Item $installPath).parent.parent.parent.fullname | |
| $deployTarget = "$rootDir\deploy\support\" |