Replace loremipsum with faker, drop discover as unneeded and ensure any
remaining requirements match the minimum requirements.
Change-Id: Ia5c5b033173c09e899e52b23f548ff822af998f0
Git 2.9+ requires an explicit option to merge unrelated
histories together. Switch all the merge commands to try
to merge without this option and call it if the stderr
indicates that it is explicitly needed.
Change-Id: I929b310126ed0ae4d6c9726e81d86c0609c3b6e2
GitHub projects commonly include explicit merges even when not
necessary, make sure to skip these as candidates of a previous import.
After checking the other parents of an import to see if any were an
empty merge of an obsolete commit, test whether the parents are
themselves a subset of the ancestry commits and ignore should this be
true.
Change-Id: I8b8f0b0689301cedb8b4352c3decb569c94a0e33
When encountering multiple non-contributing commits included in a merge
that is TREESAME to the existing contents, ensure a list of all commits
being brought in by that merge are included in the list to be pruned
from history.
Change-Id: I643e0923f8967f9b70d10b8796688b782681bfe0
Closes-Bug: #1648029
Catch a non-contributing merge of a commit where it's parent is within
the ancestry path to the previous upstream imported.
Add it to a list of commits to be stripped to ensure when encountered
it is removed from being attempted to be re-played.
Change-Id: Ibf5034a4eec5a92097cc38120959fcc12a44af74
Related-Bug: #1648029
Continue checking until the last possible candidate has been inspected
in case we encountered a merge commit that looks a lot like an import
merge commit does.
It is possible for a merge to occur where the commit brought in does
not contribute anything to the resulting tree. In such cases the merge
commit will appear TREESAME to the previous state of the branch, and
will be mistaken to be an import merge. Ensure if there is an
additional merge commit to be considered that it is also checked.
Change-Id: If5694506b59e1288e23aecbe6e0bf8297574c72a
Related-Bug: #1648029
Removing merge commits that do not contribute to the tree during
listing, reduces the number of merge commits to be subsequently pruned.
In future any remaining merges may indicate a problem, or be used to
reduce conflict cases by preserving them should users be utilizing
manual merges to resolve patch conflicts.
Change-Id: I8118db5acace6cb5d3b056c3d2cdaf398026c84c
Ensure the test for checking "change merge result is identical from
both upstream with carried patches and current" can be handled
correctly is building the test tree correctly using 'cherry-pick' to
duplicate the tree state.
For cherry-pick of changes to work correct, enable use of 'force
cherry-pick' through the '-x' option, to ensure a new commit is always
made instead of allowing for the possibility of a fast-forward to occur.
Include a modification to the commit message to insert the new node name
in the message (e.g "[C] Add file change" is cherry-picked as "[C1] Add
file change")
This changes exposed a random bug where the walking of the graph results
in the same node being visited twice. This in turn causes the wrong
commit id to be stored and reused to checkout the desired node when
building the tree resulting in a very broken graph.
Add a check for the _FINISHED flag being set to spot this scenario and
use this to avoid returning the same node twice in the topological
sorted graph, which in turn ensures that we do not accidentally
recreate a second commit for the same node, replacing the original node.
Change-Id: Ie1ae27196b3616979826e2df72df3cb7a517475d
Shorten subcommands page title by removing 'Git-Upstream '
to avoid line wrapping in sidebar display.
Change-Id: I6d742e846065c624579e567c1435c53b3946ae8c
* Clean up README
* Add some info for developers/unit tests/support to README for GitHub
* Split up inclusion of contents from README
Change-Id: I91abfedce06827d5111370750c55384d7aff1a8e
xrange no longer exists in python 3, and since it is a small number of
iterations there is a limited performance impact under python 2 by
using range instead.
Add check to ensure linearisation exception does not occur under python
3, due to exception in attempting to use a non existing function.
Change-Id: I3e6165b8bce14a44459fc9419792784f64636f5e
Add simple regression test to ensure that setting sequence.editor will
not cause a hang, and add a timeout to interactive mode tests to ensure
they are terminated with an error should they fail to complete
reasonably quickly (suggesting a hang).
Early release 0.9.0 had an issue where setting sequence.editor would
cause git-upstream to hang, due to git-rebase attempting to launch the
editor specified, while the console was being redirected by python's
subprocess.
At some point a behaviour change meant the config setting
sequence.editor was no longer used by the python subprocess calling
git-rebase. Instead the tool would launch the user specified editor
directly (checking the git config settings for sequence.editor, then
core.editor, and falling back to the environment variable EDITOR if
neither were set), and would instead ensure that when finally calling
git-rebase it would only use the special editor provided by
git-upstream.
However it's still important to check that setting sequence.editor
does not cause any future problems such the code be refactored again.
Change-Id: I303dced0d1a52791d18b39e8e6d342374e3d2eeb
Related-Bug: #1394553
Allow links to be specified to the source files, which will be
converted correctly by GitHub, by ensuring the sphinx generation then
transforms the link from the source file to the correct output file
depending on the builder used.
Change-Id: I18ac055fc6d44982048365cad819f891786484a8
Change side bar toc to a full toc to show both global and local toc
simultaneously.
Change-Id: Ied595bab97bccb8cd942c2a0b35a429d7ee88bfb
Depends-On: I8dced20b036c267799b609a6fa719f6afde89a10
Make the reason to test for ambiguous arguments clearer as well as
better explain why creating a file with a name the same as a SHA1 that
will be examined by the searcher code will check that the code is
correctly delimiting between commit and path arguments.
Change-Id: I43e07d282fc3db86a1753fdbbfa395cdcc12727e
Change README to follow similar sections to allow partial inclusion of
pieces into sphinx generated docs to prevent duplication of same
information in multiple places.
Change-Id: I834d4dcf5d9e0bede3840812eb12e1d670421cc5
Where documentation is being moved about, corrections will be avoided
to allow for easier following of conversion separated from rewriting.
* Set up some simple documentation to describe basic details of
git-upstream and installation.
* Migrate details from README into dedicated subcommands rst doc.
* Consolidate installation instructions from USAGE into
installation rst page.
* Move remainder of USAGE into dedicated workflows rst and match the
existing markdown layout.
Change-Id: Ie73d64ae7cb0e96060729638da382c901d5d68e7
Read-the-docs requires the application module to be available via the
PYTHONPATH to build correctly as it does not install a virtualenv and
configuring it to do so results in it failing to find the custom
readthedocs sphinx builder.
Change-Id: Ic4a650fdbc8db1c8aeb7027121b3e0340d39b686