GitHub supports several lightweight markup languages for documentation; the most popular ones (generally, not just at GitHub) are Markdown and reStructuredText. Markdown is sometimes considered easier to use, and is often preferred when the purpose is simply to generate HTML. On the other hand, reStructuredText is more extensible and powerful, with native support (not just embedded HTML) for tables, as well as things like automatic generation of tables of contents.
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
<html> | |
<head> | |
<script language="javascript"> | |
function matrix_on_load() | |
{ | |
s=window.screen,w=q.width=s.width,h=q.height=s.height,m=Math.random; | |
// Initialize the number of columns | |
for(p=[],i=0;i<256;p[i++]=0); |
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
//<canvas id=canvas> | |
//original source : http://timelessname.com/sandbox/matrix.html | |
//set the canvas to take the entire screen | |
canvas.height = window.screen.height; | |
canvas.width = window.screen.width; | |
//one entry in the array per column of text | |
//each value represent the current y position of the column. (in canvas 0 is at the top and positive y values go downward) | |
var columns = [] | |
for (i = 0; i < 256; columns[i++] = 1); |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
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
// Just before switching jobs: | |
// Add one of these. | |
// Preferably into the same commit where you do a large merge. | |
// | |
// This started as a tweet with a joke of "C++ pro-tip: #define private public", | |
// and then it quickly escalated into more and more evil suggestions. | |
// I've tried to capture interesting suggestions here. | |
// | |
// Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_, | |
// @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant, |
If you're like me you have a dir like ~/Workspace/Github
where all your git repos live. I often find myself making a change in a repo, getting side tracked and ending up in another repo, or off doing something else all together. After a while I end up with several repos with modifications. This script helps me pick up where I left off by checking the status of all my repos, instead of having to check each one individually.
Usage:
git-status [directory]
This will run git status
on each repo under the directory specified. If called with no directory provided it will default to the current directory.
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
#!/usr/bin/env bash | |
# grab PAM-provided auth token | |
read token | |
# grab our user, $USER isn't always set | |
USER="$(id -un)" | |
# switch to PAM_USER if passed, buffer return value | |
$([[ "$PAM_USER" != "$USER" ]] && echo su - "$PAM_USER" -s) /usr/local/bin/gpg-preset-passphrase <<< "$token" |
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
/* plugin css */ |
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
/** | |
* Original by Zirak @ http://stackoverflow.com/a/8636050/1012431 | |
* | |
* Had some issues with the clear function | |
* | |
* @type {{intervals: Array, make: make, clear: clear, clearAll: clearAll}} | |
*/ | |
var interval = { | |
//to keep a reference to all the intervals | |
intervals : [], |
OlderNewer