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
#! /bin/sh | |
# ------------------------------------------------------------------------------ | |
# SOME INFOS : fairly standard (debian) init script. | |
# Note that node doesn't create a PID file (hence --make-pidfile) | |
# has to be run in the background (hence --background) | |
# and NOT as root (hence --chuid) | |
# | |
# MORE INFOS : INIT SCRIPT http://www.debian.org/doc/debian-policy/ch-opersys.html#s-sysvinit | |
# INIT-INFO RULES http://wiki.debian.org/LSBInitScripts | |
# INSTALL/REMOVE http://www.debian-administration.org/articles/28 |
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
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Simple jQuery Infinite Scroll</title> | |
</head> | |
<body> | |
<h1>One</h1> | |
<br /> |
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
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Movable and Re-sizable Raphael JS Shape</title> | |
</head> | |
<body> | |
<div id="paper"></div> |
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
[Desktop Entry] | |
Type=Application | |
Terminal=false | |
StartupNotify=true | |
Name=Sublime Text 2 | |
Name[en_US]=Sublime Text 2 | |
GenericName=Text Editor | |
GenericName[en_US]=Text Editor | |
Comment=Edit text files | |
Comment[en_US]=Edit text files |
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
def colorize(value, color) | |
case color | |
when :black then "\e[30m" + value.to_s + "\e[0m" | |
when :red then "\e[31m" + value.to_s + "\e[0m" | |
when :green then "\e[32m" + value.to_s + "\e[0m" | |
when :yellow then "\e[33m" + value.to_s + "\e[0m" | |
when :blue then "\e[34m" + value.to_s + "\e[0m" | |
when :magenta then "\e[35m" + value.to_s + "\e[0m" | |
when :cyan then "\e[36m" + value.to_s + "\e[0m" | |
when :white then "\e[37m" + value.to_s + "\e[0m" |
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 ruby | |
class UI | |
def self.prompt_for_player_names | |
puts " _____ _____ ______ ______ _____ " | |
puts " / ____| | __ \\ | ____| | ____| | __ \\ " | |
puts " | | __ | |__) | | |__ | |__ | | | | " | |
puts " | | |_ | | _ / | __| | __| | | | | " | |
puts " | |__| | | | \\ \\ | |____ | |____ | |__| | " | |
puts " \\_____| |_| \\_\\ |______| |______| |_____/ " |
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
# Read and write spreadsheets with ruby using the spreadsheet gem | |
# Full Docs: http://spreadsheet.rubyforge.org/GUIDE_txt.html | |
require 'spreadsheet' | |
# Open source spreadsheet | |
workbook = Spreadsheet.open 'source.xls' | |
# READ |
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
"use strict"; | |
/* ============================================================================ | |
Gibson Research Corporation | |
UHEPRNG - Ultra High Entropy Pseudo-Random Number Generator | |
============================================================================ | |
This is GRC's cryptographically strong PRNG (pseudo-random number generator) | |
for JavaScript. It is driven by 1536 bits of entropy, stored in an array of | |
48, 32-bit JavaScript variables. Since many applications of this generator, | |
including ours with the "Off The Grid" Latin Square generator, may require | |
the deteriministic re-generation of a sequence of PRNs, this PRNG's initial |
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
/* | |
* A virtual dice roller that accepts standard dice notation | |
* | |
* | |
* Dice Notation | |
* | |
* [Num Dice] d <Num Sides> [Modifier] | |
* | |
* | |
* Num Dice - Number of dice to roll (optional) |
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
/** | |
* A Unique Collection Object | |
* Items are alphanumeric strings (defined by createItem function) | |
* Items are 7 characters long (defined by itemLength variable) | |
*/ | |
function UniqueCollection() { | |
var items = []; | |
var itemLength = 7; | |
/* Create a new item */ |
OlderNewer