This file contains 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
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
Random _rand = new Random(); | |
List<Player> players = new List<Player>(); | |
for (int i = 0; i < 20000; i++) | |
{ | |
players.Add(new Player() | |
{ |
This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.Diagnostics; | |
using System.Linq; | |
using System.Net; | |
using System.Net.Http; | |
using System.Text; | |
using System.Web; | |
using System.Web.Http; | |
using Umbraco.Core.Models; |
This file contains 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
//solution to http://stackoverflow.com/questions/25098525/angularjs-ngmodel-typing-state-directive/25099654#25099654 | |
//so I'm naming this property $typing (and not just 'typing') because it's that awesome and genious. | |
//imho this should be in the core of Angularjs | |
angular.module("myModule").directive('ngModel', ["$timeout", ngModelTyping]); | |
function ngModelTyping($timeout) { | |
return { | |
require: 'ngModel', | |
link: function (scope, elem, attr, ngModel) { |
This file contains 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
# Stop script on errors | |
$ErrorActionPreference = "Stop" | |
$user = Read-Host "Enter a github user" | |
$url = [string]::Format("https://api.github.com/users/{0}/gists", $user); | |
$gistsResponse = Invoke-WebRequest $url | |
$gists = $gistsResponse.Content | ConvertFrom-Json | |
$file = New-Item "gist.html" -ItemType "file" -Force | |
$outputStream = New-Object -TypeName "System.IO.StreamWriter" -ArgumentList @($file, $true) |
This file contains 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 child_process = require("child_process"); | |
command("dir"); | |
commandSync("ping 127.0.0.1"); | |
function command(cmd){ | |
var child = child_process.exec(cmd); | |
child.stdout.pipe(process.stdout); | |
child.stderr.pipe(process.stderr); | |
return child; |
This file contains 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
$ npm install -g gulp | |
$ npm install browser-sync gulp --save-dev |
This file contains 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
using System; | |
using System.Diagnostics; | |
using Microsoft.Owin.Hosting; | |
namespace SledgehammerSheep | |
{ | |
public class Program | |
{ | |
static void Main(string[] args) | |
{ |
This file contains 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
{ | |
"key":"ctrl+s", | |
"when":"editorFocus", | |
"command": "workbench.action.tasks.build" | |
} |
This file contains 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 gulp = require("gulp"); // Good old gulp | |
var transform = require("vinyl-transform"); // Transform browserify stream | |
var source = require("vinyl-source-stream"); // Output for bundles | |
var browserify = require("browserify"); // Bundling tool | |
var babelify = require("babelify"); // Compile JSX and ES2015 | |
var _ = require("lodash"); // Used to package.json keys | |
var connect = require("gulp-connect"); // Runs a local dev server | |
var open = require("gulp-open"); // Open a URL in a web browser | |
gulp.task("connect", function() { |
This file contains 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
{ | |
"name": "webpack-ts-babel", | |
"version": "1.0.0", | |
"description": "", | |
"main": "webpack.config.js", | |
"scripts": { | |
"test": "echo \"Error: no test specified\" && exit 1" | |
}, | |
"author": "", | |
"license": "ISC", |
OlderNewer