Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Git ブランチで古いコミットに戻す方法は知っていますが、タグによって指定されたブランチの状態に戻すにはどうすればよいですか? 私は次のようなものを想定しています:
git revert -bytag "Version 1.0 Revision 1.5"
これは可能ですか?
git resetを使用します。
git reset --hard "Version 1.0 Revision 1.5"
(指定された文字列がタグであると仮定します)。
あなたがいる場合:
という名前のタグにリセットしますreset-to-here
reset-to-here
git reset --hard reset-to-here
変更をリモート強制にプッシュします+
+
git push origin +master