Skip to content

Instantly share code, notes, and snippets.

@hito-asa
hito-asa / gtk-firefox
Last active December 20, 2015 16:29 — forked from alingogo/gtk-firefox
#!/bin/bash
# GTK+ and Firefox for Amazon Linux
# Written by Joseph Lawson 2012-06-03
# http://joekiller.com
# http://joekiller.com/2012/06/03/install-firefox-on-amazon-linux-x86_64-compiling-gtk/
# chmod 755 ./gtk-firefox.sh
# sudo ./gtk-firefox.sh

news-ci01# GitHub Flow

31 Aug 2011

git-flowの問題点 (Issues with git-flow)

私は人々にGitを教えるためにあちこちを飛び回っているが、最近のほぼすべてのクラスやワークショップで git-flow についてどう思うかを尋ねられた。私はいつも、git-flowは素晴らしいと思うと答えている。何百万ものワークフローを持ったシステム(Git)を提供し、ドキュメントもあるし、よくテストされている。フレキシブルなワークフローは、実に容易なやり方で多くの開発者の役に立つ。標準的なものになりつつあり、開発者はプロジェクトや企業の間を移動しつつこの標準的なワークフローに馴染むことができる。

@hito-asa
hito-asa / gist:5290947
Last active December 15, 2015 16:39 — forked from nakaearth/gist:5097524
class Stamp < ActiveRecord::Base
Paperclip.interpolates :img_dir_num do |attachment, style|
(attachment.instance.id * 0.01).to_i
end
Paperclip.interpolates :filename do |attachment, style|
attachment.instance.id.to_s + ".png"
end
if Rails.env.production?
S3_CREDENTIALS = {access_key_id: ENV['S3_ACCESS_KEY_ID'], secret_access_key: ENV['S3_SECRET_KEY'], bucket: "hoge-bucket"}
end
@hito-asa
hito-asa / Stamp.rb
Last active December 15, 2015 16:39 — forked from nakaearth/Stamp.rb
class Stamp < ActiveRecord::Base
####途中省略####
if Rails.env.production?
S3_CREDENTIALS = {access_key_id: ENV['S3_ACCESS_KEY_ID'], secret_access_key: ENV['S3_SECRET_KEY'], bucket: "hoge-bucket"}
end
if Rails.env.production?
has_attached_file :stamp, storage: :s3, s3_credentials: S3_CREDENTIALS,
styles: {stamps_s: "100x100&gt;", stamps: "350x350&gt;"}, url: ":s3_domain_url", path: "stamps/:style/:filename"
else
has_attached_file :stamp, url: "/:style/:img_dir_num/:filename", styles: {stamps_s: "100x100&gt;", stamps: "350x350&gt;"}
@hito-asa
hito-asa / access.yml
Last active December 15, 2015 16:39 — forked from nakaearth/access.yml
localhost: &localnet
/admin/user:
- [ip address]
development:
<<: *localnet
test:
<<: *localnet
production:
/admin/point:
- [ip address]
@hito-asa
hito-asa / gist:5290892
Last active December 15, 2015 16:39 — forked from nakaearth/gist:5192827
private
def update_params
params.require(:hoge).permit(:title, :description, :priority, :status)
end