From: Luca Falavigna Date: Mon, 29 Apr 2013 12:33:31 +0000 (+0000) Subject: Use changelog export path derived from projectb X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0b9068dfabb27498d868e61b9b7da0b9ecfc1349;p=dak Use changelog export path derived from projectb --- diff --git a/dak/make_changelog.py b/dak/make_changelog.py index 2d52d069..b904deaa 100755 --- a/dak/make_changelog.py +++ b/dak/make_changelog.py @@ -57,7 +57,6 @@ from shutil import rmtree from yaml import safe_dump from daklib.dbconn import * from daklib import utils -from daklib.config import Config from daklib.contents import UnpackedSource from daklib.regexes import re_no_epoch @@ -293,7 +292,6 @@ def generate_export_filelist(clpool): def main(): Cnf = utils.get_conf() - cnf = Config() Arguments = [('h','help','Make-Changelog::Options::Help'), ('a','archive','Make-Changelog::Options::Archive','HasArg'), ('s','suite','Make-Changelog::Options::Suite','HasArg'), @@ -324,9 +322,9 @@ def main(): session = DBConn().session() if export: - if cnf.exportpath: - archive = session.query(Archive).filter_by(archive_name=Options['Archive']).one() - exportpath = os.path.join(Cnf['Dir::Export'], cnf.exportpath) + (archive, exportpath) = session.query(Archive.archive_name, Archive.changelog). \ + filter_by(archive_name=Options['Archive']).one() + if exportpath: export_files(session, archive, exportpath, progress) generate_export_filelist(exportpath) else: