This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| blah |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* I prefer a more compact tree-view */ | |
| .tree-view { | |
| font-size: 11px; | |
| .list-item { | |
| line-height: 18px !important; | |
| } | |
| .selected:before, .selected:before { | |
| height: 18px !important; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### Keybase proof | |
| I hereby claim: | |
| * I am sd on github. | |
| * I am sd (https://keybase.io/sd) on keybase. | |
| * I have a public key whose fingerprint is F3FE 16B8 BD80 AEDE 0D2D 3B4F 5A59 C316 8373 5F6C | |
| To claim this, I am signing this object: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Verifying that +sd is my openname (Bitcoin username). https://onename.io/sd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #============================================================================== | |
| # It's nice to have an easy way to iterate over model objects without having | |
| # to load them all in memory at once. | |
| class ActiveRecord::Base | |
| def self.chunky_find(args = {}, &block) | |
| reporter = args.delete(:reporter) | |
| reporter = nil unless reporter and reporter.respond_to? :call | |
| sleep_duration = args[:sleep] | |
| args.delete(:sleep) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if [ "$SSH_TTY" ]; then | |
| # If this is a remote session, then start screen | |
| if [ "$TERM" != "screen" ]; then | |
| screen -xRRU | |
| if [ "$?" = "0" ]; then | |
| reset | |
| exit | |
| fi | |
| fi | |
| fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| EARTH_RADIUS = { | |
| :miles => 3_963.189, | |
| :km => 6_378.135 | |
| } | |
| units_per_lat = 2.0 * Math::PI * EARTH_RADIUS[units] / 360.0 | |
| units_per_lon = units_per_lat * Math.cos(Math::PI * longitude.to_f / 360.0).abs | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class SEShake < Poundie::Plugin | |
| register :se_shake | |
| match do |message| | |
| message.body =~ /(^\!shake|shakeshack|shake shack)/i and message.body !~ /camera\.jpg/ | |
| end | |
| action do |message| | |
| speak "http://www.shakeshack.com/camera.jpg" | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Make Hubot talk shit. | |
| module.exports = (robot) -> | |
| robot.hear /(fuck you|fuck off|shut up)/i, (msg) -> | |
| incoming_msg = msg.message | |
| if incoming_msg.text.match ///#{robot.name}///i | |
| diss = msg.match[1] | |
| if diss != "fuck you" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function bundle_exec { | |
| if [[ -a Gemfile ]]; then | |
| bundle exec $* | |
| else | |
| $* | |
| fi | |
| } | |
| alias rake="bundle_exec rake" | |
| alias cap="bundle_exec cap" |
OlderNewer