tbd;
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
/** | |
* node-ASCIIp | |
* @author: [email protected] | |
* | |
* Example: | |
* var write = require('./node-ASCIIp'); | |
* console.log(write(' _.*._ ',12,5)); | |
*/ | |
module.exports = ASCIIp; |
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
{ | |
"locale": "fi", | |
"text": { | |
"#authors": [ | |
{ | |
"name": "Juri Leino", | |
"screen-name": "line-o" | |
} | |
], | |
"tweet": { |
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
# searches a combination of the given elements that matches toMatch | |
# @param c array - initially empty, carries the current combination throught | |
# the recursion | |
# @param els array - the predefined set of elements | |
# @param toMatch string - the rest-string to be matched with the elements | |
# | |
# @return an array of combinations that recursively match | |
searchCombination = (c, els, rest) -> | |
return c if rest.length==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
var TU = require('./TypeUtils'), | |
elements = "AcAgAlAmArAsAtAuBBaBeBhBiBkBrCCaCdCeCfClCmCnCoCrCsCuDbDsDyErEsEuFFeFmFrGaGdGeHHeHfHgHoHsIInIrKKrLLaLiLrLuMMdMgMnMoMtNNaNbNdNeNiNoNpOOsPPaPbPdPmPoPrPtPuQRaRbReRfRgRhRnRuSSbScSeSgSiSmSnSrTaTbTcTeThTiTlTmUUuhUuoUupUuqUusUutVWXeYYbZnZr" | |
RNG_MIN = 65, //'A' | |
RNG_MAX = 90, //'Z' | |
abbrevs = [], | |
hashes = new Object(null) | |
name = process.argv[2] | |
function matcher(a) { | |
var s=a.toLowerCase() |
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 typeUtils = | |
literals = ['boolean', 'string', 'number', 'object'], | |
types2test = literals.concat([new RegExp(/asd/), new Number(1), new String('#')]), | |
testArrays = [ | |
[true, false, true], | |
[1, 2, 3], | |
['a', 'b', 'c'], | |
[/sdf/, /asdf/, /asf/], | |
[{}, {}, {}], | |
[new String('a'), new String('b'), new String('c')], |
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
/** | |
* Warn on console and turn all LEDs red if battery is not charged enough to take off | |
* usage: | |
* ```client.on('navdata', warnOnLowBat);``` | |
*/ | |
var warnOnLowBat = function (nav){ | |
if (nav.droneState.lowBattery === 1) { | |
this.animateLeds('red', 1, 1); | |
console.warn('New battery please!'); | |
} |
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 SandBox = (function (realCtx) { | |
var get = realCtx.document.getElementById.bind(realCtx.document), | |
_evil = eval; | |
return { | |
init: function (form, script, ctx) { | |
this._form = get(form); | |
this._script = get(script); | |
this.fakeCtx = ctx; | |
this._form.onsubmit = SandBox.evaluate; |
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 sandbox(script, context){ | |
context.window = {}; | |
for (var key in context){ | |
context.window[key] = context[key]; | |
} | |
context.global = context.window; | |
eval("with (context){ " + script + " }"); | |
} |
I hereby claim:
- I am line-o on github.
- I am line0 (https://keybase.io/line0) on keybase.
- I have a public key whose fingerprint is 9620 445B D7C6 7742 66CD 11C5 FDF1 76EB 91B4 4D74
To claim this, I am signing this object:
OlderNewer