blog.sowatchasayin

Rails etc.

やっちまった!


setup do
#ここにコントローラのコードを書いてしまった
end

write meaningful entry

Rails Insideってブログがあります。
その名の通りRuby on Rails情報が載ってるサイトです。
この度、外部の記事提供者を募集し始めるとのこと。
I'm Handing Rails Inside Over To.. You! - Rails Inside


下記、提供記事のガイドラインから引用です。
一般的なブログを書く心得として使えそう。

Some content guidelines:

* News, opinion pieces, event summaries, and link roundups all welcome.
* At least 3 paragraphs.
* At least 200 words. Ideally 220-280 for news, longer as necessary for tutorials or opinion pieces.
* At least one image - which we have the rights to run.. if you use a Creative Commons licensed image, please credit it appropriately.
* Nothing racist/profane/etc, sorry!
* Ensure that the first paragraph is in the 50~80 word range and summarizes (or at least properly introduces) the topic of the post. See existing posts for guidance.
* If something is more suited to RubyFlow or already exists on your own blog, post it on RubyFlow.
* Content should be new/fresh for Rails Inside initially, but you can post it to your own blog too afterwards, of course :-)

最初のパラグラフをサマリにする、ってのは理系論文スタイルですね。
学術論文のメディアとしての洗練され具合は面白いです。査読制度とか。

git commit --amendはpushしたらやっちゃダメ

commitに「やっぱり」をかけたい時、ありますよね。
そんな時はgit commit --amendです。直前のコミットにワークツリーの変更を後乗せして、さも元々そうだったかのように見せることができます。
さてそれをpushするときどうするか…。普通にやるとgitに怒られます。

そこで質問
How do I push amended commit to the remote git repo?

--forceをつければOKです。でも誰かが「やっぱり」前のコミットをベースに変更しているかもしれないから、やっちゃダメですって話。

I actually once pushed with --force to git.git repository and got scolded by Linus BIG TIME. It will create a lot of problems for other people. A simple answer is "don't do it".

because if someone already got your changes, then when they try to pull again, it might fail.


何にせよ、多くの場合、「やっぱり」はよくない結果を生みますね。あと--forceも。
意思決定、合意形成はどこに行っても大事ってことで。

タダで雇えるバーチャル師匠

ネット上の誰かを仮想メンターを「雇う」って話。

To recruit a virtual mentor, first find someone whose success and ideas you respect. Second, find literally everything that they’ve written. Third, find everything in video that they’ve done. Finally, find all of their products or apps or books and get them too. Once you’ve consumed everything that they’ve produced, setup a google alert for them and read anything new as it comes out

[意訳]
まず、成功していて考えがリスペクトできる人を探す。次に、彼らが書いたものを全部見つける。そんで動画も見る。製品、本とかアプリも全部ゲット。
彼らの作ったもの全部をこなしたら、グーグルのアラート(google readerとかすね)をセットして、新しく出るを速攻チェックできるようにして、全部読む。

Recruit virtual mentors

これはいい方法です。(一方的に)師事してしばらく経ってある程度吸収すると、気に入らないところが出てくる。そこで考えればいいわけです。それまでは自分の知識とか感覚とかをパワーフィーディングできます。

Author

Fujimura Daisuke
http://fujimuradaisuke.com

Labels