git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* Move some files, with all history, from one project into a new one
@ 2020-04-15  8:31 Kerry, Richard
  2020-04-15 15:11 ` Jeff King
  0 siblings, 1 reply; 5+ messages in thread
From: Kerry, Richard @ 2020-04-15  8:31 UTC (permalink / raw)
  To: git@vger.kernel.org

I would like to move some files, from the project in which they have always resided into  a new project.  I would like to keep all their history.
I don't want to waste space by also moving the rest of the old project's history, or historical file contents.

We have a long-standing project, main-system.  A group of files within it are designated as demo-system (sometimes whole folders, sometimes files within folders with other files).
All development is done on the master branch.
It has now transpired that the demo-system files are necessary, but no longer want to be within main-system but in a new project of their own.  So I would like to move them from the main-system repo into a new repo of their own.  I do want all their history but I don't want to take any contents from other files from main-system, which is quite big.
Please can someone advise if there is a particular method I should best use for this.
Do I create a new branch, then delete the rest of main-system leaving only what I want?  Surely if I do that then I would end up with all the main-system file data within the new repo, which would expand its size.
Is there a recommended way to extract certain files with their histories?

Regards,
Richard.


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-04-17 13:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-15  8:31 Move some files, with all history, from one project into a new one Kerry, Richard
2020-04-15 15:11 ` Jeff King
2020-04-15 15:49   ` Taylor Blau
2020-04-16  6:05     ` Elijah Newren
2020-04-17 13:48       ` Kerry, Richard

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).