This file contains 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
require 'rack' | |
require 'action_dispatch' | |
class Controller | |
def self.action(name) | |
-> (env) do | |
new(env).send(name) | |
end | |
end |
This file contains 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
defmodule Chop do | |
def guess(actual, range) do | |
midpoint(range) | |
|> print_guess | |
|> do_guess(actual, range) | |
end | |
defp do_guess(guess, actual, _) when guess == actual do | |
IO.puts guess | |
end |
This file contains 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 fish_prompt | |
set_color green | |
echo -n (pwd | sed "s!^$HOME!~!") | |
set_color cyan | |
if test -d .git | |
echo -n '' (git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e "s/* \(.*\)/[\1]/") | |
if [ (git status 2> /dev/null | tail -n1) != 'nothing to commit, working directory clean' ] |
This file contains 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
module SimplestAuth | |
module Model | |
def self.included(base) | |
adapters.each do |adapter| | |
if adapter.registered?(base) | |
include adapter | |
end | |
end | |
end |
This file contains 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
ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAtrRGakN2WRoXUIHhIVTg2d87EselCvRfI/Not+eE3gAQRm9m1v7hWGM6gDUTNnUGmda5+rHZgbxvrLwLTxNj3HmJNwQ63iiij6FdWk3f7mK8mBqnz7oPjwEF8HO/R1eJPenSe/C4KLyRVUHmmfbDDsJ6EALoy6+t4/VJFbi3NjnxftfxWIoiFw9R4FkmsDamuPue3wzA+qexhWhEEXDzOlLy6O+Nt47lfnWSRZPOKLc+kMljfq1NA2+ct+hnqVurSqpm332M27QdLucPmG/Jzo1EO/Pyp3it9KJAJ/qn9QcfiODL2rUnk9ZQTnm9ctEhdrTPeCyqBIJ+idYMt3LsKw== Chris@Callisto.local |
This file contains 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
#!bash | |
# | |
# bash completion support for core Git. | |
# | |
# Copyright (C) 2006,2007 Shawn O. Pearce <spearce@spearce.org> | |
# Conceptually based on gitcompletion (http://gitweb.hawaga.org.uk/). | |
# Distributed under the GNU General Public License, version 2.0. | |
# | |
# The contained completion routines provide support for completing: | |
# |
This file contains 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
-- TLC - The Tiny Lua Cocoa bridge | |
-- Note: Only tested with LuaJit 2 Beta 9 on x86_64 with OS X >=10.7.3 & iPhone 4 with iOS 5 | |
-- Copyright (c) 2012, Fjölnir Ásgeirsson | |
-- Permission to use, copy, modify, and/or distribute this software for any | |
-- purpose with or without fee is hereby granted, provided that the above | |
-- copyright notice and this permission notice appear in all copies. | |
-- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES |
This file contains 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
ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAtrRGakN2WRoXUIHhIVTg2d87EselCvRfI/Not+eE3gAQRm9m1v7hWGM6gDUTNnUGmda5+rHZgbxvrLwLTxNj3HmJNwQ63iiij6FdWk3f7mK8mBqnz7oPjwEF8HO/R1eJPenSe/C4KLyRVUHmmfbDDsJ6EALoy6+t4/VJFbi3NjnxftfxWIoiFw9R4FkmsDamuPue3wzA+qexhWhEEXDzOlLy6O+Nt47lfnWSRZPOKLc+kMljfq1NA2+ct+hnqVurSqpm332M27QdLucPmG/Jzo1EO/Pyp3it9KJAJ/qn9QcfiODL2rUnk9ZQTnm9ctEhdrTPeCyqBIJ+idYMt3LsKw== Chris@Callisto.local |
This file contains 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
#! /bin/sh | |
### BEGIN INIT INFO | |
# Provides: php-fastcgi | |
# Required-Start: $all | |
# Required-Stop: $all | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Start and stop php-cgi in external FASTCGI mode | |
# Description: Start and stop php-cgi in external FASTCGI mode | |
### END INIT INFO |
NewerOlder