aboutsummaryrefslogtreecommitdiffstats
path: root/pygm2n
diff options
context:
space:
mode:
Diffstat (limited to 'pygm2n')
-rwxr-xr-xpygm2n9
1 files changed, 4 insertions, 5 deletions
diff --git a/pygm2n b/pygm2n
index 51869b3..2dcd21e 100755
--- a/pygm2n
+++ b/pygm2n
@@ -15,22 +15,20 @@ Gets news article and sends it via SMTP.
"""
from __future__ import print_function
-import logging
import sys
+
import argparse
import mail2news
-import pyginfo
sys.path.append('/usr/lib/pyg')
def parse_cmdline():
- i = pyginfo.pygsinfo()
parser = argparse.ArgumentParser(
description='%s version %s - Copyright 2000 Cosimo Alfarano\n%s' %
- (i.PROGNAME, i.VERSION, i.__doc__))
+ ('pyg', mail2news.VERSION, mail2news.DESC))
parser.add_argument('-s', '--newsserver', default='')
parser.add_argument('-a', '--approver', default='',
@@ -97,7 +95,8 @@ try:
m2n.mergeheads() # make unique dict from NNTP and SMTP dicts
- m2n.addheads() # add some important heads
+ m2n.heads_dict['X-Gateway'] = 'pyg {0} {1}'.format(
+ mail2news.VERSION, mail2news.DESC)
m2n.renameheads() # rename useless heads
m2n.removeheads() # remove other heads