diff options
author | David Kalnischkies <kalnischkies@gmail.com> | 2011-01-20 16:01:40 +0100 |
---|---|---|
committer | David Kalnischkies <kalnischkies@gmail.com> | 2011-01-20 16:01:40 +0100 |
commit | 3cb3fe76e90283a5b3fe7105e4854d4bac13bfeb (patch) | |
tree | 773b6bbedbc9d122ebc21a84f9db680b93813f4f /ftparchive/writer.cc | |
parent | fe0f7911b650918e1d511b3453664a07f6d966d0 (diff) |
* ftparchive/writer.cc:
- add config option to search for more patterns in release command
Diffstat (limited to 'ftparchive/writer.cc')
-rw-r--r-- | ftparchive/writer.cc | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/ftparchive/writer.cc b/ftparchive/writer.cc index d7d699ddc..55fac89bd 100644 --- a/ftparchive/writer.cc +++ b/ftparchive/writer.cc @@ -306,7 +306,7 @@ PackagesWriter::PackagesWriter(string const &DB,string const &Overrides,string c Output = stdout; SetExts(".deb .udeb"); DeLinkLimit = 0; - + // Process the command line options DoMD5 = _config->FindB("APT::FTPArchive::MD5",true); DoSHA1 = _config->FindB("APT::FTPArchive::SHA1",true); @@ -907,16 +907,20 @@ bool ContentsWriter::ReadFromPkgs(string const &PkgFile,string const &PkgCompres /* */ ReleaseWriter::ReleaseWriter(string const &DB) { - AddPattern("Packages"); - AddPattern("Packages.gz"); - AddPattern("Packages.bz2"); - AddPattern("Packages.lzma"); - AddPattern("Sources"); - AddPattern("Sources.gz"); - AddPattern("Sources.bz2"); - AddPattern("Sources.lzma"); - AddPattern("Release"); - AddPattern("md5sum.txt"); + if (_config->FindB("APT::FTPArchive::Release::Default-Patterns", true) == true) + { + AddPattern("Packages"); + AddPattern("Packages.gz"); + AddPattern("Packages.bz2"); + AddPattern("Packages.lzma"); + AddPattern("Sources"); + AddPattern("Sources.gz"); + AddPattern("Sources.bz2"); + AddPattern("Sources.lzma"); + AddPattern("Release"); + AddPattern("md5sum.txt"); + } + AddPatterns(_config->FindVector("APT::FTPArchive::Release::Patterns")); Output = stdout; time_t const now = time(NULL); |