V
V
Vyacheslav Shevchenko2020-02-27 20:15:09
git
Vyacheslav Shevchenko, 2020-02-27 20:15:09

How to initialize git in an existing project and compare what's changed with the remote repository?

Hello.
There is a folder in which there are files not under the git and there is a remote repository in which the same files are located, but newer, with new edits. How to initialize git and compare with remote repository? You need to make sure that there are no files in this folder other than the remote repository.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
J
jcmvbkbc, 2020-02-27
@jcmvbkbc

git init
git add .
git commit
git remote add <remote-name> <url>
git fetch <remote-name>
git diff <remote-name>/<remote-branch>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question