Skip to content

Instantly share code, notes, and snippets.

View airhadoken's full-sized avatar

Bradley Momberger airhadoken

View GitHub Profile

Making an Art Bot, a walkthrough

I had a great idea, to make a bot that could recreate abstract art in the style of several artists.

Of course this is too big a scope so I started with one that's comparatively easy to replicate in code: Mondrian.

Prelim 0: Drawing on a canvas:

@airhadoken
airhadoken / twittercard.js
Last active February 4, 2022 18:41
Making twitter cards and also getting data back from them later, in NodeJS.
var T = require("twit");
var Q = require("q");
// key and secret for Twitter for iPhone.
// A whitelisted app is needed to access the cards API; you can't just create your own currently.
var TWITTER_CONSUMER_KEY = "IQKbtAYlXLripLGPWd0HUA";
var TWITTER_CONSUMER_SECRET = "GgDYlkSvaPxGxC4X8liwpUoqKwwr3lCADbz8A7ADU";
// These you will have to fill in yourself by authorizing Twitter for iPhone for your account.
// How to get the access tokens through OOB authorization is outside the scope of this snippet.
var TWITTER_ACCESS_TOKEN = "";
040e0ee6d4b351bf7f3c89b0e93176ecede8db7eb4caeba29ec2fc9d3b4a80490b960b658365829ad307a5e477cfdaeddfc3fa2a1342b2fcee58fc2d1609a6b8ec
@airhadoken
airhadoken / Cobalt (SL).tmTheme
Created March 7, 2018 21:28
Sublime Text Cobalt color theme with fixes for highlighting in the latest SublimeLinter
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>comment</key>
<string>Created by Jacob Rus. Based on ‘Slate’ by Wilson Miner</string>
<key>author</key>
<string>Jacob Rus</string>
<key>name</key>
<string>Cobalt</string>
<html>
<head>
<title>Terms of Service for Twitter App</title>
</head>
<body>
<h1>Definitions</h1>
<p>This document covers the Terms of Service for the Twitter API app called "twitter_joints" which is owned and managed by
Bradley Momberger whose Twitter handle is @air_hadoken and who manages and maintains the list of Twitter bots at
https://twitter.com/air_hadoken/lists/twitter-joints . All further uses of "Bradley Momberger" in this document refer
to this person and this person only.</p>
<html>
<head>
<title>Twitter app privacy policy</title>
</head>
<body>
<h1>Privacy policy for Twitter API app "twitter_joints"</h1>
<p>The following terms cover the handling of user data</p>
<ul>
<li>The primary function of the twitter_joints Twitter API app, hereafter known as "this app", is to publish content
in an automated manner using varied source corpora including, but not limited to, content already hosted on Twitter,