]> git.decadent.org.uk Git - dak.git/commitdiff
sync
authorJames Troup <james@nocrew.org>
Sat, 27 Jan 2001 00:09:36 +0000 (00:09 +0000)
committerJames Troup <james@nocrew.org>
Sat, 27 Jan 2001 00:09:36 +0000 (00:09 +0000)
14 files changed:
THANKS
apt.conf
apt.conf-non-US
apt.conf.stable [new file with mode: 0644]
apt.conf.stable-non-US [new file with mode: 0644]
docs/katie.1.sgml [new file with mode: 0644]
docs/katie.ent
docs/natalie.1.sgml [new file with mode: 0644]
katie
katie.conf
katie.conf-non-US
natalie.py
vars
vars-non-US

diff --git a/THANKS b/THANKS
index 4f64b130820551a7745a1399a6b761029a7a773e..7ac86047e752773dab0e37870dc7712bcd5d5831 100644 (file)
--- a/THANKS
+++ b/THANKS
@@ -8,6 +8,7 @@ Anthony Towns                  <ajt@debian.org>
 Antti-Juhani Kaijanaho        <ajk@debian.org>
 Ben Collins                   <bcollins@debian.org>
 Brendan O'Dea                 <bod@debian.org>
+Brian May                     <bam@debian.org>
 Brian Russo                   <wolfie@debian.org>
 Chris Leishman                <masklin@debian.org>
 Daniel Jacobwitz              <dan@debian.org>
index 214fd1ead71c564923e5052c6874a74434d8f0f0..3d9a1bff8761e5d579e29f45e0d5fcac97c3cd20 100644 (file)
--- a/apt.conf
+++ b/apt.conf
@@ -20,16 +20,6 @@ TreeDefault
    Contents::Header "/org/ftp.debian.org/katie/Contents.top";
 };
 
-tree "dists/stable"
-{
-   FileList "/org/ftp.debian.org/database/dists/stable_$(SECTION)_binary-$(ARCH).list";
-   SourceFileList "/org/ftp.debian.org/database/dists/stable_$(SECTION)_source.list";
-   Sections "main contrib non-free";
-   Architectures "alpha arm i386 m68k powerpc sparc source";
-   BinOverride "override.potato.$(SECTION)";
-   SrcOverride "override.potato.$(SECTION).src";
-};
-
 tree "dists/testing"
 {
    FileList "/org/ftp.debian.org/database/dists/testing_$(SECTION)_binary-$(ARCH).list";
index f6e3df6685239c9cb3c4aa11a9d7d1c8452e4c53..8bc0d7bcc3f1bfe3b36de577b80d0dbb2040e165 100644 (file)
@@ -20,17 +20,6 @@ TreeDefault
    Contents::Header "/org/non-us.debian.org/katie/Contents.top";
 };
 
