Skip to content

Instantly share code, notes, and snippets.

View jayharris's full-sized avatar

Jay Harris jayharris

View GitHub Profile
write-host $env:BUILD_SOURCEBRANCHNAME
if ($env:BUILD_SOURCEBRANCHNAME -eq "Develop"){
Write-Output ("##vso[build.updatebuildnumber]" + $env:BUILD_BUILDNUMBER+"-beta")
write-host "setting version as -beta"
}
else
{
if ($env:BUILD_SOURCEBRANCHNAME -ne "master"){
Write-Output ("##vso[build.updatebuildnumber]" + $env:BUILD_BUILDNUMBER+"-alpha")

Keybase proof

I hereby claim:

  • I am jayharris on github.
  • I am jayharris (https://keybase.io/jayharris) on keybase.
  • I have a public key whose fingerprint is 8A72 860E 63C6 86F6 082A B5BF FCFC 2146 944E 9E18

To claim this, I am signing this object:

@jayharris
jayharris / DoingBootstrapRight.html
Last active September 27, 2017 15:49
Semantic CSS with Bootstrap and LESS
<div class="DoingItRight">This is how it is done!</div>
@jayharris
jayharris / CountryController.cs
Created September 24, 2013 13:09
Register WebAPI Routes with multiple nested segments
public class CountryController : ApiController {
public IEnumerable<CountryResponseModel> Get() {
// Logic
return model;
}
public CountryResponseModel Get(int id) {
// Logic
return model;
}
@jayharris
jayharris / LogInjectionModule
Created January 28, 2013 08:21
Autofac Module to inject log4net ILog properties with type-specific Logs.
public class LogInjectionModule : Module {
protected override void AttachToComponentRegistration(IComponentRegistry registry,
IComponentRegistration registration) {
registration.Preparing += OnComponentPreparing;
var implementationType = registration.Activator.LimitType;
var injectors = BuildInjectors(implementationType).ToArray();
if (!injectors.Any()) {
return;