+4

"Change Sets" feature as found in SVN

adam 3 years ago updated by Philip Tarpley 2 years ago 4

More info: http://www.syntevo.com/doc/display/SU/Change+Sets

I know there's not a Git feature exactly like SVN's "Changelist", so perhaps that is why SmartGit doesn't have this feature. However, IntelliJ provides its own changelist functionality for Git projects, so I'm hoping there's a way to do this within SmartGit.

I often have several tickets/tasks pending at the same time, so being able to group change files by some label (e.g., ticket number) makes managing commits much easier.

+1

I'll add another use-case for this.


Our project regularly has tracked files which change as a result of simply running the application.  The reason that they change are often outside of our control and are due to some quirk in whatever version of Unity we happen to currently be using.  The changes are meaningless and therefore we don't want to muddy up their history by actually committing them.


So, in SmartSvn, I would plop these annoying files into a Change Set called something like "TempIgnore" simply to sequester them away from meaningful changes..


+1

If the files are changed, but should be treated as unchanged, please select the files and invoke Local | Toggle "Assume Unchanged".

This is exactly the issue myself and quite a few coworkers are running into. we are losing work because every change requires sifting through tens, or hundreds of "junk files" in order to find the legitimate work worth committing. this exhausting process that must be repeated every time that unity is brought to the foreground\for every commit.

+1

Evan, here is my general workflow for dealing with this:


  1. In SmartGit, I have a shortcut key defined for "Skip Worktree" (done from Edit->Customize->Accelerators).  You can also do it from the Local menu as Thomas suggested above.
  2. Whenever a file pops up as changed that I don't care about, I'll toggle its Skip Worktree flag.
  3. I spend most of my time in Visual Studio, using its Team Explorer window to track current changes.  Having Skip Worktree toggled will make it not show up there, which really cleans things up.
  4. Back in SmartGit, I do have the "If selected, skipped files will be shown" flag set b/c I don't want to forget which files are skipped, as it can cause issues when switching between branches.  The list is clean in Visual Studio, showing only important changes, so I'm covered for what I normally care about.
  5. Whenever I'm ready to commit, I usually just do it in visual studio (which will have an uncluttered list), but you could obviously do it from SmartGit and sort by State (skipped ones will be separated), or just toggle the option to not show skipped files and you'll have a clean list there, too.  It's worth noting that files toggled with Skip Worktree cannot be committed...you can't accidentally do it.


Luckily for me, it is usually only a handful of files, not hundreds, so you'll have more work cut out for you...don't think even change sets would solve that.


The reason I chose to use "Skip Worktree" over "Assume Unchanged" is based on guidance from people in the #git IRC channel when I was asking about the difference...they suggested to stay away from Assume Unchanged if the files are actually changing (which they are).