summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2012-11-27GitRepository/strip_sha1: fix length checkingMarkus Lehtonen
Accept longer sha1 than what was asked for. The length option given to git is merely a "wish to get a sha1 of this length". Git may also return longer sha1 if truncating to given length would give ambiguous/non-unique sha1. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-25git-dch: Allow to create changelogs when not on a branchGuido Günther
This makes snapshot changelog generation e.g. within jenkins builds simpler since jenkins by defaults checkouts out the commit without creating a branch.
2012-11-25gbp-create-remote-repo: Set HEAD in remote repoGuido Günther
to debian branch Closes: #692006
2012-11-25gbp.log: Improve error message on broken color listsGuido Günther
2012-11-25New configuration option for setting the output color schemeMarkus Lehtonen
Adds a new command line and config file option 'color-scheme' for selecting the colors used in log output. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-25log: add support for setting the color schemeMarkus Lehtonen
Implements changeable color schemes in the gbp.log module. Color scheme is given as a colon-separated list, with one color for each log level: '<debug_color>:<info_color>:<warning_colro>:<error_color>'. Colors can be given as an integer number (ANSI terminal color code) or color name (.e.g 'red'). Missing or empty fields are interpreted as using the default color for that log level. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-25gbp.log: lowercase the levelnameGuido Günther
too match the output before the switch to Python's logging module
2012-11-25log: rewrite the module to use Python logging moduleMarkus Lehtonen
Replaces the Logger with a new one, derived from the Logger class of the Python standard library. Colorized output is handled by a separate handler class. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-25gbp-pq: Improve patch header write outGuido Günther
Avoid trailing new lines in the patch header when reexporing patches. to avoid diffs when nothing changed.
2012-11-25Ignore rope project filesGuido Günther
as generated by ropemacs
2012-11-24Document changes and release 0.6.0~git20121124Guido Günther
2012-11-24git-import-dscs: Properly catch import errorsGuido Günther
Closes: #694113
2012-11-24Remove unused imports and adjust formattingGuido Günther
Git-Dch: Ignore
2012-11-24gbp-pq: don't use plural form when there's only one try leftGuido Günther
2012-11-24GitRepository/has_submodules: use correct .gitmodules fileMarkus Lehtonen
Examine .gitmodules from the "root directory" of the repo, not the current working directory. Fixes has_submodules() method, when called from arbitrary cwd. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-24GitRepository/get_commit_info: support tagsMarkus Lehtonen
Dereference the given revision to a commit. Fixes get_commit_info() when called for a tag. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-24Test gbp.pq.common.write_patchGuido Günther
2012-11-24Output test results in xunit format tooGuido Günther
2012-11-23GitRepository/get_submodules: use correct pathMarkus Lehtonen
By default, run git in the repo path, not current cwd. Also, now returns submodule paths without leading './'. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-23GitRepository/get_commits: more flexible revision rangesMarkus Lehtonen
Support getting the complete history of an arbitrary commit-ish (since=None, until=COMMIT-ISH). Formerly this was only possible for the current git HEAD. Now, get_commits(since=None, until='COMMIT') translates to 'git log COMMIT'. Also, for consistency, add support for getting the history from an arbitrary commit until the current HEAD (since=COMMIT-ISH, until=None). Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-23import-orig: remove dead GbpNothingImported exceptionMarkus Lehtonen
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-23import-orig: remove dead if statementMarkus Lehtonen
GitRepository.commit_dir() never returns empty objects. It raises an exception, instead. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-23Add sha1 stripping in a single placeGuido Günther
so we can easily sanity check the result.
2012-11-23Test if setting a topic worksGuido Günther
2012-11-23pq: Allow to pass in custom fucntion to fetch authorship informationGuido Günther
so the RPM based tools don't need to rely on a control file but can e.g. look at the spec file.
2012-11-23Test apply_and_commit_patchGuido Günther
2012-11-23Use an absolute path when parsing the control fileGuido Günther
so we con't accidentally parse a file from another dir.
2012-11-23testutils: create missing directories when adding a fileGuido Günther
2012-11-23pq: fix "no authorship" warning messagesMarkus Lehtonen
Add one missing string field. Show the patch filename instead of the pull path - the user doesn't need to know if the patch was applied from a temporary directory, for example. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-23tests: make tests a Python moduleMarkus Lehtonen
Makes it possible to reuse code between various tests. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-23notifications.py: remove unused importMarkus Lehtonen
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-23command_wrappers: suppress some pylint warningsMarkus Lehtonen
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-23Add issing git- prefix to --color and --notify optionsGuido Günther
Thanks: Filippo Rusconi Closes: #693978
2012-11-08Remove unused importGuido Günther
2012-11-08Minor git-import-orig manpage improvementsGuido Günther
2012-11-08GbpError accepts an error messageGuido Günther
so no need to print it separately
2012-11-08Allow to remove the orig tarball symlinkGuido Günther
that's used make pristine-tar see the correct orig tarball name. Closes: #692401
2012-11-07GitRepository/diff: catch git errorMarkus Lehtonen
Raise an exception if the git command fails. Also, utilize _git_inout() instead of the deprecated _git_getoutput(). Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-07GitRepository/diff: add 'paths' argumentMarkus Lehtonen
Makes the diff function more versatile. I.e. makes diffing only certain paths possible. Also, add basic unittests for the diff() method. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-07GitRepository.find_tag: change deprecated _git_getoutput to _git_inoutEd Bartosh
Signed-off-by: Ed Bartosh <eduard.bartosh@intel.com> Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-07GitRepository: fix merge() for older git versionsMarkus Lehtonen
Utilize _cmd_has_feature() in GitRepository.merge() to not give edit/no-edit option for older versions of git-merge, that don't support it. Fixes a regression (with git-version < 1.7.8) caused by commit f3aa87fa0361a. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-07GitRepository: implement _cmd_has_feature() methodMarkus Lehtonen
This method is intended for checking if the local git (client) command supports a certain feature. The "feature" is considered to be a command line option. E.g. does "merge" command have the "edit" feature translates to does git-merge support the '--edit' command line option. To figure this out, _cmd_has_feature() parses through the "OPTIONS" section of the man page of the git command. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-11-04Fix testsuite failure if DEB_VENDOR != DebianDmitrijs Ledkovs
The package fails to build from source if the DEB_VENDOR is not Debian, as the test output from git-dch expects Debian distribution specific behaviour. You can see the failed build log with DEB_VENDOR=Ubuntu here: https://launchpadlibrarian.net/121690052/buildlog_ubuntu-raring-i386.git-buildpackage_0.6.0~git20120822_FAILEDTOBUILD.txt.gz Closes: #692289 Signed-off-by: Guido Günther <agx@sigxcpu.org>
2012-10-25Print number of tries leftGuido Günther
2012-10-25Add support dch's --security optionGuido Günther
2012-10-25PEP-8 and pyflakes cleanupsGuido Günther
2012-08-26Add debian/source/format parserGuido Günther
2012-08-22Document changes and release 0.6.0~git20120822Guido Günther
2012-08-22GitArgs/add: support iterable and non-string argsMarkus Lehtonen
Support giving iterables (other than basestring, e.g. list(s)) as an argument to GitArgs.add(). Also, add support non-iterable arguments that support the str() conversion. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-08-22GitRepository: Implement set_upstream_branch and get_upstream_branch methodsEd Bartosh
set_upstream_branch sets upstream branch for the local branch using git branch --set-upstream get_upstream_branch returns info about upstream branches Signed-off-by: Ed Bartosh <eduard.bartosh@intel.com>