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
function fish_command_not_found --on-event fish_command_not_found | |
echo "fish: Unknown command '$argv'" >&2 | |
if functions -q __fish_command_not_found_setup | |
functions -e __fish_command_not_found_setup | |
end | |
if which pkgfile ^/dev/null >/dev/null | |
if test (count $argv) -ge 1 | |
if pkgfile --binaries $argv[1] ^/dev/null >/dev/null | |
echo -e "\n'$argv[1]' can be found in these packages:" | |
for pkg in (pkgfile --binaries "$argv[1]") |
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
package main | |
import ( | |
"web" | |
"os" | |
"fmt" | |
"container/vector" | |
"time" | |
) |
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
function upload(url, uint8Data) { | |
var xhr, | |
formData = new FormData(), | |
blobBuilder = new WebKitBlobBuilder(), | |
blob; | |
blobBuilder.append(uint8Data); | |
blob = blobBuilder.getBlob(); | |
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
function bug() { | |
window.reqwest({ | |
'url': 'http://thisdoesntexisthahahaha.com', | |
'timeout': 1000 * 5, | |
'type': 'html', | |
'success': function () { | |
alert('http://thisdoesntexisthahahaha.com exists??'); | |
}, | |
'error': function () { | |
console.error('Error, trying again'); |
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 node | |
(function () { | |
'use strict'; | |
var npm = require('npm'), | |
fs = require('fs'), | |
updateTimeout, | |
seconds = 10; | |
function update(fd) { |
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
(function () { | |
'use strict'; | |
var vows = require('vows'), | |
assert = require('assert'); | |
vows.describe('some test').addBatch({ | |
'test level 1': { | |
topic: function () { | |
this.callback(null, 1); |
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
package main | |
import "fmt" | |
type Appender struct { | |
data []byte | |
} | |
func (a *Appender) Write(p []byte) (int, error) { | |
newArr := append(a.data, p...) |
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
import std.conv; | |
import std.json; | |
import std.traits; | |
/* Marshal */ | |
auto marshalJSON(T)(in T val) if (isSomeString!T) { | |
JSONValue ret; | |
ret.str = val; |
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
import std.stdio; | |
import derelict.opengl3.gl; | |
import derelict.glfw3.glfw3; | |
pragma(lib, "DerelictGL3"); | |
pragma(lib, "DerelictGLFW3"); | |
pragma(lib, "DerelictUtil"); | |
pragma(lib, "dl"); |
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
import java.util.Date; | |
/** | |
* @author T. Jameson Little | |
* | |
* Person represents a person in a family tree. | |
* For this application, father and mother are assumed to be biological parents. | |
* | |
* Domain: | |
* - birthdate: Date when the Person was born (Date object) |
OlderNewer