githubにpushできない
解決したいこと
Ruby on RailsでWebアプリをつくっています。
githubにpushした際に以下のエラーが起こりました。
解決方法を教えて下さい。
発生している問題・エラー
! [rejected] master -> master (non-fast-forward)
error: failed to push some refs to 'github.com:maneshinboys/portfolio.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
自分で試したこと
git merge --allow-unrelated-histories コマンドを打つ
⇒fatal: No remote for the current branch. の表示
初学者で、勉強不足なのでここで止まってしまいました。。
どうぞよろしくお願いいたします。
