brew install git bash-completion
Configure things:
git config --global user.name "Your Name"
git config --global user.email "[email protected]"
import { Pipe, PipeTransform } from '@angular/core'; | |
import { DomSanitizer, SafeHtml } from "@angular/platform-browser"; | |
@Pipe({ | |
name: 'safeHtml' | |
}) | |
export class SafeHtmlPipe implements PipeTransform { | |
constructor(private _sanitizer:DomSanitizer) {} |
brew install git bash-completion
Configure things:
git config --global user.name "Your Name"
git config --global user.email "[email protected]"
/** | |
* Lodash mixins for combinatorics | |
* Inspired by python itertools: https://docs.python.org/2.7/library/itertools.html | |
* | |
* Usage: | |
* permutations([0,1,2],2) // [[0,1],[0,2],[1,0],[1,2],[2,0],[2,1]] | |
* combinations([0,1,2],2) // [[0,1],[0,2],[1,2]] | |
* combinations_with_replacement([0,1,2],2)// [[0,0],[0,1],[0,2],[1,1],[1,2],[2,2]] | |
* product([0,1,2],[0,1,2]) // [[0,0],[0,1],[0,2],[1,0],[1,1],[1,2],[2,0],[2,1],[2,2]] | |
* |
#/bin/sh | |
cd ~/.vim/bundle | |
for i in `\ls -p -d */`; do | |
cd "$i" | |
echo "Updating $i..." | |
git pull --recurse-submodules | grep -v 'Already up-to-date' | sed 's/^/ /' | |
[ -f .git/.gitmodules ] && git submodule update | sed 's/^/ /' | |
cd .. | |
done |
function simpleSearch(text, str) { | |
var matches = []; | |
for (var i = 0; i <= text.length; i++) { | |
if (matchesAtIndex(i, text, str)) { | |
matches.push(i); | |
} | |
} | |
return matches; | |
} |
function Invoke-Elasticsearch { | |
[CmdletBinding()] | |
Param( | |
[Uri]$Uri, | |
[Microsoft.PowerShell.Commands.WebRequestMethod]$Method = 'Get', | |
$Body = $null, | |
[PSCredential]$Credential | |
) | |
$headers = @{} |
Note: I've added one line (#375) that appends the physical path to sys.path, because the PYTHONPATH cannot be easily overridden via web.config for multiple sites. Otherwise, the wfastcgi.py is identical to the Python Tools for Visual Studio v2.0 alpha at http://pytools.codeplex.com/releases
# -*- coding: utf-8 -*- | |
''' | |
Usage: | |
>>> f = open('usc08.10') | |
>>> x = getlines(f) | |
>>> x.next() | |
GPOLocatorLine(code='F', arg='5800', data=u'\r\n') | |
>>> print x.next().data | |
TITLE 8–ALIENS AND NATIONALITY |
//------------------------------------------------------------------------------ | |
// <auto-generated> | |
// This code was generated by a tool. | |
// Runtime Version:2.0.50727.4206 | |
// | |
// Changes to this file may cause incorrect behavior and will be lost if | |
// the code is regenerated. | |
// </auto-generated> | |
//------------------------------------------------------------------------------ |
// ==UserScript== | |
// @name Jureeka | |
// @namespace http://www.jureeka.org | |
// @description Turns legal citations in webpages into hyperlinks that direct you to online legal source material. | |
// ==/UserScript== | |
/* | |
Warnings: | |
* This triggers a memory leak bug in Firefox. |