summaryrefslogtreecommitdiff
path: root/gbp/pkg
AgeCommit message (Collapse)Author
2015-03-27Don't let pristine-tar spew on stderrGuido Günther
Capture its output and only dump it on failure. This makes "gbp import-orig" and test runs less verbose.
2015-03-27command_wrapper: Make error reporting more flexibleGuido Günther
We allow to substitute stderr, stdout and error_reason in run_error now. These changes the API for derived classses slightly so fix them up as well.
2015-03-26Remove unused variableGuido Günther
Git-Dch: Ignore
2015-02-20UpstreamSource.guess_version: recognise debian native tarballsMarkus Lehtonen
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2015-02-20Use six.iteritems() and six.iterkeys()Guido Günther
to work towards Python3 support Gbp-Dch: Ignore
2015-01-22pristinetar: fix docstringGuido Günther
Gbp-Dch: Ignore
2014-07-24Make pychecker happyGuido Günther
We don't use the class variable anywhere
2014-07-24UpstreamSource: move version guessing logic to PkgPolicyMarkus Lehtonen
PkgPolicy is more logical context, for example if guessing version from a plain filename and not a real file. Also, changes guess_version() to always return a tuple to simplify checking its return value. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Conflicts: gbp/pkg/__init__.py
2014-07-24Change UpstreamSource to have PkgPolicyMarkus Lehtonen
The UpstreamSource class now gets a PkgPolicy in it's initialization. Also, introduces new DebiaUpstreamSource class which is taken in use in the scripts. The PkgPolicy is not yet used for anything in UpstreamSource. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2014-07-24UpstreamSource.guess_version: don't check for directoriesMarkus Lehtonen
Directories are not recognized anyway, if guess_version() is called for non-existent sources. And, parse_archive_filename() works fine for directory names, too. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2014-07-24UpstreamSource/guess_version: detect more compression formatsMarkus Lehtonen
By utilizing the parse_archive_filename() function that detects e.g. "alias suffixes" such as 'tgz'. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2014-07-24Fix typosGuido Günther
2014-07-24Move get_compression() out of pkg.PkgPolicy classMarkus Lehtonen
Renames the function to parse_archive_filename() and changes it's return values. Filename parsing is merely generic functionality, not tied to any packaging policy. The function now returns the base name of the file (that is, filename without, archive and compression extensions), archive format and compression method. Adds supported archive formats 'tar' and 'zip' and file extension aliases, e.g. 'tgz'. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2013-03-22Better document how one derives from PkgTypesGuido Günther
2013-03-22Return boolean types from is_ methodsGuido Günther
instead of a match object or None
2013-03-22Remove unused importsGuido Günther
2012-07-02Make exception syntax consistentGuido Günther
2012-06-30PristineTar: move Debian-specific stuff to DebianPristineTarMarkus Lehtonen
Continuation to the PristineTar refactoring, makes the "common" PristineTar independent of DebianPkgPolicy. This commit moves the Debian-specific has_commit() and checkout() methods to DebianPristineTar class and replaces them with more generic functions in the base class. Also, drops the Debian-specific get_commit() method completely, as it was not used outside the PristineTar class itself. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
2012-06-25UpstreamSource: automatically detect package name and versions from directoriesGuido Günther
of the form packagename-<version>
2012-05-25Refactor deb helpers: move PristineTar classGuido Günther
Based on a patch by Markus Lehtonen This refactor is preparation to the upcoming rpm support.
2012-05-01Refactor deb helpers: move UpstreamSource classMarkus Lehtonen
to pkg base module. This refactor is preparation to the upcoming rpm support.
2012-05-01Refactor deb helpers: introduce PkgPolicy classMarkus Lehtonen
Create a new 'pkg' basemodule, intended to be re-used by the upcoming rpm package helpers. Move some deb functionality to a new pkg.PkgPolicy class, to be used as a base for different package types. Introduces Deb-specific deb.DebianPkgPolicy.