[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Can I retrospectively merge an old Git repo with a new one ?

From: Gavin Lambert <tsvn_at_mirality.co.nz>
Date: Thu, 23 Mar 2017 17:57:14 +1300

On 22/03/2017 04:41, Kerry, Richard wrote:
> I have just recently tried to change a Git project (ie repo) into a
> server. To get started with this, as it’s the first one I’ve done, I’m
> using the local protocol, ie the new repo is a file folder, cloned from
> the existing project using “clone into bare repo”.

This is the TortoiseSVN forum -- if you're asking Git questions you
should probably do so elsewhere.

But: if you have a local Git repo that contains history and you want to
upload it to a remote Git server (eg. GitHub), then you simply need to
create a blank repository using the server-side tools (eg. create a new
repository on GitHub), add this as a remote to your existing repository,
and then push. This will upload all the commit history to the server.

> This project has a bit of history, but up to now I’ve just made copies
> of the whole project folder and copied that around to work on. I’d like
> now to point those existing copied projects at my new, cloned, bare repo
> version. Can I do that ? Or do I need to check-out/clone it and start
> again and manually merge existing files ?

This sounds like you haven't actually been using the version control
properly, so it's unclear what you meant above.

Did you start by cloning someone else's Git repo and have been making
local changes just by copying the folder? Or did you create an empty
local repo and commited some changes to it before stopping and making
copies instead? Or have you been making a mix of copies and commits?

Do you care about retaining the history of this project or are you only
interested in preserving the current and future states?

Either way, you've made a mess for yourself, but it can be cleaned up;
we just need to work out what state things are starting in and how much
of the history you want to preserve. (And whether you really are
talking about Git or SVN.)

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3222076

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_tortoisesvn.tigris.org].
Received on 2017-03-25 01:13:50 CET

This is an archived mail posted to the TortoiseSVN Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.