Skip to content

Instantly share code, notes, and snippets.

View pdxmph's full-sized avatar

Mike Hall pdxmph

View GitHub Profile
@pdxmph
pdxmph / blogging_with_gists.md
Last active March 11, 2019 20:57
Mike's blogging gist

This idea is larger than a breadbox

So, I had this idea over the weekend that I wanted to share on Twitter. I realized it'd take more than 280 characters to get the idea across, so I loaded up the Twitter web page to take advantage of the ... what is it? The Tweet Storm feature? I don't know. I just know you click a '+' button and you can chain tweets instead of replying to yourself. It's nice! But also I hate it! I mean, you do you and if you want to make a thread, cool. I feel self-conscious about it. I'm not on Twitter a lot, so it's not my home base and I kinda feel like making a tweet thread is implying you have a certain claim to attention

@pdxmph
pdxmph / gists_with_mike.md
Last active March 10, 2019 07:19
Mike Goes for It With Org-Mode

In Which Mike Just Goes for It With org-mode

I am going to try blogging with gists.

This afternoon I went to a coffee shop and spent some time with other folks who're trying to Just Do Something. I've had an idea rattling around in my head for a while, but I haven't given myself space to try to grow it. I also realized a few weeks ago that I get really restless by the time the weekend comes. There's a lot of pent up mental energy, and it often gets lost in the first thing that catches my attention,

@pdxmph
pdxmph / apple_mail_org_mode_link.scpt
Created March 9, 2019 22:29
Make an org mode link from a mail message
@pdxmph
pdxmph / dirty_trello_analysis.rb
Created February 25, 2019 02:57
A very quick script to parse a Trello export and get out some basic information. Read inline documentation for assumptions and limitations.
#!/usr/bin/env ruby
require 'json'
require 'date'
require 'active_support'
require 'fileutils'
require 'pathname'
# Your trello dump should be in a directory with this script.
dir_file = File.read("puppet_trello/puppetlabs.json")
@pdxmph
pdxmph / adventures_in_ios_automation_middleman_blogging_edition.md
Created February 10, 2019 22:08
Notes about an Editorial/Working Copy blog publishing workflow

Adventures In iOS Automation: Middleman Blogging Edition

My Things site is built on Middleman, a static site generator that‘s pretty much the Jekyll modern people can love.

I‘ve tried static site generators a few times in the past, and the thing that‘s always stopped me from adopting them full-time for my regular blog (this one) is the overhead of maintaining something built around Git on a bunch of devices when most of my writing is spontaneous and squeezed in around the edges of other stuff. I was willing to do it with Things because it‘s a slower site, and the bulk of the content is developed over days or weeks.

When I got the iPad Pro I‘m typing this entry on, it made me start thinking about the things I‘d like to be able to do given a closer-to-real keyboard and enough screen real estate to keep my brain from freezing up when starting at everything through a 10" window. “Create and post content for a website managed by a static site generator

@pdxmph
pdxmph / hipchat_slack_room_massager.rb
Created December 20, 2018 01:21
Read a Google Spreadsheet and massage a HipChat export file to rename rooms and erase unwanted history
#!/usr/bin/env ruby
require "google_drive"
require "json"
# Change this to the POSIX path where your export lives
export_root = ""
# Read in our rooms file
rooms_file = File.read(export_root + "/rooms.json")
@pdxmph
pdxmph / hipchat_user_list.rb
Last active December 13, 2018 22:36
Make a tsv list of users and ids
#!/usr/bin/env ruby
require 'json'
# Change this to the POSIX path where your export lives
export_root = "/Users/mikehall/Sandbox/"
# sample record
# {
# "account_type"=>"user",
# "avatar"=>"line_noise",
@pdxmph
pdxmph / room_transcript.rb
Created December 13, 2018 18:49
HipChat Room Transcripts
#!/usr/bin/env ruby
# Use this to quickly spit out a transcript from a HipChat export.
#
# Command line syntax:
#
# ruby room_transcript.rb 123455
#
# (where 123455 is the id of the room)
@pdxmph
pdxmph / hipchat_room_list.rb
Created December 13, 2018 18:17
HipChat Room List
#!/usr/bin/env ruby
# Change this to the POSIX path where your export lives
export_root = "/path/to/your/export/"
require 'json'
# Read the pertinent stuff into Ruby hashes
rooms_file = File.read(export_root + "rooms.json")
#!/usr/bin/env ruby
require "rubygems"
require "appscript"
include Appscript
require "active_support"
require 'rss/1.0'
require 'rss/2.0'
require 'open-uri'