Skip to content

Instantly share code, notes, and snippets.

View zph's full-sized avatar

Zander Hill zph

View GitHub Profile
#!/usr/bin/env ruby
#
#
require 'json'
require 'open-uri'
require 'pry'
nonstandard_url = "http://xkcd.com/info.0.json"
# start_url = "http://xkcd.com/1/info.0.json"
# end_url = "http://xkcd.com/1243/info.0.json"
#!/usr/bin/env ruby
#
require 'json'
require 'CSV'
require 'open-uri'
json_files = Dir.glob("*.json")
content = json_files.map do |file|
#!/usr/bin/env ruby
#
require 'json'
require 'CSV'
require 'open-uri'
json_files = Dir.glob("*.json")
content = json_files.map do |file|
{"month":"7","num":1244,"link":"","year":"2013","news":"","safe_title":"Six Words","transcript":"","alt":"Ahem. We are STRICTLY an Orbiter shop.","img":"http://imgs.xkcd.com/comics/six_words.png","title":"Six Words","day":"29","url":"http://xkcd.com/info.0.json"}
@zph
zph / ctags.md
Last active December 20, 2015 11:19 — forked from wikimatze/ctags.md

Working effectively with ctags has been a topic I avoided for a long time because I was too lazy to invest the time to learn about it.

I was working on my application and needed to constantly consult Padrino's API docs in the browser. It would have been more effective if I could do the searching directly in Padrino's code on GitHub. Even better would be if I didn't have to leave the terminal and could stay in the flow of coding. It's possible with ctags!

What is ctags

ctags is a tool which make it easy for you to shift rapidly through code.

#!/bin/sh
#
# This shell script passes all its arguments to the binary inside the
# MacVim.app application bundle. If you make links to this script as view,
# gvim, etc., then it will peek at the name used to call it and set options
# appropriately.
#
# Based on a script by Wout Mertens and suggestions from Laurent Bihanic. This
# version is the fault of Benji Fisher, 16 May 2005 (with modifications by Nico
# Weber and Bjorn Winckler, Aug 13 2007).
#!/bin/sh
SPACE="SERVER$(spacefinder | sed 's/Current Space ID: //')"
mvim --serverlist | grep $SPACE
if [ $? -eq 1 ]
then
mvim --servername $SPACE $*
else
mvim --servername $SPACE --remote $*
fi
nnoremap <leader>e :!iex %<CR>
fizzbuzz = fn
{0, 0, _} -> "FizzBuzz"
{0, _, _} -> "Fizz"
{_, 0, _} -> "Buzz"
{_,_, third} -> "#{third}"
end

Bearded's Hourly Contract

Date: [[Date of Document]] Between [Our Company] and [Your Company]

Summary

We’re not big on formality, but sometimes it’s best to have a few simple things written down so that we’re all on the same page. In this contract you won’t find complicated legal terms or large passages of unreadable text. We have no desire to trick you into signing something that you might later regret. We do want what’s best for the safety of both parties, now and in the future.