同步本地文件到github回购 [英] syncing local file to github repo
问题描述
我使用Git将文件提交到Github上的repo中
您不直接将文件直接提交到GitHub上的repo,您在本地克隆中进行提交,然后将这些提交推送到远程存储库,在这种情况下,GitHub 。
...使用git show确认它已成功
git show
不会告诉你push是否成功,它只显示最后一次提交的内容。
我无法在GitHub上看到该文件。为什么会这样?
您是否做过 git push
?
将文件同步到GitHub的简单说明
你不用git同步文件,你使用提交。您可以使用 git push
将本地提交推送到远程, git fetch
验证或表明它已被推送到GitHub?
git push 的输出告诉你push是否成功。
Beginner question/problem. I used Git to commit a file to a repo on Github and used git show to confirm that it had been successful, but I'm unable to see the file on GitHub. Why is that? Are there any simple instructions for syncing up a file to GitHub that I could use to verify or indicate that it was pushed to GitHub?
I used Git to commit a file to a repo on Github
You don't commit files directly to a repo on GitHub, you make commits in your local clone and then push those commits to remote repository, in this case GitHub.
... used git show to confirm that it had been successful
git show
does not tell you if the push has been successful or not, it just shows the contents of the last commit.
I'm unable to see the file on GitHub. Why is that?
Did you do a git push
?
simple instructions for syncing up a file to GitHub
You don't sync files with git, you work with commits. You use git push
to push local commits to a remote, and git pull
or git fetch
to get commits from a remote to your local repo.
verify or indicate that it was pushed to GitHub?
The output of git push
tells you if the push succeeded or not.
这篇关于同步本地文件到github回购的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!