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
Gem::Specification.new do |spec| | |
spec.name = "nfu" | |
spec.version = "0.0.1" | |
spec.authors = ["uchiko"] | |
spec.email = ["memememomo"] | |
spec.summary = "return nfu" | |
spec.files = ["nfu.rb"] | |
spec.require_path = "." | |
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 UserForm | |
include ActiveModel::Model | |
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
describe 'FizzBuzz' do | |
describe '#run' do | |
context '3の倍数' do | |
example 'Fizzという文字列を返すこと' do | |
expect(FizzBuzz.run(3)).to eq('Fizz') | |
expect(FizzBuzz.run(6)).to eq('Fizz') | |
expect(FizzBuzz.run(9)).to eq('Fizz') | |
expect(FizzBuzz.run(12)).to eq('Fizz') | |
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
FROM centos:centos6 | |
... |
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
[1] pry(main)> show-source Class.class_name | |
From: /Users/uchiko/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/yard-0.8.7.6/lib/yard/core_ext/module.rb @ line 7: | |
Owner: Module | |
Visibility: public | |
Number of lines: 3 | |
def class_name | |
name.split("::").last | |
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 Test | |
def self.hoge | |
puts 'hoge' | |
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
group :development, :test do | |
... | |
gem 'rails-erd', github: 'ready4god2513/rails-erd', branch: 'rails-4.2-support-fix' | |
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
#!/bin/bash | |
SRC=$(go list -f '{{range .GoFiles}}{{.}} {{end}}') | |
TESTS=$(go list -f '{{range .TestGoFiles}}{{.}} {{end}}') | |
if [ $# -gt 0 ]; then | |
TESTS=$1 | |
fi | |
go test $SRC $TESTS |
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
package main | |
import ( | |
"github.com/mitchellh/cli" | |
"log" | |
"os" | |
) | |
/** foo サブコマンド用の実装 **/ | |
type Foo struct{} |
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
package echoserver | |
import ( | |
"bufio" | |
"fmt" | |
"net" | |
"strconv" | |
) | |
type Server struct { |