LoginSignup
4
4

More than 5 years have passed since last update.

SourceTree で feature ブランチを作ろうとしたら Please run "git flow init" first.

Last updated at Posted at 2015-05-20

日々 SoruceTree にある Git Flow 機能にお世話になっていて、コマンドから feature ブランチを作ったことがありません。
ところが突然、いつものように feature ブランチを作ろうとしたらエラーが出た。

sh.exe C:*********\Atlassian\SourceTree\gitflow_local\gitflow\git-flow feature start new_branch
fatal: Not a gitflow-enabled repo yet. Please run "git flow init" first.

エラー終了しました。エラーの内容は上記をご覧ください。

今までは問題なく作れていたし、何も変えてないのに突然なぜ!?(←よくある、実は何かしてるやつ)と思いつつ、指示通りターミナルを開いて "git flow init" したみたけど git flow をインストールしてなくて(?)コマンドが認識されない。

いろいろ調べた結果、実は master ブランチをローカルから削除していたことが原因だと判明しました!!
稀なケースだろうけど、ぐぐってもそういうケースが見つからないので残しておきます。
master develop ブランチはちゃんとローカルにないとそりゃーダメですよね。。。

4
4
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
4
4