Skip to content

Instantly share code, notes, and snippets.

View sintaxi's full-sized avatar

Brock Whitten sintaxi

View GitHub Profile
System information commands
(*) #su Show only errors and warnings: `dmesg --level=err,warn`
(*) View dmesg output in human readable format: `dmesg -T`
(*) Get an audio notification if a new device is attached to your computer: `dmesg -tW -l notice | gawk '{ if ($4 == "Attached") { system("echo New device attached | espeak") } }`
(*) Dmesg: follow/wait for new kernel messages: `dmesg -w`
(*) The proper way to read kernel messages in realtime.: `dmesg -wx`
(*) Query graphics card: `lspci -nnk | grep -i VGA -A2`
exports.encode = function(txt){
return JSON.stringify({a: "hello world"}).replace(/^\{\"a\"\:\"/, "").replace(/\"\}$/, "")
exports.decode = function(line){
return JSON.parse('{"a": "' + line + '"}')["a"]
this.addEventListener('install', function(event) {
event.waitUntil('v1.1').then(function(cache) {
return cache.addAll([
sintaxi /
Last active May 1, 2018 00:04
Transfering a paid project on surge.

Begin by making sure both parties are on latest version of surge

npm install -g surge

Current Owner does this...

  1. Add user as collaborator by inviting them on your next deployment.
sintaxi /
Created August 5, 2017 22:23
The following is an unverified copy of an internal document circulated at a well known tech company. The author is unknown.

Reply to public response and misrepresentation

I value diversity and inclusion, am not denying that sexism exists, and don’t endorse using stereotypes. When addressing the gap in representation in the population, we need to look at population level differences in distributions. If we can’t have an honest discussion about this, then we can never truly solve the problem. Psychological safety is built on mutual respect and acceptance, but unfortunately our culture of shaming and misrepresentation is disrespectful and unaccepting of anyone outside its echo chamber. Despite what the public response seems to have been, I’ve gotten many personal messages from fellow Googlers expressing their gratitude for bringing up these very important issues which they agree with but would never have the courage to say or defend because of our shaming culture and the possibility of being fired. This needs to change.


  • Google’s political bias has equated the freedom from offense with psychological safety, but shaming
curl -sSN | tar -xjf-
cd ffmpeg-3.2.4
(./configure --help|head -n255|grep -- '--enable-'\
| perl -pe's/.*(--enable-\S+).*/$1/g' | grep -v = # 255: toolchain options
./configure --list-encoders|perl -pe's/\s+/\n/g'|sed 's/^/--enable-encoder=/'
./configure --list-decoders|perl -pe's/\s+/\n/g'|sed 's/^/--enable-decoder=/'
./configure --list-hwaccels|perl -pe's/\s+/\n/g'|sed 's/^/--enable-hwaccel=/'
./configure --list-muxers|perl -pe's/\s+/\n/g'|sed 's/^/--enable-muxer=/'
./configure --list-demuxers|perl -pe's/\s+/\n/g'|sed 's/^/--enable-demuxer=/'
sintaxi / regions.txt
Last active March 28, 2022 02:12
Surge Regions
List of regions your project is served from when you deploy using surge. : : CA : Toronto : : US : New York : : US : San Francisco : : GB : London : : NL : Amsterdam : : DE : Frankfurt : : SG : Singapore
sintaxi / 🐢.js
Last active November 14, 2016 21:51
🐢🐢🐢 All the way down.
var 🐢 = function(mstr){
if (!mstr) mstr = {}
return function(config){
for (var attr in config) { mstr[attr] = config[attr] }
var obj = scope(mstr)
obj.exec = function(){
// awesome things here
Please review the following abuse complaint and provide us with a resolution:
CloudFlare received a trademark infringement complaint regarding:
Please be aware CloudFlare is a network provider offering a reverse proxy, pass-through security service. We are not a hosting provider. CloudFlare does not control the content of our customers.
The actual IP address hosting is Using the following command, you can confirm the site in question is hosted at that IP address: curl -v -H "Host:"
sintaxi / thing.js
Last active July 9, 2016 22:00
A JavaScript question. What is the best way to handle this situation?
var expensiveThing = function(callback){
callback(null, { name: "Thurston Moore" })
}, 5000)
var fetchAndLogExpensiveThing = function(){
expensiveThing(function(err, data){
console.log(err, data)