summaryrefslogtreecommitdiff
path: root/gbp
AgeCommit message (Collapse)Author
2013-09-16pq: Only print number or tries if we try more than onceGuido Günther
2013-09-16pq: print which patch failed to applyGuido Günther
2013-09-10GitRepository: deprecate the get_remote_repos methodMarkus Lehtonen
Superceded byt the get_remotes() method. Change-Id: I34f9e8b8188b5a40ce21d2f74e6068f2aaec9e60 Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-10GitRepository.has_remote_repo: use get_remotes methodMarkus Lehtonen
Use the new get_remotes() method Change-Id: Ic34cf590a6f36e6fa0af2ffbe932c8ae3a198944 Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-10git: new class and method for remote repositoriesMarkus Lehtonen
Add a new GitRemote class for representing git remote repositories. The initial, very limited, version only contains information about the fetch and push URLs of the remote repository. Also, add a new GitRepository.get_remotes() method for getting remote repositories as instances of the new GitRemote class. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-10GitRepository.pull: Add 'all_remotes' optionLingchaox Xin
Also changes the method to utilize the GitArgs class. Signed-off-by: Lingchaox Xin <lingchaox.xin@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-10GitRepository.push: Add 'tags' optionLingchaox Xin
Signed-off-by: Lingchaox Xin <lingchaox.xin@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-10GitRepository.push: Add 'force' optionLingchaox Xin
Signed-off-by: Lingchaox Xin <lingchaox.xin@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-10GitRepository.list_tree: add 'paths' optionMarkus Lehtonen
Change-Id: I9331fec6fcd0e58dad7cb4a571a683e09ce08011 Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-10GitRepository.diff: add 'ignore_submodules' optionMarkus Lehtonen
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-10common/buildpackage: fix handling of empty tarball prefixMarkus Lehtonen
Previously empty prefix in tarball generation introduced a leading slash in all filenames in the archive. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-05Remove unused importGuido Günther
2013-09-05GitRepository.diff: prevent usage of external diffMarkus Lehtonen
External diff might break patch generation, for example. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-05GitRepository.diff: add 'text' optionMarkus Lehtonen
For generating textual diffs. Useful for Pq - for example, the 'patch' utility does not support git binary diffs. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-04GitRepository: Add clean() methodMarkus Lehtonen
Signed-off-by: Lingchaox Xin <lingchaox.xin@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-04GitRepository.fetch: Add 'all_remotes' optionLingchaox Xin
Signed-off-by: Lingchaox Xin <lingchaox.xin@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-04GitRepository.fetch: Add 'refspec' optionLingchaox Xin
Signed-off-by: Lingchaox Xin <lingchaox.xin@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-04GitRepository.describe: add 'tags' and 'extra-match' optionsLingchaox Xin
Signed-off-by: Lingchaox Xin <lingchaox.xin@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-04GitRepository.has_treeish: minor pylint fixLingchaox Xin
Signed-off-by: Lingchaox Xin <lingchaox.xin@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-04import-orig: import readline in the common moduleMarkus Lehtonen
Useful common functionality. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-04GitRepository/diff: add 'stat' and 'summary' optionsMarkus Lehtonen
For getting diffstat and summary in the output. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-09-04config: restore mangled env in doctestsMarkus Lehtonen
Otherwise the mangled GBP_CONF_FILES affects also other doctests when run with python-nose. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-08-28Use open() instead of file()Guido Günther
since the later doesn't exist in python3
2013-08-24pq: exclude patches from Debian packaging branchGuido Günther
When regenerating the patch queue including patches from the Debian branch is not useful. Addresses parts of See #680705. Thanks: Benjamin Cama for the detailed analysis
2013-08-24GitRepository: allow to use '..' instead of '...'Guido Günther
The symmetric difference isn't always useful since it includes changes from both branches. See #680705.
2013-08-22Minor docstring updatesGuido Günther
2013-08-21dch: make automatic adding of new sections more robustGuido Günther
This code that determined if we found a snapshot header was obuscated by the code that determines the commits to add. Split those and better document their purpose. Also always return the commit to start from so we don't need to repeat the logic in the uper levels.
2013-07-04GitRepository.set_upstream_branch: use --set-upstream-to if availableGuido Günther
since --set-upstream is deprecated.
2013-07-04GitRepository.set_upstream_branch: Catch errors to set upstream branchGuido Günther
2013-07-04GitRepository.set_upstream_branch: don't try to set upstream twiceGuido Günther
Move setting of the upstream branch out of the loop. This worked by accident.
2013-06-29gbp.git.GitRepository.has_branch(): use _git_commandGuido Günther
instead of the deprecated _git_getoutput
2013-06-29gbp.git.Repository.get_branch(): use _git_commandGuido Günther
instead of the deprecated _git_inout and clarify the return codes and exceptions raised.
2013-06-29Git.Repository.__git_inout: Close all other file descriptorsGuido Günther
No need to leak fds to the child.
2013-06-29Git.Repository.__git_inout: properly set stdinGuido Günther
We should set stdin to subprocess.PIPE when piping input according to the subprocess docs.
2013-06-27Use has_keyGuido Günther
It's shorter and get's rid of the unused dummy variable.
2013-06-26import-dsc: print filename instead of object nameGuido Günther
2013-06-26config: Don't fill in the parser with all defaultsGuido Günther
There's no need to fill the parser with all the built in defaults since we can simply copy them to the config from the class dict. This allows us to first set the values from the old {git,gbp}-* commands and then only overwrite changed values from the newer "gbp <command>" versions. Otherwise we'd overwite all old style config with the new style one. This also fixes the problem where the default section wouldn't be read at all if the command doesn't even have an empty section in any gbp.conf file.
2013-06-26gbp-import-dscs: invoke gbp import-dscGuido Günther
instead of git-import-dsc
2013-06-26Consistently call gbp the supercommandGuido Günther
and robustify against invalid modules names.
2013-06-26gbp: support --helpGuido Günther
2013-06-19GbpOptionParser: Make sure we parse the old config sectionsGuido Günther
For backward compatibility between {gbp,git}-<subcommand> and "gbp <subcommand>" make sure we parse the former sections if using the later.
2013-06-19GbpOptionParser: Make sure we access the GbpOptionParser*'s default dictGuido Günther
and not the one from the OptionParser. The instance's default dict this gets reset to empty when invoking OptionParser.__init__.
2013-06-18Add wrapper for all gbp commandsGuido Günther
So like git you can now use gbp <command> instead of git-<command> or gbp-<command>. The manpages and docs aren't adjusted yet.
2013-06-13GitRepository/diff: allow single objectMarkus Lehtonen
Allow diffing a single object, e.g. getting diff from single commit. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-06-11Simplify expressionGuido Günther
Git-Dch: Ignore
2013-06-11GitRepository.get_subject: use get_commit_infoGuido Günther
This kills another _git_getoutput. Also deprecate the method since we don't need to special case the subject.
2013-06-11buildpackage: use get_commit_info() instead of get_subject()Markus Lehtonen
Utilize the get_commit_info() method of GitRepository instead of the deprecated get_subject(). Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-06-06import-orig: keep working copy in sync with branch HEADMarkus Lehtonen
Update working copy and index (to branch HEAD) if we modify the currently checked-out branch. Otherwise the repository is left in unclean state when the current branch is upstream or pristine-tar and the '--no-merge' option is used. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-06-06GitRepository/get_commit_info: add patchname to infoMarkus Lehtonen
Add a new 'patchname' field to the information returned by get_commit_info. That is, the subject in a sanitized format, similar to what git-format-patch uses. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-06-06gitmodifier: make the datetime object always have timezoneMarkus Lehtonen
To be consistent with the date property and for easier compatibility with git dates. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>