railstチュートリアル3章で作成するサンプルアプリケーションのレポジトリをリモートレポジトリにプッシュしたいのですが、出来ません。
githubにて反映されてることを期待したにですが出来ませんでした。以下、私が試した手順です。
・
・
・
・
$ git remote add origin git@github.com:Masaki-Maejima/sample_app.gitを実行。リモートリポジトリ(GitHub)にaddした
↓
$ git push -u origin --allを実行したところ
ーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーTo github.com:Masaki-Maejima/sample_app.git
! [rejected] master -> master (fetch first)
error: failed to push some refs to 'git@github.com:Masaki-Maejima/sample_app.git'
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
ーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーが表示された。
Github上でsample_appという名前のレポジトリを作ってしまっていたので削除した上で、git init .
Add,commitの手順をやり直し、再度
↓
$ git remote add origin git@github.com:Masaki-Maejima/sample_app.gitを実行。
↓
したが、fatal: remote origin already exists.のメッセージが出たので、ググる
↓
https://qiita.com/_bns/items/c3f9559890b5205761b8
↓
git remote rm origin originを削除してやり直すと良いとあったため,参照し、実行
↓
再度リモートアドして、git push -u origin --allを実行するも、
ERROR: Repository not found.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
が表示された。
ここで止まっています。
ご存知の方、教えていただけたら幸いでございます。
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2018/11/10 03:36
2018/11/10 05:53