From a544dd1aeb934625f6e42af02a480c25d0d7eb7a Mon Sep 17 00:00:00 2001 From: richard Date: Tue, 18 Sep 2001 22:58:37 +0000 Subject: [PATCH] Added some more help to roundu-admin git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@256 57a73879-2fb5-44c3-a270-3262357dd7e2 --- CHANGES.txt | 3 +++ roundup-admin | 29 +++++++++++++++++------------ roundup/date.py | 12 +++++++++--- 3 files changed, 29 insertions(+), 15 deletions(-) diff --git a/CHANGES.txt b/CHANGES.txt index 1f66b41..49159f5 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -2,12 +2,15 @@ This file contains the changes to the Roundup system over time. The entries are given with the most recent entry first. 2001-??-?? - 0.2.9 +Fixed: + . Pretty time interval wasn't handling > 1 month properly. . Generation of links to Link/Multilink in indexes. (thanks Hubert Hoegl) . AssignedTo wasn't in the "classic" schema's item page. 2001-08-30 - 0.2.8 Fixed: + . Wasn't handling unguessable mime types for file uploads. . Missing import in mailgw. diff --git a/roundup-admin b/roundup-admin index d110ebc..f69009f 100755 --- a/roundup-admin +++ b/roundup-admin @@ -16,7 +16,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -# $Id: roundup-admin,v 1.17 2001-08-28 05:58:33 anthonybaxter Exp $ +# $Id: roundup-admin,v 1.18 2001-09-18 22:58:37 richard Exp $ import sys if int(sys.version[0]) < 2: @@ -38,24 +38,26 @@ def usage(message=''): Commands: %s - Help: roundup-admin -h - roundup-admin help - -- this help - roundup-admin help - -- command-specific help - roundup-admin morehelp - -- even more detailed help - -'''%(message, '\n '.join(commands)) + roundup-admin help -- this help + roundup-admin help -- command-specific help + roundup-admin morehelp -- even more detailed help +Options: + -i instance home -- specify the issue tracker "home directory" to administer + -u -- the user[:password] to use for commands + -c -- when outputting lists of data, just comma-separate them'''%( +message, '\n '.join(commands)) def moreusage(message=''): usage(message) print ''' All commands (except help) require an instance specifier. This is just the path -to the roundup instance you're working with. It may be specified in the -environment variable ROUNDUP_INSTANCE or on the command line as "-i instance". +to the roundup instance you're working with. A roundup instance is where +roundup keeps the database and configuration file that defines an issue +tracker. It may be thought of as the issue tracker's "home directory". It may +be specified in the environment variable ROUNDUP_INSTANCE or on the command +line as "-i instance". A designator is a classname and a nodeid concatenated, eg. bug1, user10, ... @@ -426,6 +428,9 @@ if __name__ == '__main__': # # $Log: not supported by cvs2svn $ +# Revision 1.17 2001/08/28 05:58:33 anthonybaxter +# added missing 'import' statements. +# # Revision 1.16 2001/08/12 06:32:36 richard # using isinstance(blah, Foo) now instead of isFooType # diff --git a/roundup/date.py b/roundup/date.py index da19289..ef65d87 100644 --- a/roundup/date.py +++ b/roundup/date.py @@ -15,7 +15,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -# $Id: date.py,v 1.12 2001-08-17 03:08:11 richard Exp $ +# $Id: date.py,v 1.13 2001-09-18 22:58:37 richard Exp $ import time, re, calendar @@ -317,10 +317,13 @@ class Interval: ''' if self.year or self.month > 2: return None - if self.month: + if self.month or self.day > 13: days = (self.month * 30) + self.day if days > 28: - return '%s months'%int(days/30) + if int(days/30) > 1: + return '%s months'%int(days/30) + else: + return '1 month' else: return '%s weeks'%int(days/7) if self.day > 7: @@ -376,6 +379,9 @@ if __name__ == '__main__': # # $Log: not supported by cvs2svn $ +# Revision 1.12 2001/08/17 03:08:11 richard +# fixed prettification of intervals of 1 week +# # Revision 1.11 2001/08/15 23:43:18 richard # Fixed some isFooTypes that I missed. # Refactored some code in the CGI code. -- 2.30.2