Skip to content

Instantly share code, notes, and snippets.

View amonks's full-sized avatar
🐋
🐟🐠🐡

Andrew Monks amonks

🐋
🐟🐠🐡
View GitHub Profile
// ⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️
// ⚠️ This isn't very written yet! ⚠️
// ⚠️ I'll post on monks.co when ⚠️
// ⚠️ it's more done. ⚠️
// ⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️⚠️
// check out this gist to see a changelog:
// https://gist.github.com/amonks/b06302fc5489d28b243e627fc2a910b4/
/* global R */

installation:

$ npm install --save express

usage

option 1

$ node ./static-server.js [port]
Access Key ID:
AKIAIMIVRDXW6NR2QS3Q
Secret Access Key:
4dQGIW/9fQJHF+KE86CQY9560GWNClGbrNaKzUL9

So you want to babel all of your javascript, but you don't want to think about gulp or webpack or crap like that. You want to use tools that come preinstalled on OSX.

Use this.

@amonks
amonks / kwmrc
Last active September 5, 2016 14:51
/*
9/5/16 Andrew Monks
https://koekeishiya.github.io/kwm/kwmc.html
https://gist.github.com/amonks/db69836fc17d48be49e0166d53ccc77d
*/
// Set default values for screen padding
kwmc config padding 21 0 21 0
// Set default values for container gaps
@amonks
amonks / monad.js
Created July 19, 2016 08:37
How to work with Monads IRL // Chaining in JavaScript
/* How to work with Monads IRL // Chaining in JavaScript
* by Andrew Monks // https://monks.com/monads
*
* try it in your browser:
* https://tonicdev.com/amonks/578beb1fdb37ac12001d3826
Have you ever chained a bunch of functions together?
Math.log(Math.floor(Math.sqrt(Math.random())))
var context = new webkitAudioContext(),
audio = new Audio(),
source,
// `stream_url` you'd get from
// requesting http://api.soundcloud.com/tracks/6981096.json
url = 'https://api.soundcloud.com/tracks/6981096/stream' +
'?client_id=SOMETHING_SECRET';
audio.crossOrigin = "anonymous"; // via http://stackoverflow.com/questions/31308679/mediaelementaudiosource-outputs-zeros-due-to-cors-access-restrictions-local-mp3
audio.src = url;
source = context.createMediaElementSource(audio);

General Motors / Phil Morton

Andrew Monks


I love General Motors as, in jonCates' words, "a cyberpsychedelic remixological roadtrip across the American imagination". But is it successful as a critical stand against General Motors? I'd say yes, but a year ago I would not have. I'll divide the piece into two main sections: the first half, wherein Phil says things about General Motors, and the second half, wherein Phil does not. At first, I had trouble with the second half. It's easy to dismiss: I love it: I love image processing, and Colorful Colorado, and all the equipment, but it doesn't seem to directly relate to the piece's pro-consumer thesis.

But the more I think about copy-it-right, the more it makes sense. In a conversation at SAIC off The Phil Morton Video Archive, Gene Youngblood said, "One value of these tools is that after using them for a while, and using them on a large scale, we could come to conceive of a viable anarchic society. It could work."

# # # # # # # # # # # # # # # # # # # # # # # # # # #
#
# TRACK
#
# config for this particular track
#
# # # # # # # # # # # # # # # # # # # # # # # # # # #
bpm = 20 # this does change the bpm when reloading code
beat = 0 # this does not reset the beat to 0 when reloading code