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 flatten(l) = [ for (a = l) for (b = a) b ]; | |
module star(r, points=6, thickness=4) { | |
outerRadius = r; | |
innerRadius = r/2; | |
step = 360 / points; | |
halfStep = step / 2; | |
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
var fs = require('fs'); | |
var csv = require('csv'); | |
var md4 = require('js-md4'); | |
fs.createReadStream(__dirname+'/input.csv') | |
.pipe(csv.parse({columns: true})) | |
.pipe(csv.transform(function(record){ | |
record.my_field = md4(record.my_field); | |
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
/*jslint vars: true, plusplus: true, devel: true, nomen: true, regexp: true, indent: 4, maxerr: 50 */ | |
/*global define, $, brackets */ | |
define(function (require, exports, module) { | |
"use strict"; | |
var CommandManager = brackets.getModule("command/CommandManager"), | |
EditorManager = brackets.getModule("editor/EditorManager"), | |
Menus = brackets.getModule("command/Menus"); |
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
var http = require('http'); | |
http.createServer(function (req, res) { | |
res.writeHead(200, {'Content-Type': 'text/plain'}); | |
res.end('Hello World\n'); | |
}).listen(process.env.PORT, process.env.IP); | |
console.log('Server running!'); |
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
var FFT = require('fft'); | |
FFT_SIZE = 8; | |
var fft = new FFT.complex(FFT_SIZE, false); | |
var ifft = new FFT.complex(FFT_SIZE, true); | |
var inBuffer = new Float32Array([0,.5,1,.5,0,-.5,-1,-.5]); | |
var outBuffer = new Float32Array(2 * FFT_SIZE); | |
var outBuffer2 = new Float32Array(2 * FFT_SIZE); |
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
#!/usr/bin/env node | |
// this plugin replaces arbitrary text in arbitrary files | |
// | |
// Look for the string CONFIGURE HERE for areas that need configuration | |
// | |
var fs = require('fs'); | |
var path = require('path'); | |
var glob = require("glob"); |
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 insertStyles(selectors, styles) { | |
var text = selectors.join(', ') + ' { '; | |
for (var i in styles) { | |
text += i + ':' + styles[i] + '; '; | |
} | |
text += '}'; |
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
### Keybase proof | |
I hereby claim: | |
* I am jbeuckm on github. | |
* I am jbeuckm (https://keybase.io/jbeuckm) on keybase. | |
* I have a public key whose fingerprint is 98AA E0F0 FC55 604F 78FB 1DC9 80A6 12E4 1266 F8B3 | |
To claim this, I am signing this object: |
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
<html lang="en" xmlns:m="http://www.w3.org/1998/Math/MathML"> | |
<head> | |
<meta charset="utf-8"> | |
<style> | |
body { | |
margin: 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
<html> | |
<head> | |
<title>My first Three.js app</title> | |
<style> | |
body { | |
margin: 0; | |
} | |
canvas { | |
width: 100%; | |
height: 100% |
NewerOlder