"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "scripts/add-issue" between
roundup-1.6.1.tar.gz and roundup-2.0.0.tar.gz

About: Roundup is an highly customisable issue-tracking system with command-line, web and e-mail interfaces (written in Python).

add-issue  (roundup-1.6.1):add-issue  (roundup-2.0.0)
#! /usr/bin/env python #! /usr/bin/env python
''' '''
Usage: %s <tracker home> <priority> <issue title> Usage: %s <tracker home> <priority> <issue title>
Create a new issue in the given tracker. Input is taken from STDIN to Create a new issue in the given tracker. Input is taken from STDIN to
create the initial issue message (which may be empty). Issues will be create the initial issue message (which may be empty). Issues will be
created as the current user (%s) if they exist as a Roundup created as the current user (%s) if they exist as a Roundup
user, or "admin" otherwise. user, or "admin" otherwise.
''' '''
from __future__ import print_function
import sys, os, pwd import sys, os, pwd
from roundup import instance, mailgw, date from roundup import instance, mailgw, date
# open the instance # open the instance
username = pwd.getpwuid(os.getuid())[0] username = pwd.getpwuid(os.getuid())[0]
if len(sys.argv) < 3: if len(sys.argv) < 3:
print "Error: Not enough arguments" print("Error: Not enough arguments")
print __doc__.strip()%(sys.argv[0], username) print(__doc__.strip()%(sys.argv[0], username))
sys.exit(1) sys.exit(1)
tracker_home = sys.argv[1] tracker_home = sys.argv[1]
issue_priority = sys.argv[2] issue_priority = sys.argv[2]
issue_title = ' '.join(sys.argv[3:]) issue_title = ' '.join(sys.argv[3:])
# get the message, if any # get the message, if any
message_text = sys.stdin.read().strip() message_text = sys.stdin.read().strip()
# open the tracker # open the tracker
tracker = instance.open(tracker_home) tracker = instance.open(tracker_home)
 End of changes. 2 change blocks. 
2 lines changed or deleted 3 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)