0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

初めてマージを理解した。

Last updated at Posted at 2016-11-19

Ruby on Rails Tutorialを第5章まで進めています。
いろんな経緯でmastercheckoutしたところ、いきなり作ったヘルパーとかなくなってるから焦りました。
ブランチの一覧とか、コミットの履歴とかいろいろ見ているうちに作業ブランチを間違えていたことに気づいたわけですね。
(てか、ここでやっとブランチとかcheckoutする意味とかわかりました・・・)

ということで、なんとかmasterにこれまでの変更箇所を反映させたく、お世話になります「サルでもわかるGit入門」さんで調べさせていただいたところ、「マージすればいいんだ!てか、マージってそういうことか!!」
と気づきましたので備忘録です。

マージ方法

1.まずは変更する方のブランチへ

$git checkout master

2.マージする

$git merge issue

まとめ

マージはブランチを統合することだと思っていましたが、実行してもブランチが1つになるわけではありませんでした。

*こちらのページを参考にさせていただきました。
http://www.backlog.jp/git-guide/stepup/stepup2_4.html

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?