brew unlink imagemagick
cd /usr/local/Cellar
cd imagemagick
rm -rf [新しいバージョン]
brew versions imagemagick -> バージョン一覧見る
git checkout [戻したいバージョンを指定]
brew link imagemagick
gem install rmagick
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
@mixin line-bottom($op1: .2, $op2: .3){ | |
border-bottom: 1px solid rgba(0, 0, 0, $op1); | |
@include box-shadow(rgba(255, 255, 255, $op2)0 1px 0); | |
} | |
#main { | |
color: #666; | |
font-size: 0.3em; | |
@include line-bottom(.3, .1); | |
a { |
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
=line-bottom($op1: .2, $op2: .3) | |
border-bottom: 1px solid rgba(0, 0, 0, $op1) | |
+box-shadow(rgba(255, 255, 255, $op2)0 1px 0) | |
#main | |
color: #666 | |
font-size: 0.3em | |
+line-bottom(.3, .1) | |
a | |
font: |
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
#overlay-content-wrapper | |
#overlay-layer | |
#overlay-content | |
%section.contens |
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
$ -> | |
$.fn.crop = (w, h) -> | |
$(this).on "load", -> | |
iw = ($(this).width() - w) / 2 | |
ih = ($(this).height() - h) / 2 | |
$(this).css "top", "-" + ih + "px" | |
$(this).css "left", "-" + iw + "px" |
例えば3つ前のcommitをやり直したいとき
git rebase -i HEAD~~~
または
git rebase -i HEAD~3
(~~~の数だけHEADから遡れる)
トピックブランチでデザイン作業後、masterにマージされるまでの間、masterのSassが最新のものから乖離してしまって作業が進められない問題を解決するために、git-cherry-pickで必要なSassの変更のみをmasterに取り込む
※この際、Sassだけcommitを分けると楽 → 不要なファイルやコンフリクトがなければそのままcommitごとmasterに取り込まれるので超ベンリです。
作業中のトピックブランチで git log
して必要なcommitのIDをコピー
$ git log
commit一覧が出てくるので、masterに取り込みたい「commit」の右側の文字列をコピー(下記の場合は 88ca4f2b3958748baf9947dcf1fdaebc01616cf6
をコピー)
$ git reflog
どこまで戻ればいいのか確認
9001e69 HEAD@{0}: pull: Fast-forward
e163cdc HEAD@{1}: commit: work in progress
cc4f489 HEAD@{2}: commit: Fix design for footer
e60b062 HEAD@{3}: rebase finished: returning to refs/heads/master
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
$ -> | |
targetUl = "ul#autoScroll" | |
targetList = "ul#autoScroll li" | |
targetListHeight = $(targetList).height() | |
delayTime = 4000 | |
scrollDistance = (-1 * targetListHeight) + 'px' | |
setInterval (-> | |
$(targetUl).find("li:first").appendTo(targetUl).show() | |
$(targetUl).find("li:first").hide -> |
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
$ rake routes CONTROLLER=hoges |