2017-01-16 2 views
-2

私のディレクトリはgh-pagesにリンクされていて、何週間もうまくいきました。私は.gitfileというファイルを削除しました。それは意味がないと思っていましたが、明らかにそうではありませんでした。今私は私のプロフィールページに変更をプッシュすることはできません。私は古いウェブサイトmurphypicard.github.ioに行き、その変更を続けていきたいと思います。私の偶然gitファイルを削除しました(アトム、私のテキストエディタ)時間と時間前

私のディレクトリの名前はportfoliopageで、私のGH-ページのURLはmurphypicard.github.ioある

ここ

私がこれまで試したコマンドは次のとおりです。

~/wdi/portfoliopage (master)$ git remote add origin https://murphypicard.github.io/ 

~/wdi/portfoliopage (master)$ git remote -v 
origin //murphypicard.github.io/ (fetch) 
origin //murphypicard.github.io/ (push) 

~/wdi/portfoliopage (master)$ git remote get-url 
origin //murphypicard.github.io/ 

~/wdi/portfoliopage (master)$ git push -u origin master 
fatal: repository //murphypicard.github.io/' not found 

~/wdi/portfoliopage (master)$ git remote add origin https://murphypicard.github.io/ 
fatal: remote origin already exists. 

~/wdi/portfoliopage (master)$ git remote add origin [email protected]:MurphyPicard/arayaghsizian.github.io.git 
fatal: remote origin already exists. 

~/wdi/portfoliopage (master)$ git push origin master 
fatal: repository //murphypicard.github.io/' not found 

~/wdi/portfoliopage (master)$ git push gh-pages master 
fatal: 'gh-pages' does not appear to be a git repository 
fatal: Could not read from remote repository. 

私も持っています運がないset-urlを試しました。

私のコミットを古いghページにプッシュする方法はありますか?

答えて

0

.git/configファイルを編集し、そこに正しいリモートURLを追加してください。

以下のような何か:あなたが見ることができるよう、remote repositoryが空で、

git remote set-url origin [email protected]:MurphyPicard/arayaghsizian.github.io.git 

しかし:

[remote "origin"] 
url = [email protected]:MurphyPicard/arayaghsizian.github.io.git 
fetch = +refs/heads/*:refs/remotes/origin/* 
0

コマンドがあります。

更新:

それはあなたが使用するリモートリポジトリ何明確ではありません。 GitHub pageにアクセスし、リポジトリを参照して、ローカルリポジトリにリンクするリポジトリを選択してください。

あなたのコメントからこの質問には、repoはhttps://github.com/MurphyPicard/murphypicard.github.ioと思われます。このレポのページをブラウザで開いて、「クローンまたはダウンロード」という名前の緑色のボタン(ページの右側)を押して、git remoteコマンドで使用するURLを表示します。

murphypicard.github.ioの場合、URLは[email protected]:MurphyPicard/murphypicard.github.io.gitです。

したがって、あなたのコマンドは次のようにする必要があります:可能であれば

git remote set-url origin [email protected]:MurphyPicard/murphypicard.github.io.git 
+0

、私はこれまで押し続けていきたいと考えて:https://murphypicard.github.io/ 私が試した:gitのリモート設定、URLの原点をhttps://murphypicard.github.io/運がない –

+0

私は試しました: '' '〜/ wdi/portfoliopage(master)$ git remote set-url origin [email protected]:MurphyPicard.github.io.git 〜/ wdi/portfoliopage(master)$ git push origin master エラー:リポジトリが見つかりません。 致命的:リモートリポジトリから読み取れませんでした。 正しいアクセス権が であり、リポジトリが存在することを確認してください。 〜/ wdi/portfoliopage(master)$ git push gh-pages master 致命的: 'gh-pages'がgitリポジトリではない 致命的:リモートリポジトリから読み取れませんでした。 という正しいアクセス権があり、リポジトリが存在することを確認してください.''' –

関連する問題