/geek

Month

March 2012

84 posts

Positivity Link #3: Kansas - Carry on my Wayward Son! Just lay that weary head to rest. Don't you cry no more → open.spotify.com
Mar 19, 20124 notes
#carry on my wayward son #don't you cry no more #kansas #not the state #oooo organ! #positivity
NEEDS MOAR COWBELL! Blue Oyster Cult - (Don't Fear) The Reaper → open.spotify.com
Mar 19, 20124 notes
#don't fear the reaper #moar cowbell #positivity
Positive Thinking Song #2: Journey - Don't Stop Believing. It's going out to you Dallas! → open.spotify.com
Mar 19, 20123 notes
#don't stop believin #going anywhere #journey #just a small town boy #take that midnight train #positivity
Dallas told me I'm only allowed to talk about Rainbows for the rest of the day. I've reached my negativity quota! → open.spotify.com
Mar 19, 20124 notes
#dio #negativity quotas #rainbows #positivity
PS1 Start-up Audio (Remastered)

Nostalgia Attack!!

Mar 18, 201215 notes
#nostalgia #ps1 #startup
Mar 18, 20121,006 notes
Mar 17, 20123,492 notes
Listen
Mar 17, 20126 notes
Mar 15, 2012102 notes
I love coding with Jamba!
  • Brian: i'm on the phone with this one guy, he's using joomla, he keeps referring to it as jamba
  • Brian: now i want a fruit smoothie
Mar 14, 20121 note
#fruit smoothies #chats with brian
Mar 14, 201218 notes
I want to use Clojure....
  • Evan: well, also because clojure will make you incurably insane.
  • Me: functionally insane thank you very much. little to no side-effects
  • Evan: hahaha. I prefer "immutably insane" then.
Mar 13, 20125 notes
#functional programming #programing jokes #clojure #insanity
Mar 12, 20125 notes
#william shatner #seeking major tom
Mar 12, 2012159 notes
How John Interviews?
  • Me: Why is everyone scared to talk to me?
  • Dallas: I don't know. I just imagine that when you're in an interview you start screaming: BUBBLE SORT NOW!!!!!
  • Me: ....
Mar 12, 20128 notes
#BUBBLE SORT NOW #Interviews
Creating a band
  • Me: let's create a non-mainstream band, sell out, make millions and still wear tight jeans
  • Brian: yes, let's analyze the BPM of the top 40 songs over the last 6 months, analyze the key they were written in, do some lexical analysis on lyrics and start with a strong foundation.
  • Brian: music; like an engineer
  • Me: Let's call ourselves "Lexical Robot"
  • Brian: DONE!
Mar 12, 20125 notes
#lexical robot #coming to a bar near you
Mar 12, 201247 notes
Hardware Hacks....
  • Me: I think I'm going to start doing hardware hacks
  • Me: SOFTWARE BORES ME NOW
  • Brian: YOU MUST GO DEEPER
  • Me: TWIDDLE MY BITS
Mar 12, 20124 notes
#twiddle my bits #hardware hacks
I just cooked and ate 2 week old bacon...

And I want my last words to be if I die from it…”it was delicious”

Mar 11, 20128 notes
#mmm bacon #im gonna die
Mar 11, 2012725 notes
Play
Mar 10, 20129 notes
#zelda #floppy drives
All I can say is this....

Fuck you, Dark Souls.

Mar 10, 20126 notes
#rage break #dark souls #AAAAAAARRHRHHGHGGHHHGGGHGHGHGHGHGH
Mar 9, 201215 notes
Mar 9, 201231,224 notes
Mar 8, 20128,126 notes
Mar 8, 2012114 notes
Mar 8, 201236 notes
#ALL GLORY TO THE HYPNOTOAD
Mar 8, 20123,211 notes
Mar 8, 2012191 notes
#tyrion #wolverine #tyriolverine
Mar 7, 20122,115 notes
#want
Mar 7, 201211 notes
#ipad #confirmation
Mar 7, 20121,690 notes

(┛◉Д◉)┛彡┻━┻

Mar 6, 20123 notes
#rage!
Git-Fu 2

Recently, I needed to do some repository splitting using git. Originally, I figured this would be a long and laborious process that I would curse for years to come. So let me start this off with this: It wasn’t that bad.

I googled quite a bit and found this fantastic StackOverflow post about it. I needed to do something a little different than what was done here so I’ll walk you guys through the whole process.

So let’s say you have a git repository laid out as follows:

 proj1/
    best_app_ever.php
    tests/
    old_project/
    ABC/
    ABC.php

Let’s say you want to move the directory ABC and ABC.php from the project above because proj1 has just become too big and place it into a new project called proj2.

Step 1: Clone your repository as proj2

git clone proj1 proj2

Optional: Remove your origin. I do this just so I don’t accidentally remove anything from the origin.

git remote rm origin

Step 2: Filter the history out you don’t want.

git filter-branch --index-filter "git rm -rf best_app_ever.php tests old_project" --prune-empty -- --all

Here is where I start to diverge from the StackOverflow post, I don’t want to just extract out ABC, I want ABC.php as well. Using —subdirectory-filter just won’t cut it here. We use index-filter to rewrite the index and run the command git remove command on the files I don’t want. The prune-empty flag will trim the commits that are empty that occurred while executing your filter. It’s important to note that —all will rewrite all branches and tags.

Step 3: Reset the index and working tree

git reset --hard

Step 4: Clean up all your refs

git for-each-ref --format="%(refname)" refs/original/ | xargs -n 1 git update-ref -d

This goes through all the refs and deletes them if they contain an old value.

Step 5: Expire all the old reflog entries

git reflog expire --expire=now --all

Step 6: Clean up and optimize, pruning anything older than now.

git gc --aggressive --prune=now

The above steps should create two different repositories with all history preserved!

proj1/
    best_app_ever.php
    tests/
    old_project/

proj2/
     ABC/
     ABC.php

Hope this helps you the next time you need to split up a repository!

Mar 6, 20126 notes
#git #git-fu #repository magic
Mar 5, 2012623 notes
Mar 3, 201234 notes
Mar 3, 20122 notes
#lord helmet #how the hell did his hair do that??
Git-Fu

Recently, I wanted to see what files in a commit changed over here at Tumblr so that we could do some syntax checking.

So I needed to basically see all the files that changed on a merge commit that happened with 2 parents. The following command pulls out all the php files from that merge commit.

git show --pretty="format:" --name-only parent1...parent2 | grep .php | sort | uniq

With this one liner, I have a list of all the different files that changed in the commit, ready to be lint checked. Neat, huh? Git is awesome.

Mar 2, 201228 notes
#git #fun
Mar 2, 20122,259 notes
Mar 2, 20128,630 notes
Mar 2, 2012281 notes
Comparing PHP, Perl, Python and Ruby → hyperpolyglot.org
Mar 1, 201265 notes

February 2012

45 posts

(╯°□°)╯︵ ┻━┻

Feb 29, 201210 notes
#table #throw
Feb 28, 2012264 notes
Feb 28, 2012525 notes
Feb 28, 20121,015 notes
Feb 28, 20125,222 notes
Feb 27, 20122,398 notes
Feb 27, 201212,929 notes
Rhizome Recommends: Art and Technology SXSW Panels → rhizome.org
Feb 26, 201213 notes
Next page →
2012 2013
  • January 48
  • February 34
  • March 53
  • April 19
  • May 32
  • June 44
  • July
  • August
  • September
  • October
  • November
  • December
2011 2012 2013
  • January 57
  • February 45
  • March 84
  • April 72
  • May 49
  • June 59
  • July 83
  • August 72
  • September 73
  • October 63
  • November 30
  • December 24
2011 2012
  • January
  • February
  • March
  • April 3
  • May 39
  • June 46
  • July 68
  • August 92
  • September 55
  • October 73
  • November 75
  • December 45