This is a fairly common question, and there isn't a One True Answer.
These are the most common techniques:
[api]: New apis / changes to apis | |
[test]: Update test/* files | |
[dist]: Changes to submodules, version bumps, updates to package.json | |
[minor]: Small changes | |
[doc]: Updates to documentation | |
[ux]: Updates to UX | |
[fix]: Bug fixes | |
[bin]: Update binary scripts associated with the project | |
[merge]: Resolved git merge from upstream or otherwise | |
[refactor]: Refactor of existing code with no external API changes |
public class Widget | |
{ | |
public int Id { get; set; } | |
public string Name { get; set; } | |
public string Description { get; set; } | |
} |
public static class TestHelpers | |
{ | |
public static void ShouldEqualWithDiff(this string actualValue, string expectedValue) | |
{ | |
ShouldEqualWithDiff(actualValue, expectedValue, DiffStyle.Full, Console.Out); | |
} | |
public static void ShouldEqualWithDiff(this string actualValue, string expectedValue, DiffStyle diffStyle) | |
{ | |
ShouldEqualWithDiff(actualValue, expectedValue, diffStyle, Console.Out); |
git reset --hard head | |
git clean -xdf -e *.suo -e packages/* | |
git checkout $args |
public class PersistenceResult | |
{ | |
readonly ModelStateDictionary modelState; | |
protected PersistenceResult(ModelStateDictionary modelState) | |
{ | |
this.modelState = modelState; | |
} | |
public static PersistenceResult Success() |
This article has been given a more permanent home on my blog. Also, since it was first written, the development of the Promises/A+ specification has made the original emphasis on Promises/A seem somewhat outdated.
Promises are a software abstraction that makes working with asynchronous operations much more pleasant. In the most basic definition, your code will move from continuation-passing style:
getTweetsFor("domenic", function (err, results) {
// the rest of your code goes here.
[user] | |
name = Brad Wilson | |
email = [email protected] | |
[alias] | |
a = add -A | |
abort = rebase --abort | |
amend = commit --amend -C HEAD | |
bl = blame -w -M -C | |
br = branch | |
cat = cat-file -t |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Reflection; | |
using System.Security.Permissions; | |
using System.Web.Mvc; | |
using Example.Web; | |
using NUnit.Framework; | |
namespace Example.UnitTests.Web |
var sb = new StringBuilder(); | |
foreach (var src in container.ComponentRegistry.Sources.Select(s => s.ToString()).OrderBy(s => s)) | |
sb.AppendLine(src); | |
sb.AppendLine(); | |
foreach (var reg in container.ComponentRegistry.Registrations.OrderBy(r => r.Activator.LimitType.FullName)) | |
{ | |
sb.AppendLine(reg.Activator.LimitType.FullName); | |
sb.Append(" ").AppendLine(reg.Lifetime.GetType().Name); |