Skip to content

Instantly share code, notes, and snippets.

View tylerpearson's full-sized avatar

Tyler Pearson tylerpearson

View GitHub Profile
@tylerpearson
tylerpearson / nyt.txt
Last active August 29, 2015 14:12
most common words in the Twitter bios of New York Times staff (downcased, with most punctuation stripped and stop words removed)
new: 514
times: 497
york: 483
editor: 264
reporter: 138
@nytimes: 101
author: 83
correspondent: 71
bureau: 60
nyt: 60
@tylerpearson
tylerpearson / twitter_bio_word_analyzer.rb
Last active August 29, 2015 14:12
A Ruby script to find the most commonly used words in the bios of accounts a user follows on Twitter
require 'twitter'
# change this to your own info to get the script to work
# get it from https://apps.twitter.com/
client = Twitter::REST::Client.new do |config|
config.consumer_key = "XXX"
config.consumer_secret = "XXX"
config.access_token = "XXX"
config.access_token_secret = "XXX"
@tylerpearson
tylerpearson / results.txt
Last active August 29, 2015 14:12
most common words in the bios of the people I follow on Twitter (downcased, with most punctuation stripped and stop words removed)
director: 66
news: 61
web: 54
digital: 53
politics: 52
twitter: 50
design: 49
founder: 44
tweets: 43
former: 43
@tylerpearson
tylerpearson / results.txt
Created January 4, 2015 00:41
most common words in my Twitter followers' bios (with punctuation stripped and stop words skipped)
i: 135
west: 89
virginia: 74
media: 55
marketing: 51
wv: 49
social: 46
news: 38
political: 38
love: 37
@tylerpearson
tylerpearson / remove.md
Last active August 29, 2015 14:12
remove conflicted dropbox files

find . -type f -name "* conflicted *" -exec rm -f {} \;

@tylerpearson
tylerpearson / copy_github_labels.rb
Last active January 11, 2022 15:27
Super simple script to copy Github tag labels from one repository to another. Uses the Octokit gem.
require 'octokit'
# https://help.github.com/articles/creating-an-access-token-for-command-line-use/
client = Octokit::Client.new(:access_token => "getmefromgithub")
COPY_FROM_REPO = "repo/old"
COPY_TO_REPO = "repo/new"
current_labels = client.labels(COPY_FROM_REPO)
@tylerpearson
tylerpearson / array.rb
Created October 6, 2014 01:46
PayPal blocked 2 letter country codes
['AF', 'AQ', 'CI', 'CU', 'BY', 'BV', 'IO', 'CM', 'CF', 'CX', 'HT', 'HM', 'IR', 'IQ', 'KR', 'LA', 'LB', 'LR', 'LY', 'MM', 'NG', 'PK', 'PG', 'RS', 'SD', 'SY', 'ZW', 'VN', 'BD']
@tylerpearson
tylerpearson / passenger_nginx_env_vars.md
Last active August 29, 2015 14:07
setting env vars with passenger and nginx
http {
    ...
    passenger_ruby /path/to/passenger_ruby

=============

chmod +x /path/to/passenger_ruby

/*
* FB SETTINGS
*/
window.fbAsyncInit = function() {
// 1. Get a unique appId for the website from https://developers.facebook.com/apps
// The title will be visible in the post, so make it the name of the site (e.g. Taco Truck for Congress)
// 2. In "Settings", click "+ Add Platform", select "Website", and add the site URL (localhost is cool initially too)
// 3. In "App Details", things like the icon can be customized

Keybase proof

I hereby claim:

  • I am tylerpearson on github.
  • I am tylerpearson (https://keybase.io/tylerpearson) on keybase.
  • I have a public key whose fingerprint is CE07 404E C0F8 0BE1 A2C2 D933 C68C B0FE 23FD D51B

To claim this, I am signing this object: