Skip to content

Instantly share code, notes, and snippets.

View sole's full-sized avatar
🌞
🌿🌱

sole sole

🌞
🌿🌱
View GitHub Profile
@sole
sole / gist:9c83f12f1564af66ee43
Created January 8, 2016 13:51 — forked from anonymous/gist:1817540b7c0160d0ef42
Servo CSS properties
// List of all CSS properties parsed by servo as of 2016-01-08
// To extract again, build Servo and search for `is_supported_property`
// in the generated file target/debug/build/style-*/out/properties.rs
background
margin
padding
border-color
border-style
border-width
@sole
sole / ibeacon.js
Last active August 29, 2015 14:21 — forked from janjongboom/ibeacon.js
navigator.mozBluetooth.defaultAdapter.startLeScan([]).then(handle => {
console.log('Start scanning', handle);
handle.ondevicefound = e=> {
var record = parseScanRecord(e.scanRecord);
if (record) {
console.log('Found an iBeacon', record.uuid, record.major, record.minor, e.rssi);
}
}
setTimeout(() => {
@sole
sole / convert.sh
Created April 12, 2015 14:18
converting audio files in batch
(for FILE in *.wav; do ffmpeg -i "$FILE" -f mp3 -ab 256000 -map_metadata 0 -id3v2_version 3 "`basename "$FILE" .wav`.mp3" || break; done)
@sole
sole / boom.txt
Created March 25, 2015 15:18
boom.txt
hey actor conn1.child22/styleSheetsActor8
*************************
A coding exception was thrown and uncaught in a Task.
Full message: TypeError: this._tabPool is null
Full stack: BTA_createStyleSheetActor@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/actors/webbrowser.js:109:93
exports.StyleSheetsActor<._addStyleSheets/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/actors/stylesheets.js:11:93
TaskImpl_run@resource://gre/modules/Task.jsm:10:439
TaskImpl@resource://gre/modules/Task.jsm:9:98
createAsyncFunction/asyncFunction@resource://gre/modules/Task.jsm:6:32
@sole
sole / npm-debug.log
Created November 3, 2014 16:02
npm2-debug.log
This file has been truncated, but you can view the full file.
34017 verbose lock using /Users/sole/.npm/_locks/readable-stream-8e72619de60e4c69.lock for /Users/sole/data/tmp/m_i/node_modules/browserify/node_modules/labeled-stream-splicer/node_modules/stream-splicer/node_modules/readable-stream
34018 verbose lock using /Users/sole/.npm/_locks/readable-wrap-8174500540adac3b.lock for /Users/sole/data/tmp/m_i/node_modules/browserify/node_modules/labeled-stream-splicer/node_modules/stream-splicer/node_modules/readable-wrap
34019 silly gunzTarPerm extractEntry test/vectors/byte0013.dat
34020 silly gunzTarPerm extractEntry test/vectors/byte0014.dat
34021 silly install write writing indexof 0.0.1 to /Users/sole/data/tmp/m_i/node_modules/browserify/node_modules/labeled-stream-splicer/node_modules/stream-splicer/node_modules/indexof
34022 silly cache addNamed cb indexof@0.0.1
34023 verbose unbuild node_modules/browserify/node_modules/labeled-stream-splicer/node_modules/stream-splicer/node_modules/indexof
34024 verbose unlock done using /Users/sole/.npm/_locks/shasum-4a2e8a4ae5a8f
@sole
sole / attempt1.log
Created November 3, 2014 12:37
npm install log
lol:macchina_infinity sole$ rm -rf node_modules/ npm-debug.log
lol:macchina_infinity sole$ npm install
> openmusic-white-noise@1.0.1 postinstall /Users/sole/pdata/macchina_infinity/node_modules/openmusic-brown-noise/node_modules/openmusic-white-noise
> gulp build
\
module.js:340
throw err;
^
@sole
sole / npm-debug.log
Created November 3, 2014 11:28
doomed npm install
This file has been truncated, but you can view the full file.
40020 silly gunzTarPerm extractEntry README.md
40021 silly gunzTarPerm extractEntry esprima.js
40022 silly gunzTarPerm extractEntry .npmignore
40023 silly gunzTarPerm extractEntry README.md
40024 silly gunzTarPerm extractEntry test/root-nomount.js
40025 silly gunzTarPerm extractEntry test/root.js
40026 silly gunzTarPerm extractEntry test/index.html
40027 silly gunzTarPerm extractEntry .travis.yml
40028 silly gunzTarPerm extractEntry lib/code.js
40029 silly gunzTarPerm extractEntry example/line_count_options.js
@sole
sole / titles.html
Created April 16, 2014 10:19
Best titles list ever
<select name="title">
<option value=""></option>
<option value="Mr">Mr</option>
<option value="Mrs">Mrs</option>
<option value="Miss">Miss</option>
<option value="Ms">Ms</option>
<option value="Dr">Dr</option>
<option value="Admiral">Admiral</option>
<option value="Air Comm">Air Comm</option>
<option value="Ambassador">Ambassador</option>
/*var detectOrientation = function () {
if (window.matchMedia('(orientation: landscape)').matches) {
videoWidth = 135;
videoHeight = 101;
console.log('landscape mode');
} else {
videoWidth = 101;
videoHeight = 135;
console.log('portrait mode');
}
@sole
sole / gist:4121881
Created November 20, 2012 23:04 — forked from Ricket/gist:2044441
Three.js mouse picking
var projector = new THREE.Projector();
var ray = projector.pickingRay( mouseCoord, camera ); // (mouse coord are in screenspace and must be [-1, 1])
var objects = ray.intersectObjects( scene.children );
if( objects.length )
{
objects[ 0 ].object; // THREE.Particule or THREE.Mesh
objects[ 0 ].face; // THREE.Face3 or THREE.Face4 (is .object is a Mesh
objects[ 0 ].point; // THREE.Vector3
}