H
H
Hint2013-07-23 17:47:08
git
Hint, 2013-07-23 17:47:08

git clone to existing folder without deleting files

There is a fighting server. There is a repository with its scripts. On the server itself, there are a huge number of other files that are not in the repository, but which cannot be touched (they are separated into different folders, of which there are a lot). Previously, files changed in the repository were uploaded to the production server manually. Now I just want to do a git pull. How can I turn a folder on the production server into a working git folder, and move all the files from the repository there, but so that the rest of the files (which are not in git) are not affected?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
N
Nikolai Vasilchuk, 2013-07-23
@Anonym

Clone to a temporary folder and transfer to the desired one. One small script.

5
505abc, 2013-07-23
@505abc

git-scm.com/book/ru/%D0%98%D0%BD%D1%81%D1%82%D1%80%D1%83%D0%BC%D0%B5%D0%BD%D1%82 %D1%8B-Git-%D0%9F%D0%BE%D0%B4%D0%BC%D0%BE%D0%B4%D1%83%D0%BB%D0%B8
git submodule, no?

S
Skywrtr, 2013-07-23
@Skywrtr

And just create an empty repository on the server (git init) and then pull, specifying the desired repository?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question