This file contains hidden or 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
#!/bin/bash | |
for d in */ ; do | |
echo "-- $d --" | |
cd $d | |
git status -s | |
cd .. | |
done |
This file contains hidden or 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
function goodbye(e) { | |
if(!e) e = window.event; | |
//e.cancelBubble supported by IE - this will kill the bubbling process. | |
e.cancelBubble = true; | |
e.returnValue = 'You sure you want to leave?'; | |
//This is displayed on the dialog | |
//e.stopPropagation works in Firefox. | |
if (e.stopPropagation) { | |
e.stopPropagation(); |
This file contains hidden or 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
# get a homestead box | |
vagrant box add laravel/homestead | |
# clone homestead and go into it | |
git clone [email protected]:laravel/homestead.git | |
cd homestead | |
# put composer into it | |
curl -sS https://getcomposer.org/installer | php |
This file contains hidden or 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
/* | |
Make coordinates counter-clockwise | |
http://stackoverflow.com/questions/1165647/how-to-determine-if-a-list-of-polygon-points-are-in-clockwise-order | |
(x2-x1)(y2+y1) | |
point[0] = (5,0) edge[0]: (6-5)(4+0) = 4 | |
point[1] = (6,4) edge[1]: (4-6)(5+4) = -18 |
This file contains hidden or 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
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"> | |
<HTML> | |
<HEAD> | |
<META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=utf-8"> | |
<TITLE></TITLE> | |
<META NAME="GENERATOR" CONTENT="OpenOffice 4.1.1 (Unix)"> | |
<META NAME="CREATED" CONTENT="0;0"> | |
<META NAME="CHANGED" CONTENT="0;0"> |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Filter</title> | |
<script type="text/javascript" src="https://code.jquery.com/jquery-1.11.2.min.js"></script> | |
</head> | |
<body> | |
<div id="proc"><p><a href="http://www.oscars.org/hollywoodcostume/" target="_blank">Academy of Motion Picture Arts and Sciences</a> <br><a href="http://annenbergphotospace.org/" target="_blank">Annenberg Space for Photography</a> <br><a href="http://www.armoryarts.org/" target="_blank">Armory Center for the Arts</a> <br><a href="http://www.caamuseum.org/" target="_blank">California African American Museum</a> <br><a href="http://californiasciencecenter.org/" target="_blank">California Science Center</a><br><a href="http://camla.org/" target="_blank">Chinese American Museum</a> <br><a href="http://www.cafam.org/" target="_blank">Craft Folk & Art Museum</a> <br><a href="http://www.fowler.ucla.edu/" target="_blank">Fowler Museum at UCLA</a> <br><a href="http://www.getty.edu/visit/center/" target="_blank">The Getty Center</a> <br><a href="http: |
This file contains hidden or 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
// http://www.html5rocks.com/en/tutorials/es6/promises/ | |
function get(url) { | |
// Return a new promise. | |
return new Promise(function(resolve, reject) { | |
// Do the usual XHR stuff | |
var req = new XMLHttpRequest(); | |
req.open('GET', url); | |
req.onload = function() { |
This file contains hidden or 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
<!DOCTYPE html> | |
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]--> | |
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]--> | |
<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]--> | |
<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]--> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> | |
<link rel="stylesheet" href="style.css"> | |
<title></title> |
This file contains hidden or 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
GIT on bitbucket notes | |
Set up | |
1. Identify yourself | |
# git config --global user.name "My Name" | |
# git config --global user.email [email protected] | |
2. Set up SSH keys - add .ssh/id_rsa.pub to bitbucket | |
https://bitbucket.org/account/user/[username]/ssh-keys/ |
NewerOlder