-tree "dists/stable/non-US"
-{
-   FileList "/org/non-us.debian.org/database/dists/stable_non-us/$(SECTION)_binary-$(ARCH).list";
-   SourceFileList "/org/non-us.debian.org/database/dists/stable_non-us/$(SECTION)_source.list";
-   Sections "main contrib non-free";
-   Architectures "alpha arm i386 m68k powerpc sparc source";
-   BinOverride "override.potato.$(SECTION)";
-   SrcOverride "override.potato.$(SECTION).src";
-   External-Links false;
-};
-
 tree "dists/testing/non-US"
 {
    FileList "/org/non-us.debian.org/database/dists/testing_non-us/$(SECTION)_binary-$(ARCH).list";
diff --git a/apt.conf.stable b/apt.conf.stable
new file mode 100644 (file)
index 0000000..b17f062
--- /dev/null
@@ -0,0 +1,31 @@
+Dir 
+{
+   ArchiveDir "/org/ftp.debian.org/ftp/";
+   OverrideDir "/org/ftp.debian.org/scripts/override/";
+   CacheDir "/org/ftp.debian.org/database/";
+};
+
+Default
+{
+   Packages::Compress ". gzip";
+   Sources::Compress "gzip";
+   Contents::Compress "gzip";
+   DeLinkLimit 0;
+   MaxContentsChange 6000;
+   FileMode 0664;
+}
+
+TreeDefault
+{
+   Contents::Header "/org/ftp.debian.org/katie/Contents.top";
+};
+
+tree "dists/stable"
+{
+   FileList "/org/ftp.debian.org/database/dists/stable_$(SECTION)_binary-$(ARCH).list";
+   SourceFileList "/org/ftp.debian.org/database/dists/stable_$(SECTION)_source.list";
+   Sections "main contrib non-free";
+   Architectures "alpha arm i386 m68k powerpc sparc source";
+   BinOverride "override.potato.$(SECTION)";
+   SrcOverride "override.potato.$(SECTION).src";
+};
diff --git a/apt.conf.stable-non-US b/apt.conf.stable-non-US
new file mode 100644 (file)
index 0000000..494c61d
--- /dev/null
@@ -0,0 +1,32 @@
+Dir 
+{
+   ArchiveDir "/org/non-us.debian.org/ftp/";
+   OverrideDir "/org/non-us.debian.org/scripts/override/";
+   CacheDir "/org/non-us.debian.org/database/";
+};
+
+Default
+{
+   Packages::Compress ". gzip";
+   Sources::Compress "gzip";
+   Contents::Compress "gzip";
+   DeLinkLimit 0;
+   MaxContentsChange 6000;
+   FileMode 0664;
+}
+
+TreeDefault
+{
+   Contents::Header "/org/non-us.debian.org/katie/Contents.top";
+};
+
+tree "dists/stable/non-US"
+{
+   FileList "/org/non-us.debian.org/database/dists/stable_non-us/$(SECTION)_binary-$(ARCH).list";
+   SourceFileList "/org/non-us.debian.org/database/dists/stable_non-us/$(SECTION)_source.list";
+   Sections "main contrib non-free";
+   Architectures "alpha arm i386 m68k powerpc sparc source";
+   BinOverride "override.potato.$(SECTION)";
+   SrcOverride "override.potato.$(SECTION).src";
+   External-Links false;
+};
diff --git a/docs/katie.1.sgml b/docs/katie.1.sgml
new file mode 100644 (file)
index 0000000..8ea23bf
--- /dev/null
@@ -0,0 +1,116 @@
+<!-- -*- mode: sgml; mode: fold -*- -->
+<!doctype refentry PUBLIC "-//OASIS//DTD DocBook V3.1//EN" [
+
+<!ENTITY % katieent SYSTEM "katie.ent">
+%katieent;
+
+]>
+
+<refentry>
+  &katie-docinfo;
+  
+  <refmeta>
+    <refentrytitle>katie</>
+    <manvolnum>1</>
+  </refmeta>
+  
+  <!-- Man page title -->
+  <refnamediv>
+    <refname>katie</>
+    <refpurpose>Installs packages from incoming</>
+  </refnamediv>
+
+  <!-- Arguments -->
+  <refsynopsisdiv>
+    <cmdsynopsis>
+      <command>katie</>
+      <arg><option><replaceable>options</replaceable></></arg>
+      <arg choice="plain"><replaceable>package</replaceable></arg>
+      <arg><option><replaceable>...</replaceable></option></arg>
+    </cmdsynopsis>
+  </refsynopsisdiv>
+  
+  <RefSect1><Title>Description</>
+    <para>   
+      <command>katie</command> is the program which installs packages from incoming into the distribution.
+    </PARA></REFSECT1>
+
+  <RefSect1><Title>Options</>
+    
+    <VariableList>
+
+      <varlistentry>
+       <term><option>-a/--automatic</option></term>
+       <listitem>
+         <para>Run automatically; i.e. perform the default action if it's possible to do so without user interaction.  Intend for use in cron jobs and the like.</para>
+       </listitem>
+      </varlistentry>
+
+      <varlistentry>
+       <term><option>-h/--help</option></term>
+       <listitem>
+         <para>Display usage help and then exit.</para>
+       </listitem>
+      </varlistentry>
+
+      <varlistentry>
+       <term><option>-k/--ack-new</option></term>
+       <listitem>
+         <para>Acknowledge new packages.  <emphasis>WARNING:</emphasis> due to the sub-optimal implementation of new packages, this option should only be used when processing *all* packages (e.g. in cron jobs).</para>
+       </listitem>
+      </varlistentry>
+
+      <varlistentry>
+       <term><option>-m/--manual-reject=<replaceable>message</replaceable></option></term>
+       <listitem>
+         <para>Perform a manual rejection of the package.  The <replaceable>message</replaceable> is included in the rejection notice sent to the uploader.  If no <replaceable>message</replaceable> is given, an editor will be spawned so one can be added to the rejection notice.
+       </listitem>
+      </varlistentry>
+
+      <varlistentry>
+       <term><option>-n/--no-action</option></term>
+       <listitem>
+         <para>Don't actually install anything; just show what would be done.</para>
+       </listitem>
+      </varlistentry>
+
+      <varlistentry>
+       <term><option>-p/--no-lock</option></term>
+       <listitem>
+         <para>Don't check the lockfile.  Obviously dangerous and should only be used for cron jobs (if at all).</para>
+       </listitem>
+      </varlistentry>
+
+      <varlistentry>
+       <term><option>-u/--distribution=<replaceable>distribution</replaceable></option></term>
+       <listitem>
+         <para>Override the <literal>Distribution</Literal> field.  Should only be used for binary packages otherwise if used on a source package, all binary recompiles of that source will require a similar manual override.</para>
+       </listitem>
+      </varlistentry>
+
+      <varlistentry>
+       <term><option>-v/--version</option></term>
+       <listitem>
+         <para>Display the version number and then exit.</para>
+       </listitem>
+      </varlistentry>
+
+    </VariableList>
+  </RefSect1>
+
+  <RefSect1><Title>Diagnostics</>
+    <para>
+      <command>katie</command> returns zero on normal operation, non-zero on error.
+    </PARA>
+  </RefSect1>
+
+  <refsect1>
+    <title>Acknowledgements</title>
+    <para>katie is based very heavily on dinstall, written by Guy Maor <email>maor@debian.org</email>; in fact it started out life as a dinstall clone.</para>
+  </refsect1>
+
+  &manauthor;
+
+
+  
+</refentry>
index b7abf4d9cea9ae2520d1ac578a474e3a4491cb68..2c3522996c2adb521d5ff29065ce20f183efa3b9 100644 (file)
@@ -3,17 +3,18 @@
 <!-- Boiler plate docinfo section -->
 <!ENTITY katie-docinfo "
  <docinfo>
-   <address><email>james@nocrew.org</></address>
-   <author><firstname>James</> <surname>Troup</></>
-   <copyright><year>2000-2001</> <holder>James Troup</></>
-   <date>15 January 2001</>
+   <address><email>james@nocrew.org</email></address>
+   <author><firstname>James</firstname> <surname>Troup</surname></author>
+   <copyright><year>2000-2001</year> <holder>James Troup</holder></copyright>
+   <date>15 January 2001</date>
  </docinfo>
 "> 
 
 <!-- Boiler plate Author section -->
 <!ENTITY manauthor "
- <RefSect1><Title>Author</>
+ <RefSect1><Title>Author</title>
    <para>
-   katie was written by James Troup <email>james@nocrew.org</>.
+   katie was written by James Troup <email>james@nocrew.org</email>.
+   </para>
  </RefSect1>
 ">
diff --git a/docs/natalie.1.sgml b/docs/natalie.1.sgml
new file mode 100644 (file)
index 0000000..388f6f2
--- /dev/null
@@ -0,0 +1,74 @@
+<!-- -*- mode: sgml; mode: fold -*- -->
+<!doctype refentry PUBLIC "-//OASIS//DTD DocBook V3.1//EN" [
+
+<!ENTITY % katieent SYSTEM "katie.ent">
+%katieent;
+
+]>
+
+<refentry>
+  &katie-docinfo;
+  
+  <refmeta>
+    <refentrytitle>natalie</>
+    <manvolnum>1</>
+  </refmeta>
+  
+  <!-- Man page title -->
+  <refnamediv>
+    <refname>natalie</>
+    <refpurpose>Override Utility to remove/add packages from suites</>
+  </refnamediv>
+
+  <!-- Arguments -->
+  <refsynopsisdiv>
+    <cmdsynopsis>
+      <command>natalie</>
+      <arg><option><replaceable>options</replaceable></></arg>
+    </cmdsynopsis>
+  </refsynopsisdiv>
+  
+  <RefSect1><Title>Description</>
+    <para>   
+      <command>natalie</command> is the command line tool to handle override files.  Override files can be listed to stdout or updated from stdin.
+
+  <RefSect1><Title>Options</>
+    
+      <VariableList>
+       <VarListEntry><term><option>-c/--component=<replaceable>component</replaceable></option></>
+         <ListItem><Para>Uses the override DB for the component listed.  The default is <literal>main</literal>.</PARA></LISTITEM>
+       </VarListEntry>
+       
+       <varlistentry>
+         <term><option>-l/--list</option></term>
+         <listitem>
+           <para>Lists the override DB to stdout.</para>
+         </listitem>
+       </varlistentry>
+
+       <VarListEntry><term><option>-s/--suite=<replaceable>suite</replaceable></option></>
+         <ListItem><Para>Uses the override DB for the suite listed.  The default is <literal>unstable</literal>.</PARA></LISTITEM>
+       </VarListEntry>
+       
+       <VarListEntry><term><option>-S/--set</option></term>
+         <ListItem><Para>Update the override DB based on the contents of stdin.  Information on the results of the update are printed to stdout.</PARA></LISTITEM>
+       </VarListEntry>
+       
+       <varlistentry>
+         <term><option>-t/--type=<replaceable>type</replaceable></option></term>
+         <listitem>
+           <para>Uses the override DB for the type listed.  The default is <literal>deb</literal>.  Possible values are: <literal>deb</literal>, <literal>udeb</literal> and <literal>dsc</literal>.</para>
+         </listitem>
+       </varlistentry>
+
+    </VariableList>
+  </RefSect1>
+
+  <RefSect1><Title>Diagnostics</>
+    <para>
+      <command>natalie</command> returns zero on normal operation, non-zero on error.
+  </RefSect1>
+
+  &manauthor;
+  
+</refentry>
diff --git a/katie b/katie
index 5596586d14d3a0042ff50160c64a88c66232096a..1c611a7eb634583bd77afa2b448659811081379c 100755 (executable)
--- a/katie
+++ b/katie
@@ -2,7 +2,7 @@
 
 # Installs Debian packaes
 # Copyright (C) 2000  James Troup <james@nocrew.org>
-# $Id: katie,v 1.22 2001-01-23 20:27:35 troup Exp $
+# $Id: katie,v 1.23 2001-01-27 00:09:36 troup Exp $
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -91,13 +91,14 @@ legacy_source_untouchable = {};
 def usage (exit_code):
     print """Usage: dinstall [OPTION]... [CHANGES]...
   -a, --automatic           automatic run
-  -d, --debug=VALUE         debug
-  -k, --ack-new             acknowledge new packages
+  -D, --debug=VALUE         turn on debugging
+  -h, --help                show this help and exit.
+  -k, --ack-new             acknowledge new packages !! for cron.daily only !!
   -m, --manual-reject=MSG   manual reject with `msg'
   -n, --no-action           don't do anything
   -p, --no-lock             don't check lockfile !! for cron.daily only !!
-  -r, --no-version-check    override version check
-  -u, --distribution=DIST   override distribution to `dist'"""
+  -u, --distribution=DIST   override distribution to `dist'
+  -v, --version             display the version number and exit"""
     sys.exit(exit_code)
 
 def check_signature (filename):
@@ -178,7 +179,7 @@ def check_changes(filename):
     # Check for mandatory fields
     for i in ("source", "binary", "architecture", "version", "distribution","maintainer", "files"):
         if not changes.has_key(i):
-            reject_message = "Rejected: Missing field `%s' in changes file." % (i)
+            reject_message = "Rejected: Missing field `%s' in changes file.\n" % (i)
             return 0    # Avoid <undef> errors during later tests
 
     # Fix the Maintainer: field to be RFC822 compatible
@@ -397,11 +398,7 @@ def check_files():
                     files[file]["oldfiles"][suite] = oldfile
                     # Check versions [NB: per-suite only; no cross-suite checking done (yet)]
                     if apt_pkg.VersionCompare(files[file]["version"], oldfile["version"]) != 1:
-                        if Cnf["Dinstall::Options::No-Version-Check"]:
-                            reject_message = reject_message + "Overriden rejection"
-                        else:
-                            reject_message = reject_message + "Rejected"
-                        reject_message = reject_message + ": %s Old version `%s' >= new version `%s'.\n" % (file, oldfile["version"], files[file]["version"])
+                        reject_message = reject_message + "Rejected: %s Old version `%s' >= new version `%s'.\n" % (file, oldfile["version"], files[file]["version"])
                 # Check for existing copies of the file
                 if not changes.has_key("stable upload"):
                     q = projectB.query("SELECT b.id FROM binaries b, architecture a WHERE b.package = '%s' AND b.version = '%s' AND a.arch_string = '%s' AND a.id = b.architecture" % (files[file]["package"], files[file]["version"], files[file]["architecture"]))
@@ -545,7 +542,7 @@ def check_dsc ():
                             reject_message = reject_message + "Rejected: %s refers to %s, but I can't find it in Incoming or in the pool.\n" % (file, dsc_file);
                             continue;
                 else:
-                    reject_message = reject_message + "Rejected: %s refers to %s, but I can't find it in Incoming." % (file, dsc_file);
+                    reject_message = reject_message + "Rejected: %s refers to %s, but I can't find it in Incoming.\n" % (file, dsc_file);
                     continue;
                 if actual_md5 != dsc_files[dsc_file]["md5sum"]:
                     reject_message = reject_message + "Rejected: md5sum for %s doesn't match %s.\n" % (found, file);
@@ -606,6 +603,9 @@ def check_override ():
             section = files[file]["section"];
             override_section = files[file]["override section"];
             if section != override_section and section != "-":
+                # Ignore this; it's a common mistake and not worth whining about
+                if section == "non-US/main" and override_section == "non-US":
+                    continue;
                 summary = summary + "%s: section is overridden from %s to %s.\n" % (file, section, override_section);
             if files[file]["type"] == "deb": # don't do priority for source
                 priority = files[file]["priority"];
@@ -981,8 +981,8 @@ def reject (changes_filename, manual_reject_mail_filename):
         if os.path.exists(file):
             try:
                 utils.move (file, "%s/REJECT/%s" % (Cnf["Dir::IncomingDir"], file));
-            except utils.cant_overwrite_exc:
-                sys.stderr.write("W: couldn't overwrite existing file '%s/REJECT/%s" % (Cnf["Dir::IncomingDir"], file));
+            except:
+                sys.stderr.write("W: couldn't reject file '%s' [Got %s].\n" % (file, sys.exc_type);
                 pass;
 
     # If this is not a manual rejection generate the .reason file and rejection mail message
@@ -1186,15 +1186,16 @@ non-maintainer upload.  The .changes file follows.
 def process_it (changes_file):
     global reprocess, orig_tar_id, changes, dsc, dsc_files, files;
 
-    reprocess = 1;
-    orig_tar_id = None;
     # Reset some globals
+    reprocess = 1;
     changes = {};
     dsc = {};
     dsc_files = {};
     files = {};
     orig_tar_id = None;
     legacy_source_untouchable = {};
+    reject_message = "";
+    orig_tar_id = None;
 
     # Absolutize the filename to avoid the requirement of being in the
     # same directory as the .changes file.
@@ -1235,7 +1236,6 @@ def main():
                  ('m',"manual-reject","Dinstall::Options::Manual-Reject", "HasArg"),
                  ('n',"no-action","Dinstall::Options::No-Action"),
                  ('p',"no-lock", "Dinstall::Options::No-Lock"),
-                 ('r',"no-version-check", "Dinstall::Options::No-Version-Check"),
                  ('s',"no-mail", "Dinstall::Options::No-Mail"),
                  ('u',"override-distribution", "Dinstall::Options::Override-Distribution", "HasArg"),
                  ('v',"version","Dinstall::Options::Version")];
@@ -1282,7 +1282,6 @@ def main():
 
     # Process the changes files
     for changes_file in changes_files:
-        reject_message = ""
         print "\n" + changes_file;
         process_it (changes_file);
 
index c665c91208acfb0299f4ec1cd17332a084f557c7..633ce2996955ce69efde3509847c45db1d0cb893 100644 (file)
@@ -9,7 +9,6 @@ Dinstall
         Manual-Reject "";
         No-Action "";
         No-Lock "";
-        No-Version-Check "";
         No-Mail "";
         Override-Distribution "";
         Version "";
index b90ef3619c2eefc8c2b49d0463cf962c782ccce5..45d561fe0ce2e2e73f75d52286e1952a435e422b 100644 (file)
@@ -9,7 +9,6 @@ Dinstall
         Manual-Reject "";
         No-Action "";
         No-Lock "";
-        No-Version-Check "";
         No-Mail "";
         Override-Distribution "";
         Version "";
index 8206ddfe8715705457f1432def9614a9559fe1e7..e92d6d7d676bdc97355ea7d19a4740ceedbf41db 100755 (executable)
@@ -2,7 +2,7 @@
 
 # Manipulate override files
 # Copyright (C) 2000  James Troup <james@nocrew.org>
-# $Id: natalie.py,v 1.1 2001-01-10 05:58:26 troup Exp $
+# $Id: natalie.py,v 1.2 2001-01-27 00:09:36 troup Exp $
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -31,6 +31,25 @@ projectB = None;
 
 ################################################################################
 
+def usage (exit_code):
+    print """Usage: natalie.py [OPTIONS]
+  -D, --debug=VALUE        debug
+  -h, --help               this help
+  -V, --version            retrieve version
+  -c, --component=CMPT     list/set overrides by component
+                                  (contrib,*main,non-free)
+  -s, --suite=SUITE        list/set overrides by suite 
+                                  (experimental,stable,testing,*unstable)
+  -t, --type=TYPE          list/set overrides by type
+                                  (*deb,dsc,udeb)
+  -S, --set                set overrides from stdin
+  -l, --list               list overrides on stdout
+
+ starred (*) values are default"""
+    sys.exit(exit_code)
+
+################################################################################
+
 def init():
     global projectB;
     
@@ -194,6 +213,9 @@ def main ():
                  ('t',"type","Natalie::Options::Type", "HasArg")];
     file_list = apt_pkg.ParseCommandLine(Cnf,Arguments,sys.argv);
 
