Feature Requests item #1081787, was opened at 2004-12-09 14:10
Message generated for change (Comment added) made by anadelonbrin
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=498106&aid=1081787&group_id=61702
Category: None
Group: None
>Status: Pending
Priority: 5
Submitted By: Matthew Vickers (matthew_vickers)
Assigned to: Tony Meyer (anadelonbrin)
Summary: Adding the version only to sb_filter.py
Initial Comment:
Hi Folks,
Doing some integeration of Spambayes into our network
email gateway and I needed the version only to be
printed to the console i.e sb_filter -v. I have
modified the source of sb_filter.py to include the
version commandline option.
Mabey someone else out there needs this small
functionality or it could be placed into the CVS tree.
def version():
print >> sys.stderr, get_version_string("sb_filter"),
"with engine %s" % get_version_string()
sys.exit(1)
and in the main() function
Added a "v" to the getopt arguments
opts, args = getopt.getopt(sys.argv[1:],
'hxd:p:nfvgstGSo:',
['help', 'examples',
'option='])
Added the following into the else if statements
elif opt == '-v':
version();
Regards all.
Matt.
----------------------------------------------------------------------
>Comment By: Tony Meyer (anadelonbrin)
Date: 2005-02-03 15:19
Message:
Logged In: YES
user_id=552329
sb_filter.py -h prints out the version information above the
usage information. Is that not sufficient? (piping the
output through some sort of filter could give just the version).
If there's some reason that just the version by itself would
be good, please let me know and I'll add it for 1.1.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=498106&aid=1081787&group_id=61702
_______________________________________________
Spambayes-bugs mailing list
[email protected]
http://mail.python.org/mailman/listinfo/spambayes-bugs