Skip to content

Instantly share code, notes, and snippets.

View rkulla's full-sized avatar

Ryan Kulla rkulla

  • Southern California
View GitHub Profile
@rkulla
rkulla / my-life-list.md
Last active May 2, 2023 02:58
My Life List

Ryan Kulla's Birding Life List

Pinterest Version with photos I took

By Number -> Species -> Date First Identified -> Location First identified

  1. Northern Mockingbird - 02/22/2006 - San Bernardino, CA
  2. American Crow - 02/22/2006 - San Bernardino, CA
  3. House Sparrow - 02/27/2006 - San Bernardino, CA
  4. European Starling - 03/06/2006 - San Bernardino, CA
@rkulla
rkulla / quickscan.pl
Last active December 29, 2022 05:39
Simple Perl-based Port Scanner
#!/usr/bin/perl
# Easy port scanner
# I wrote this in the 90s to help learn socket programming
# ./quickscan -h for usage
use Socket;
$| = 1; # so \r works right
my ($ip, $protocol, $port, $myhouse, $yourhouse, $log);
@rkulla
rkulla / co
Last active December 3, 2021 11:12
Bash script for easier SVN checkouts
#!/bin/bash
# Author Ryan Kulla (rkulla@gmail.com)
#
# A shell script (in Bash) that allows you to do SVN checkouts
# with a shorter command than the default subversion command.
# Handy if your repos have long, hard to remember URLs.
#
# Put this script in your PATH (e.g., ~/bin/)
# Make sure it's executable:
# $ chmod u+x ~/bin/co

Keybase proof

I hereby claim:

  • I am rkulla on github.
  • I am rkulla (https://keybase.io/rkulla) on keybase.
  • I have a public key ASBDV2m5F9zjHg4tmy96M-U2wGZweobV9UVwTJlMJ89OrQo

To claim this, I am signing this object:

@rkulla
rkulla / vsrcrb.rb
Last active September 10, 2016 04:52
Easily find and view Ruby standard library source code
#!/usr/bin/env ruby
# vsrcrb.rb by Ryan Kulla (http://rkulla.com).
# Note that it only works on a *nix OS (OSX, Linux, etc). Not Windows.
# Command-line program to output standard library module source
# Install: $ mkdir ~/bin ; mv -i vsrcrb.rb ~/bin/vsrcrb ; chmod u+x ~/bin/vsrcrb
# Usage: $ vsrcrb <module-name-without-extension>
# Example: View socket.rb's source code: $ vsrcrb socket | less
# To view a gem's src: $ less $(gem which <gem>)
def get_source_paths(target_file)
@rkulla
rkulla / go
Last active August 23, 2016 04:16
go wrapper to "go run" implicitly when you type "go *.go"
#!/bin/bash
# Simple go wrapper for typing "go file.go" instead of "go run file.go"
# Allows flags and wildcards as usual.
#
# Installation: Copy this wrapper to first in PATH, e.g. $GOPATH/bin
realgo=/usr/local/go/bin/go
if (( $# > 0 )) && [[ "$1" = *.go ]]; then
$realgo run "$@"
else
@rkulla
rkulla / rails-3-tutorial-notes
Last active December 14, 2015 16:08
My Rails 3 Tutorial notes that I recommend people use.
My notes and shortcuts for working with Michael Hartl's great Rails tutorial
(http://ruby.railstutorial.org/)
- Since he has you install RVM in the very first chapter, I recommend actually using it
immediately rather than getting in the habit of typing out "bundle exec" all of the time
or forgetting to create and switch to gemsets. I recommend running this right away:
$ rvm use 1.9.3@sample_app --create
This way if you're reading other tutorials too, and want to experiment with gems they
@rkulla
rkulla / bq.py
Created November 7, 2015 17:47
BigQuery CLI query to json
#!/usr/bin/env python
# Query Big Query and return JSON results.
# Just a python example. There are better CLI tools than this:
# https://cloud.google.com/bigquery/bq-command-line-tool?hl=en
# usage: python bq.py
# For pretty output, pipe to 'prettyjson' or json.tool and/or pygmentize:
# bq.py | python -m json.tool | pygmentize -l javascript
from apiclient.discovery import build
from oauth2client.client import SignedJwtAssertionCredentials
@rkulla
rkulla / gwhich.c
Created August 4, 2011 06:39
GTK+ front-end wrapper around the UNIX which(1) command
/* gwhich.c -by Ryan Kulla
* GTK+ front-end wrapper around the which(1) command.
* Compile with: gcc gwhich.c -o gwhich `pkg-config --cflags --libs gtk+-2.0`
* Usage: gwhich
*/
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include <gtk/gtk.h>
@rkulla
rkulla / portell.py
Last active September 26, 2015 15:57
Look up a BSD system's Port package's description instantly
#!/usr/bin/env python
# portell.py -by Ryan Kulla
# I wrote this in ~2001 just for fun
# Description: Lookup a BSD (FreeBSD, et al) system's Port package's description instantly.
# Creates an index of existing Ports for easy and quick look up.
# Usage: portell.py <portname>
import sys, os, shelve
try: