Change 'rbt diff' and 'rbt post' to take revisions as arguments.
Review Request #5226 — Created Jan. 9, 2014 and submitted
Change 'rbt diff' and 'rbt post' to take revisions as arguments.
This change updates the 'diff' and 'post' commands to treat extra arguments as
the revision spec, and adds a new -I/--include flag to specify any files to
limit the diff to.This is done for all SCMs except ClearCase. I need to work through all the
pending ClearCase patches and read through the proposal on how to fit it into
this new world order.This also includes some changes to the way that changenums are pulled out for
perforce and plastic. Ideally I'd like to get rid of the server-side
summary/description fetch and implement the --guess-* options, but that would
likely piss off a lot of users. Instead, I've just moved the changenum
extraction into the diff methods, so that we don't duplicate the work of
parsing revisions in two different ways. This also returns 'None' for submitted
changelists (for now) because the server-side code is broken at the moment.Whether or not files are supported is currently client-dependent. Most already
did, and I've added it for git. It's still not done for Plastic, since my
Plastic expertise is exactly zero.
- Ran unit tests
- Checked diffs and extracted summaries for:
- bzr backend with zero, one, and two-arg forms.
- cvs backend with zero arguments. I haven't tested the two-arg form because
after trying four different public CVS repos, I have yet to find one that
(a) has a CVSROOT, (b) allows me to check it out, (c) allows me to do a
diff between two tags, and (d) have that diff not contain broken text
encodings. - hg backend with zero, one, and two-arg forms.
- hgsubversion backend with zero, one, and two-arg forms.
- git backend with zero, one, and two-arg forms.
- git-p4 backend with zero, one, and two-arg forms.
- git-svn backend with zero, one, and two-arg forms.
- perforce backend with zero, one, and two-arg forms, including submitted and
shelved changesets. - svn backend with zero, one, and two-arg forms, including changelists.
Description | From | Last Updated |
---|---|---|
I think RBTools' current approach for Mercurial is wrong. This patch (along with the previous code) is very happy about … |
IN indygreg | |
"Subversion" |
chipx86 | |
Should add a trailing period. |
chipx86 | |
Same comments as with diff. |
chipx86 |
-
-
I think RBTools' current approach for Mercurial is wrong. This patch (along with the previous code) is very happy about using 'tip' and the revlog revision range to construct outgoing changesets and diffs.
Please note that the revlog revision order is different from the DAG. The only guaranteed similarity is that a single revision's parent must come before the child in the revlog.
I have a set of outstanding patches (which will conflict significantly with this patch) that do away with blanket
hg out
(without -r). This ensures that every changeset under consideration by RBTools chains up through the DAG to a specific parent. Otherwise, we may have changesets belonging to other heads creaping in.FWIW, your refactoring of adding revspec to all the functions is very similar to what I've done. I think we share many of the same opinions on what is needed to improve Mercurial support. There's just a few issues to work out.
Perhaps the Mercurial refactoring should be done as a standalone patch before the API change on rbt diff and post?
-
I have a few patches that conflict with this and your other patch. This patch makes me very happy and is larger in scope than just Mercurial. I'm totally fine with waiting for this patch to land and rebasing my work on top of it.
- Change Summary:
-
- Make requested changes
- Fix arguments to get_diff in 'rbt post'
- Description:
-
Change 'rbt diff' and 'rbt post' to take revisions as arguments.
This is a preliminary post that will probably change as I test things more
thoroughly. I just wanted to get feedback on what I have. This change updates the 'diff' and 'post' commands to treat extra arguments as
the revision spec, and adds a new -I/--include flag to specify any files to limit the diff to. This is done for all SCMs except ClearCase. I need to work through all the
pending ClearCase patches and read through the proposal on how to fit it into this new world order. Whether or not files are supported is currently client-dependent. Most already
did, and I've added it for git. It's still not done for Plastic, since my Plastic expertise is exactly zero. - Testing Done:
-
~ Ran unit tests.
~ Need to do a ton more with each SCM. ~ - Ran unit tests
~ - Tested zero, one, and two-arg posting with the Git backend. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
- Change Summary:
-
Fix some issues I encountered while testing the SVN backend.
- Description:
-
Change 'rbt diff' and 'rbt post' to take revisions as arguments.
This is a preliminary post that will probably change as I test things more
thoroughly. I just wanted to get feedback on what I have. This change updates the 'diff' and 'post' commands to treat extra arguments as
the revision spec, and adds a new -I/--include flag to specify any files to limit the diff to. This is done for all SCMs except ClearCase. I need to work through all the
pending ClearCase patches and read through the proposal on how to fit it into this new world order. Whether or not files are supported is currently client-dependent. Most already
did, and I've added it for git. It's still not done for Plastic, since my Plastic expertise is exactly zero. - Testing Done:
-
- Ran unit tests
~ - Tested zero, one, and two-arg posting with the Git backend. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git backend with zero, one, and two-arg posting. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
+ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
- Change Summary:
-
- Fix issues with perforce backend.
- Change the way that changenums are extracted.
- Remove check for p4d 2002.2. I think it's safe to say that people aren't running a version > 10 years old.
- Description:
-
Change 'rbt diff' and 'rbt post' to take revisions as arguments.
This is a preliminary post that will probably change as I test things more
thoroughly. I just wanted to get feedback on what I have. This change updates the 'diff' and 'post' commands to treat extra arguments as
the revision spec, and adds a new -I/--include flag to specify any files to limit the diff to. This is done for all SCMs except ClearCase. I need to work through all the
pending ClearCase patches and read through the proposal on how to fit it into this new world order. + This also includes some changes to the way that changenums are pulled out for
+ perforce and plastic. Ideally I'd like to get rid of the server-side + summary/description fetch and implement the --guess-* options, but that would + likely piss off a lot of users. Instead, I've just moved the changenum + extraction into the diff methods, so that we don't duplicate the work of + parsing revisions in two different ways. This also returns 'None' for submitted + changelists (for now) because the server-side code is broken at the moment. + Whether or not files are supported is currently client-dependent. Most already
did, and I've added it for git. It's still not done for Plastic, since my Plastic expertise is exactly zero. - Testing Done:
-
- Ran unit tests
- Tested the Git backend with zero, one, and two-arg posting. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
~ - Testing the Perforce backend with zero, one, and two revisions, including
submitted and shelved changesets. Verified that the resulting diffs and
summaries/descriptions were correct.
+ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
- Change Summary:
-
Updated testing to list git-svn backend.
- Testing Done:
-
- Ran unit tests
- Tested the Git backend with zero, one, and two-arg posting. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
~ - Testing the Perforce backend with zero, one, and two revisions, including
submitted and shelved changesets. Verified that the resulting diffs and
summaries/descriptions were correct.
~ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
~ - Tested the Git-SVN backend with zero, one, and two-arg posting. Verified that
the resulting diffs and guessed summaries/descriptions were correct.
~ - Testing the Perforce backend with zero, one, and two revisions, including
submitted and shelved changesets. Verified that the resulting diffs and
summaries/descriptions were correct.
+ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
- Change Summary:
-
Fix the parameters to extract_description for mercurial.
- Testing Done:
-
- Ran unit tests
~ - Tested the Git backend with zero, one, and two-arg posting. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git-SVN backend with zero, one, and two-arg posting. Verified that
the resulting diffs and guessed summaries/descriptions were correct.
~ - Testing the Perforce backend with zero, one, and two revisions, including
submitted and shelved changesets. Verified that the resulting diffs and
summaries/descriptions were correct.
~ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
~ - Tested the hgsubversion backend with zero, one, and two-arg posting. Verified
that the resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git backend with zero, one, and two-arg posting. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git-SVN backend with zero, one, and two-arg posting. Verified that
the resulting diffs and guessed summaries/descriptions were correct.
~ - Testing the Perforce backend with zero, one, and two revisions, including
submitted and shelved changesets. Verified that the resulting diffs and
summaries/descriptions were correct.
+ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
- Change Summary:
-
git-p4 testing details
- Testing Done:
-
- Ran unit tests
- Tested the hgsubversion backend with zero, one, and two-arg posting. Verified
that the resulting diffs and guessed summaries/descriptions were correct.
- Tested the Git backend with zero, one, and two-arg posting. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git-SVN backend with zero, one, and two-arg posting. Verified that
the resulting diffs and guessed summaries/descriptions were correct.
~ - Testing the Perforce backend with zero, one, and two revisions, including
submitted and shelved changesets. Verified that the resulting diffs and
summaries/descriptions were correct.
~ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
~ - Tested the Git-P4 backend with zero, one, and two-arg posting. Verified that
the resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git-SVN backend with zero, one, and two-arg posting. Verified that
the resulting diffs and guessed summaries/descriptions were correct.
~ - Testing the Perforce backend with zero, one, and two revisions, including
submitted and shelved changesets. Verified that the resulting diffs and
summaries/descriptions were correct.
+ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
- Change Summary:
-
Update testing info to include hg, reformat for readability.
- Testing Done:
-
- Ran unit tests
~ - Tested the hgsubversion backend with zero, one, and two-arg posting. Verified
that the resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git backend with zero, one, and two-arg posting. Verified that the
resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git-P4 backend with zero, one, and two-arg posting. Verified that
the resulting diffs and guessed summaries/descriptions were correct.
~ - Tested the Git-SVN backend with zero, one, and two-arg posting. Verified that
the resulting diffs and guessed summaries/descriptions were correct.
~ - Testing the Perforce backend with zero, one, and two revisions, including
submitted and shelved changesets. Verified that the resulting diffs and
summaries/descriptions were correct.
~ - Tested the SVN backend with zero, one, and two revisions, as well as
changelists. Verified that the resulting diffs were correct.
~ - Checked diffs and extracted summaries for:
~ - hg backend with zero, one, and two-arg forms.
~ - hgsubversion backend with zero, one, and two-arg forms.
~ - git backend with zero, one, and two-arg forms.
~ - git-p4 backend with zero, one, and two-arg forms.
~ - git-svn backend with zero, one, and two-arg forms.
+ - perforce backend with zero, one, and two-arg forms, including submitted and
shelved changesets.
+ - svn backend with zero, one, and two-arg forms, including changelists.
- Change Summary:
-
CVS testing info
- Testing Done:
-
- Ran unit tests
- Checked diffs and extracted summaries for:
~ - hg backend with zero, one, and two-arg forms.
~ - hgsubversion backend with zero, one, and two-arg forms.
~ - git backend with zero, one, and two-arg forms.
~ - git-p4 backend with zero, one, and two-arg forms.
~ - git-svn backend with zero, one, and two-arg forms.
~ - perforce backend with zero, one, and two-arg forms, including submitted and
shelved changesets.
~ - svn backend with zero, one, and two-arg forms, including changelists.
~ - cvs backend with zero arguments. I haven't tested the two-arg form because
after trying four different public CVS repos, I have yet to find one that
(a) has a CVSROOT, (b) allows me to check it out, (c) allows me to do a
diff between two tags, and (d) have that diff not contain broken text
encodings.
~ - hg backend with zero, one, and two-arg forms.
~ - hgsubversion backend with zero, one, and two-arg forms.
~ - git backend with zero, one, and two-arg forms.
~ - git-p4 backend with zero, one, and two-arg forms.
~ - git-svn backend with zero, one, and two-arg forms.
~ - perforce backend with zero, one, and two-arg forms, including submitted and
shelved changesets.
+ - svn backend with zero, one, and two-arg forms, including changelists.
- Change Summary:
-
Final update: ready for review!
- Description:
-
Change 'rbt diff' and 'rbt post' to take revisions as arguments.
- This is a preliminary post that will probably change as I test things more
- thoroughly. I just wanted to get feedback on what I have. - This change updates the 'diff' and 'post' commands to treat extra arguments as
the revision spec, and adds a new -I/--include flag to specify any files to limit the diff to. This is done for all SCMs except ClearCase. I need to work through all the
pending ClearCase patches and read through the proposal on how to fit it into this new world order. This also includes some changes to the way that changenums are pulled out for
perforce and plastic. Ideally I'd like to get rid of the server-side summary/description fetch and implement the --guess-* options, but that would likely piss off a lot of users. Instead, I've just moved the changenum extraction into the diff methods, so that we don't duplicate the work of parsing revisions in two different ways. This also returns 'None' for submitted changelists (for now) because the server-side code is broken at the moment. Whether or not files are supported is currently client-dependent. Most already
did, and I've added it for git. It's still not done for Plastic, since my Plastic expertise is exactly zero. - Testing Done:
-
- Ran unit tests
- Checked diffs and extracted summaries for:
~ - cvs backend with zero arguments. I haven't tested the two-arg form because
after trying four different public CVS repos, I have yet to find one that
(a) has a CVSROOT, (b) allows me to check it out, (c) allows me to do a
diff between two tags, and (d) have that diff not contain broken text
encodings.
~ - hg backend with zero, one, and two-arg forms.
~ - hgsubversion backend with zero, one, and two-arg forms.
~ - git backend with zero, one, and two-arg forms.
~ - git-p4 backend with zero, one, and two-arg forms.
~ - git-svn backend with zero, one, and two-arg forms.
~ - perforce backend with zero, one, and two-arg forms, including submitted and
shelved changesets.
~ - svn backend with zero, one, and two-arg forms, including changelists.
~ - bzr backend with zero, one, and two-arg forms.
~ - cvs backend with zero arguments. I haven't tested the two-arg form because
after trying four different public CVS repos, I have yet to find one that
(a) has a CVSROOT, (b) allows me to check it out, (c) allows me to do a
diff between two tags, and (d) have that diff not contain broken text
encodings.
~ - hg backend with zero, one, and two-arg forms.
~ - hgsubversion backend with zero, one, and two-arg forms.
~ - git backend with zero, one, and two-arg forms.
~ - git-p4 backend with zero, one, and two-arg forms.
~ - git-svn backend with zero, one, and two-arg forms.
~ - perforce backend with zero, one, and two-arg forms, including submitted and
shelved changesets.
+ - svn backend with zero, one, and two-arg forms, including changelists.