Skip to content

Instantly share code, notes, and snippets.

View idlem1nd's full-sized avatar

Tim Williams idlem1nd

View GitHub Profile
$.connection.hub.logging = true;
$.connection.hub.url = "https://push-api.tfl.gov.uk/signalr/hubs/signalr";
var hub = $.connection.predictionsRoomHub;
hub.client.showPredictions = updateBoard;
$.connection.hub.start()
.done(function() {
console.log("tfl.predictions: connection started");
@idlem1nd
idlem1nd / LatLonConversion.cs
Created September 25, 2014 10:13
Can convert WGS84 Lat/Lon to OSGB Eastings/Northings and vice-versa. Credit for original work goes to Jonathan Stott
using System;
public class LatLonConversion
{
private LatLonConversion() { }
private static double Deg2Rad(double x)
{
return x * (Math.PI / 180);
}

Migrating from TFS to Git

This is a quick how-to of my experience using the git-tfs bridge to keep a TFS repository in sync with a Git repository, which subsequently allowed TFS to be migrated away from completely.

The git-tfs tool

At the time of writing, the latest version of git-tfs has issues with TFS branches that have been renamed and/or reparented. It also struggles with baseless merges. We will use pmmiosec's fork of git-tfs, specifically the rename_branch, which resolves issue #480 with git-tfs. Full instructions on building git-tfs from source can be found here, but to summarise:

# Get the source code