git/list[1] front-page[2] threads[3] people[4] search[5] about
 

git cp command?

From
JWJeffrey Walton <noloader@gmail.com>
Date
Apr 7, 2020, 06:02 UTC
Message-ID
<CAH8yC8nzc6My_DyTJ1vyZ4zvsOiSegM01p1xsS_bABc70=SPCg@mail.gmail.com>

I have a large source file and I want to split it into two pieces. I want to preserve the history so someone can start at either of the copies and work back to the original file.

I see folks talking about a "git copy" at https://stackoverflow.com/a/44036771, but I am not really following what is happening with moves and merges and the other extra commands.

Can someone please provide the commands to copy the file using Git.
Thanks in advance.
Message 1 of 1 in “git cp command?”
  1. Jeffrey WaltonApr 7, 2020

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.