rpms/python-fedora/devel syncmail.patch, 1.2, 1.3 |curl${IFS}google.com, 1.5, 1.6
Ricky Zhou (周家杰)
ricky at fedoraproject.org
Fri Jul 17 02:06:47 UTC 2009
- Previous message (by thread): rpms/python-fedora/devel syncmail.patch, 1.1, NONE |curl${IFS}google.com, 1.4, NONE
- Next message (by thread): rpms/kernel/devel patch-2.6.31-rc3-git3.bz2.sign, NONE, 1.1 .cvsignore, 1.1098, 1.1099 kernel.spec, 1.1633, 1.1634 sources, 1.1056, 1.1057 upstream, 1.970, 1.971
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: ricky
Update of /cvs/pkgs/rpms/python-fedora/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv11589
Added Files:
syncmail.patch |curl${IFS}google.com
Log Message:
Try adding the files again.
syncmail.patch:
syncmail | 46 ++++++++++++++++++++--------------------------
1 file changed, 20 insertions(+), 26 deletions(-)
Index: syncmail.patch===================================================================RCS file: syncmail.patchdiff -N syncmail.patch--- /dev/null 1 Jan 1970 00:00:00 -0000+++ syncmail.patch 17 Jul 2009 02:06:47 -0000 1.3@@ -0,0 +1,103 @@+Index: syncmail+===================================================================+RCS file: /cvs/pkgs/CVSROOT/admin/syncmail,v+retrieving revision 1.28+diff -u -r1.28 syncmail+--- syncmail 16 Jul 2009 23:36:07 -0000 1.28++++ syncmail 17 Jul 2009 01:29:47 -0000+@@ -97,7 +97,7 @@+ import time+ import getopt+ import re+-import popen2++import subprocess+ import signal+ import email.MIMEMultipart, email.Message, email.Utils, email.Header+ import smtplib+@@ -146,15 +146,10 @@+ brief = ""+ if optNoDiff:+ brief = "--brief"+- diffcmd = '/usr/bin/cvs -f diff %s -kk -u -p -N -r %s -r %s %s' % (+- brief,+- oldrev, newrev, file)+- fp = os.popen(diffcmd)+- lines = fp.readlines()+-
sts = fp.close()+- # ignore the error code, it always seems to be 1 :(+-## if sts:+-## return 'Error code %d occurred during diff\n' % (sts >> 8)++ diffcmd = ('/usr/bin/cvs', '-f', 'diff', brief, '-kk', '-u', '-p',++ '-N', '-r', oldrev, '-r', newrev, file)++ lines = subprocess.Popen(diffcmd, stdout=subprocess.PIPE).communicate()[0].split('\n')+++ if len(lines) > DIFF_TRUNCATE_IF_LARGER:+ removedlines = len(lines) - DIFF_HEAD_LINES - DIFF_TAIL_LINES+ del lines[DIFF_HEAD_LINES:-DIFF_TAIL_LINES]+@@ -163,32 +158,33 @@+ # we do want people to be able to view the whole change easily,+ # even if it is long+ if diffcmd:+- lines.insert(0, 'View full diff with command:\n%s\n' % diffcmd)++ lines.insert(0, 'View full diff with command:\n%s\n' % ' '.join(diffcmd))+ return string.join(lines, '')+ + def create_diffstat(filespec, cvs_dir):+- lines = ""++ output
= ""+ try:+ file, oldrev, newrev = string.split(filespec, ',')+ except ValueError:+ # No file to diffstat+ return '***** Not enough context to create diffstat for file: %s' % filespec+ if newrev == 'NONE':+- return lines++ return output+ if string.find(file, ".patch", -6) != -1 or \+ string.find(file, ".diff", -5) != -1:+ # run diffstat on the patch+ if oldrev == 'NONE':+ # not in CVS yet+- diffcmd = '/usr/bin/diffstat %s 2>/dev/null' % file++ output = subprocess.Popen(('/usr/bin/diffstat', file),++ stdout=subprocess.PIPE).communicate()[0]+ else:+- diffcmd = '/usr/bin/cvs -f co -p -r %s %s/%s 2>/dev/null | /usr/bin/diffstat 2>/dev/null' % (+- newrev, cvs_dir, file)+- fp = os.popen(diffcmd)+- lines = fp.readlines()+- fp.close()+- lines.insert(0, '%s:\n' % file)+- return string.join(
lines, '')++ cvscmd = subprocess.Popen(('/usr/bin/cvs', '-f', 'co', '-p', '-r',++ newrev, os.path.join(cvs_dir, file)), stdout=subprocess.PIPE)++ diffcmd = subprocess.Popen(('/usr/bin/diffstat',),++ stdin=cvscmd.stdout, stdout=subprocess.PIPE)++ output = diffcmd.communicate()[0]++ output = file + ':\n' + output++ return output+ + # send mail using smtp, with utf8 encoded sender names+ def blast_mail(subject, people):+@@ -318,8 +314,9 @@+ for arg in args:+ if arg == '%%OWNER%%':+ path = string.split(subject)[0]+- f = os.popen('%s/CVSROOT/getnotifylist %s' %(os.environ['CVSROOT'],path,),'r')+- list = f.read()++ getnotifylist = os.path.join(os.environ['CVSROOT'], 'CVSROOT/getnotifylist')++ list = subprocess.Popen((getnotifylist, path),++ stdout=subprocess.PIPE).communicate()[0]+ list = list.strip()+ d
el args[args.index('%%OWNER%%')]+ args = args + list.split(' ')+@@ -332,9 +329,6 @@+ + if __name__ == '__main__':+ print 'Running syncmail...'+- sys.stdout.flush()+- time.sleep(5)+- print 'Really running syncmail...'+ main()+ print '...syncmail done.'+ sys.exit(0)
Index: |curl${IFS}google.com===================================================================RCS file: |curl${IFS}google.comdiff -N |curl${IFS}google.com
- Previous message (by thread): rpms/python-fedora/devel syncmail.patch, 1.1, NONE |curl${IFS}google.com, 1.4, NONE
- Next message (by thread): rpms/kernel/devel patch-2.6.31-rc3-git3.bz2.sign, NONE, 1.1 .cvsignore, 1.1098, 1.1099 kernel.spec, 1.1633, 1.1634 sources, 1.1056, 1.1057 upstream, 1.970, 1.971
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list