Skip to content

Instantly share code, notes, and snippets.

View natemcmaster's full-sized avatar

Nate McMaster natemcmaster

View GitHub Profile
@natemcmaster
natemcmaster / project.diff
Created July 22, 2014 20:37
patch EF project json to build on mono
diff --git a/src/EntityFramework/project.json b/src/EntityFramework/project.json
index 9676c8f..1a130bf 100644
--- a/src/EntityFramework/project.json
+++ b/src/EntityFramework/project.json
@@ -33,16 +33,7 @@
"System.Runtime.Extensions": "4.0.10.0",
"System.Threading": "4.0.0.0"
}
- },
- ".NETPortable,Version=v4.6,Profile=Profile44": {
@natemcmaster
natemcmaster / gist:71d274cc975dfee3457a
Last active August 29, 2015 14:04
Output from Design Time Host
{
"ProjectName": "DesignTimeHostDemo",
"Configurations": [
{
"FrameworkName": "net45",
"LongFrameworkName": ".NETFramework,Version=v4.5",
"FriendlyFrameworkName": ".NET Framework 4.5",
"CompilationSettings": {
"LanguageVersion": 6,
"Defines": [
@natemcmaster
natemcmaster / nuget.config
Created July 23, 2014 18:06
nuget.config
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="AspNetVNext" value="https://www.myget.org/F/aspnetvnext/api/v2" />
<add key="NuGet.org" value="https://nuget.org/api/v2/" />
</packageSources>
</configuration>
public class SublimeWorkspace : Workspace
{
public SublimeWorkspace(string workspaceKind) : base(GetHost(), workspaceKind)
{
}
private static HostServices GetHost()
{
return MefHostServices.DefaultHost;
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.Host.Mef;
import sublime, sublime_plugin, os, sys
import subprocess
class CBluntEventlistener(sublime_plugin.EventListener):
"""docstring for CBluntEventlistener"""
def on_query_completions(self, view, prefix, locations):
pos = locations[0]
scopes = view.scope_name(pos).split()
if "source.cs" not in scopes:
return []
@natemcmaster
natemcmaster / quicksort.js
Created August 18, 2014 04:26
Simple implementation of quicksort in JS
function quickSort(arr) {
sort(arr, 0, arr.length - 1);
return arr;
}
function swap(arr, m, n) {
var tmp = arr[m];
arr[m] = arr[n];
arr[n] = tmp;
}
@natemcmaster
natemcmaster / README.md
Last active August 29, 2015 14:08
YSA 172: Nov. 7 Service Project

TL;DR

Nov 7, 7:30pm

5455 Heritage School Dr, Provo

Service project, hosting a dance for Scenic View Academy (speical education school).


This Friday is our service project and dance!

@natemcmaster
natemcmaster / index.html
Created November 22, 2014 00:44
Tithing Settlement Schedule
<html>
<head>
<meta name=Title content="Tithing Settlement">
<meta name=Keywords content="">
<meta http-equiv=Content-Type content="text/html; charset=macintosh">
<meta name=ProgId content=Excel.Sheet>
<meta name=Generator content="Microsoft Excel 14">
<link rel=File-List href="tithing_settlement_files/filelist.xml">
<title>Tithing Settlement</title>
@natemcmaster
natemcmaster / data.json
Created February 20, 2015 03:50
Simple Data struct
{
"id": 1,
"name": "P90X EZ",
"steps":[
{
"activityId":284,
"name":"Pushup",
"measurements": [
{
"typeId": 1,