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
// COLOR ****************************************************/ | |
$bordercolor: #888; | |
$activecolor: #D61518; | |
$aqua:#00FFFF; | |
$bisque:#ffe4c4; | |
$black:#000000; | |
$blue:#0000FF; | |
$brown:#A52A2A; | |
$cyan:#00FFFF; |
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
[ui] | |
username = kuruma | |
[extensions] | |
hgext.graphlog = | |
hgext.fetch = | |
progress = | |
transplant = | |
pager = | |
color = |
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 EnumInput < Formtastic::Inputs::SelectInput | |
def collection | |
enum = @object.enums(@method.to_sym) | |
choices = enum ? enum.select_options : [] | |
end | |
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
class A | |
def a | |
"super" | |
end | |
end | |
module B | |
def a | |
"module" | |
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
a = {a:1,b:2} | |
b = {b:3,c:4} | |
$.extend(a, b) | |
a #=> {a: 1, b: 3, c: 4} | |
a = {a:1,b:2} | |
b = {b:3,c:4} | |
_.extend(a, b) | |
a #=> {a: 1, b: 3, c: 4} |
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
<div id="fb-root"></div> | |
<script>(function(d, s, id) { | |
var js, fjs = d.getElementsByTagName(s)[0]; | |
if (d.getElementById(id)) {return;} | |
js = d.createElement(s); js.id = id; | |
js.src = "//connect.facebook.net/ja_JP/all.js#xfbml=1&appId=111570108909859"; | |
fjs.parentNode.insertBefore(js, fjs); | |
}(document, 'script', 'facebook-jssdk'));</script> |
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
@techs.empty? | |
# Output "I love Ruby" | |
say = "I love Ruby" | |
puts say | |
# Output "I *LOVE* RUBY" | |
say['love'] = "*love*" | |
puts say.upcase | |
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
require 'shell' | |
class VERSION | |
sh = Shell.cd(Rails.root) | |
@@i=sh.system('hg','identify','-i').to_s.gsub("\n","") | |
@@n=sh.system('hg','identify','-n').to_s.gsub("\n","") | |
@@b=sh.system('hg','identify','-b').to_s.gsub("\n","") | |
cattr_reader :i,:n,:b | |
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
$RAILS = {scheme: 'http', host: 'localhost', port: '3000' } | |
def $RAILS.scheme; $RAILS[:scheme]; end | |
def $RAILS.host; $RAILS[:host]; end | |
def $RAILS.port; $RAILS[:port]; end | |
def $RAILS.authority; "#{$RAILS.host}:#{$RAILS.port}"; end | |
def $RAILS.uri_root; "#{$RAILS.scheme}://#{$RAILS.host}:#{$RAILS.port}"; 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
# -*- encoding: utf-8 -*- | |
lib = File.expand_path('../lib/', __FILE__) | |
$:.unshift lib unless $:.include?(lib) | |
require "current/version" | |
Gem::Specification.new do |s| | |
s.name = "current" | |
s.version = Current::VERSION | |
s.platform = Gem::Platform::RUBY |
NewerOlder