+    if Cnf["Natalie::Options::Help"]:
+        usage(0);
+
     init();
 
     action = None;
diff --git a/vars b/vars
index c166ff7fbe50f5f6c942bd205c9ee0152ed059ab..053f34f1d48f57252932b6d74b9b4239217266df 100644 (file)
--- a/vars
+++ b/vars
@@ -11,7 +11,7 @@ overridedir=$scriptdir/override
 
 incoming=/org/ftp.debian.org/incoming
 
-copyoverrides="potato.contrib potato.contrib.src potato.main potato.main.src potato.non-free potato.non-free.src sid.contrib sid.contrib.src sid.main sid.main.debian-installer sid.main.src sid.non-free sid.non-free.src testing.contrib testing.contrib.src testing.main testing.main.src testing.non-free testing.non-free.src"
+copyoverrides="potato.contrib potato.contrib.src potato.main potato.main.src potato.non-free potato.non-free.src sid.contrib sid.contrib.src sid.main sid.main.debian-installer sid.main.src sid.non-free sid.non-free.src woody.contrib woody.contrib.src woody.main woody.main.src woody.non-free woody.non-free.src"
 
 PATH=$masterdir:$PATH
 umask 022
index 291cec96ba4eed1dea099de28e0628b63669bb91..d8310c97ba6e613713c202c67851db56c63e68f2 100644 (file)
@@ -14,7 +14,7 @@ packagesfiles=packagesfiles-non-US
 sourcesfiles=sourcesfiles-non-US
 contentsfiles=contentsfiles-non-US
 
-copyoverrides="potato.contrib potato.contrib.src potato.main potato.main.src potato.non-free potato.non-free.src sid.contrib sid.contrib.src sid.main sid.main.src sid.non-free sid.non-free.src testing.contrib testing.contrib.src testing.main testing.main.src testing.non-free testing.non-free.src"
+copyoverrides="potato.contrib potato.contrib.src potato.main potato.main.src potato.non-free potato.non-free.src sid.contrib sid.contrib.src sid.main sid.main.src sid.non-free sid.non-free.src woody.contrib woody.contrib.src woody.main woody.main.src woody.non-free woody.non-free.src"
 
 PATH=$masterdir:$PATH
 umask 022