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

RE: "groups of files" in Git?

From
Randall S. Becker <rsbecker@nexbridge.com>
Date
Jul 11, 2017, 17:27 UTC
Message-ID
<000801d2fa6a$eb5e5130$c21af390$@nexbridge.com>
In-Reply-To
<CAEcERAz3vYekvJ8SM1FfdAVsP3LMVqA1O3yoJVThvg-0fPtVCg@mail.gmail.com>

-----Original Message----- On July 11, 2017 11:45 AM Nikolay Shustov wrote:

>I have been recently struggling with migrating my development workflow from Perforce to Git, all because of the following thing:
>I have to work on several features in the same code tree parallel, in the same Perforce workspace. The major reason why I cannot
>work on one feature then on another is just because I have to make sure that the changes in the related areas of the product play together well.
>With Perforce, I can have multiple changelists opened, that group the changed files as needed.
Show 5 quoted lines
>With Git I cannot seem to finding the possibility to figure out how to achieve the same result. And the problem is
>that putting change sets on different Git branches (or workdirs, or whatever Git offers that makes the changes to
>be NOT in the same source tree) is not a viable option from me as I would have to re-build code as I re-integrate
>the changes between the branches (or whatever changes separation Git feature is used).
>Build takes time and resources and considering that I have to do it on multiple platforms (I do cross-platform development) it really denominates the option of not having multiple changes in the same code tree.
Change sets are core git functionality. When you commit, you commit a group of changes across multiple files, not single file at a time, like most legacy SCM systems. Individual features are managed typically managed using topic branches that can be switched (using checkout) rapidly, which in your case will cause a localized rebuild based on what files were swapped.
If you need something slightly different than topic branches, do multiple clones off a base integration branch. This will give you multiple working source trees. Switch each clone to its own branch and work with them locally. If you need to move changes from one branch to another, commit, push on one branch, and pull merge to the other branch.
You could also use stash to accomplish similar things, but I wouldn't.

Cheers, Randall

Previous: Igor DjordjevicNext: Junio C Hamano
Message 10 of 26 in “"groups of files" in Git?”
  1. Nikolay ShustovJul 11, 2017
  2. Stefan BellerJul 11, 2017
  3. Nikolay ShustovJul 11, 2017
  4. Junio C HamanoJul 13, 2017
  5. Nikolay ShustovJul 13, 2017
  6. Junio C HamanoJul 13, 2017
  7. Igor DjordjevicJul 13, 2017
  8. Igor DjordjevicJul 13, 2017
  9. Igor DjordjevicJul 13, 2017
  10. Randall S. BeckerJul 11, 2017
  11. Junio C HamanoJul 11, 2017
  12. Nikolay ShustovJul 11, 2017
  13. Stefan BellerJul 11, 2017
  14. Nikolay ShustovJul 11, 2017
  15. Lars SchneiderJul 11, 2017
  16. Nikolay ShustovJul 11, 2017
  17. Lars SchneiderJul 11, 2017
  18. Nikolay ShustovJul 13, 2017
  19. Igor DjordjevicJul 11, 2017
  20. Nikolay ShustovJul 13, 2017
  21. Junio C HamanoJul 13, 2017
  22. Nikolay ShustovJul 13, 2017
  23. Fredrik GustafssonJul 11, 2017
  24. astianJul 11, 2017
  25. Nikolay ShustovJul 13, 2017
  26. Igor DjordjevicJul 13, 2017

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.