This is the mail archive of the cygwin-apps-cvs mailing list for the cygwin-apps project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[calm - Cygwin server-side packaging maintenance script] branch master, updated. 20160705-64-g389b020




https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=389b02002f7accd6ba05e22d00cdd7b973c93035

commit 389b02002f7accd6ba05e22d00cdd7b973c93035
Author: Jon Turney <jon.turney@dronecode.org.uk>
Date:   Thu Apr 6 19:25:49 2017 +0100

    Add daemon mode for calm
    
    SIGUSR1 tells it to re-read the upload area
    SIGUSR2 tells it to re-read the release area
    
    This avoids maintainers having to wait a random amount of time to discover
    the result of their uploads
    
    For the moment, we still re-read everything every 30 minutes, but this could
    be increased, which would be a good deal more efficient, as we won't be
    re-reading the state of the relarea when nothing has changed.

https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=d935dc04cd2ce0262bf0a3df523b61c23716b246

commit d935dc04cd2ce0262bf0a3df523b61c23716b246
Author: Jon Turney <jturney@sourceware.org>
Date:   Thu May 12 16:45:33 2016 +0000

    Tweak email recipents
    
    Add stromeko to errors list
    Add jturney and yselkowitz to Bcc list

https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=1163403b267d31dbd14949fa425cfc29ecee14f7

commit 1163403b267d31dbd14949fa425cfc29ecee14f7
Author: Jon Turney <jon.turney@dronecode.org.uk>
Date:   Fri Jun 24 14:23:51 2016 +0100

    Also check for skip: but install files
    
    Check the condition both ways, so the presence/absence of skip: matches
    absence/presence of an install tarfile


Diff:
---
 calm/calm.py    |    7 ++++---
 calm/package.py |    2 +-
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/calm/calm.py b/calm/calm.py
index 33bc05d..c01bc1a 100755
--- a/calm/calm.py
+++ b/calm/calm.py
@@ -447,7 +447,7 @@ def do_daemon(args, state):
     context = daemon.DaemonContext(
         stdout=sys.stdout,
         stderr=sys.stderr,
-        pidfile=lockfile.pidlockfile.PIDLockFile('/var/run/calm.pid'))
+        pidfile=lockfile.pidlockfile.PIDLockFile(args.daemon))
 
     running = True
     read_relarea = True
@@ -578,6 +578,7 @@ def main():
     htdocs_default = os.path.join(common_constants.HTDOCS, 'packages')
     homedir_default = common_constants.HOMEDIR
     orphanmaint_default = common_constants.ORPHANMAINT
+    pidfile_default = '/sourceware/cygwin-staging/calm.pid'
     pkglist_default = common_constants.PKGMAINT
     relarea_default = common_constants.FTP
     setupdir_default = common_constants.HTDOCS
@@ -586,8 +587,8 @@ def main():
     queuedir_default = '/sourceware/cygwin-staging/queue'
 
     parser = argparse.ArgumentParser(description='Upset replacement')
-    parser.add_argument('-d', '--daemon', action='store_true', help="daemonize")
-    parser.add_argument('--email', action='store', dest='email', nargs='?', const=common_constants.EMAILS, help='email output to maintainer and ADDRS (default: ' + common_constants.EMAILS + ')', metavar='ADDRS')
+    parser.add_argument('-d', '--daemon', action='store', nargs='?', const=pidfile_default, help="daemonize (PIDFILE defaults to " + pidfile_default + ")", metavar='PIDFILE')
+    parser.add_argument('--email', action='store', dest='email', nargs='?', const=common_constants.EMAILS, help="email output to maintainer and ADDRS (ADDRS defaults to '" + common_constants.EMAILS + "')", metavar='ADDRS')
     parser.add_argument('--force', action='store_true', help="overwrite existing files")
     parser.add_argument('--homedir', action='store', metavar='DIR', help="maintainer home directory (default: " + homedir_default + ")", default=homedir_default)
     parser.add_argument('--htdocs', action='store', metavar='DIR', help="htdocs output directory (default: " + htdocs_default + ")", default=htdocs_default)
diff --git a/calm/package.py b/calm/package.py
index 0513084..fe188c4 100755
--- a/calm/package.py
+++ b/calm/package.py
@@ -468,7 +468,7 @@ def validate_packages(args, packages):
                 packages[p].skip = True
                 logging.info("package '%s' appears to be source-only as it has no non-empty install tarfiles and no dependencies, marking as 'skip'" % (p))
 
-        elif has_install and any(['skip' in version_hints[vr] for vr in vr_list]):
+        elif has_install and any(['skip' in packages[p].version_hints[vr] for vr in packages[p].version_hints]):
             logging.error("package '%s' has 'skip:' hint but also has install tarfiles" % (p))
             error = True
 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]