CouchDB is a NoSQL database for storing JSON documents. It comes with a REST API out of the box so your client applications can persist data while requiring you to write little or no server-side code. CouchDB's killer feature is its ability to easily replicate, which allows for horizontal scaling, easy backup, and for client adapters to synchronize documents. This is perfect if you want to write an application that is offline-first. It's become my go-to database when creating new
## Unity ## | |
*.cs diff=csharp text | |
*.cginc text | |
*.shader text | |
*.mat merge=unityyamlmerge eol=lf | |
*.anim merge=unityyamlmerge eol=lf | |
*.unity merge=unityyamlmerge eol=lf | |
*.prefab merge=unityyamlmerge eol=lf |
<html> | |
<head> | |
<script src="clmtrackr.js"></script> | |
<script src="model_pca_20_svm.js"></script> | |
<script src="p5.js"></script> | |
<script src="p5.dom.js"></script> | |
<script> | |
var ctracker; |
[Sparkfiles][1] are [great][2].
- Create a new Shell Script Extension.
- Give it the Keyword "spark".
- Click the "Advanced" button above the "Command" textarea and deselect "Spaces" under "Escaping".
- Close the Advanced dialog and paste this script into the "Command" textarea.
jQuery(function($) { | |
$('form[data-async]').live('submit', function(event) { | |
var $form = $(this); | |
var $target = $($form.attr('data-target')); | |
$.ajax({ | |
type: $form.attr('method'), | |
url: $form.attr('action'), | |
data: $form.serialize(), |
Dad and I got to talk about programming for two weeks before he died.
I was 22, a senior in college completing a BFA in graphic design. Dad was 62, an older dad than most. When he started programming at Tennessee Tech back in the 60s, he wrote FORTRAN on punch cards. He was a wealth of knowledge.
I had just been introduced to code that semester, and it was already consuming my thoughts. It felt magical and powerful, in many ways a more fulfilling creative practice than visual design (but that's for another post).
When I came home for the holidays, Dad shared The Ten Commandments of Egoless Programming with me. He printed them and we discussed each point. It was one of the few programming related things we were able to discuss before he unexpectedly passed; perhaps that's why it sticks with me.
Using Python's built-in defaultdict we can easily define a tree data structure:
def tree(): return defaultdict(tree)
That's it!
DEFAULT_FILE_STORAGE = 'storages.backends.s3boto.S3BotoStorage' | |
STATICFILES_STORAGE = 'path.to.storage.S3StaticStorage' | |
THUMBNAIL_DEFAULT_STORAGE = 'storages.backends.s3boto.S3BotoStorage' | |
AWS_ACCESS_KEY_ID = 'YOUR KEY' | |
AWS_SECRET_ACCESS_KEY = 'YOUR KEY' | |
AWS_STORAGE_BUCKET_NAME = 'media.YOURSITE.com' | |
AWS_STATIC_BUCKET_NAME = 'static.YOURSITE.com' | |
AWS_S3_CUSTOM_DOMAIN = AWS_STORAGE_BUCKET_NAME | |
AWS_STATIC_CUSTOM_DOMAIN = AWS_STATIC_BUCKET_NAME | |
STATIC_URL = 'http://%s/' % AWS_STATIC_BUCKET_NAME |
56k: "https://123.campfirenow.com/images/56k.gif" | |
bell: ":bell:" | |
bezos: ":laughing::thought_balloon:" | |
bueller: "anyone?" | |
butts: ":open_hands: :smoking:" | |
clowntown: "https://123.campfirenow.com/images/clowntown.gif" | |
cottoneyejoe: ":notes::hear_no_evil::notes:" | |
crickets: "hears crickets chirping" | |
dadgummit: "dad gummit!! :fishing_pole_and_fish:" | |
dangerzone: "https://123.campfirenow.com/images/dangerzone.png" |
function get_avatar_from_service(service, userid, size) { | |
// this return the url that redirects to the according user image/avatar/profile picture | |
// implemented services: google profiles, facebook, gravatar, twitter, tumblr, default fallback | |
// for google use get_avatar_from_service('google', profile-name or user-id , size-in-px ) | |
// for facebook use get_avatar_from_service('facebook', vanity url or user-id , size-in-px or size-as-word ) | |
// for gravatar use get_avatar_from_service('gravatar', md5 hash email@adress, size-in-px ) | |
// for twitter use get_avatar_from_service('twitter', username, size-in-px or size-as-word ) | |
// for tumblr use get_avatar_from_service('tumblr', blog-url, size-in-px ) | |
// everything else will go to the fallback | |
// google and gravatar scale the avatar to any site, others will guided to the next best version |