import os,sys,time
file = open('svnlog')
revList = []
tempList = []
linen = 1
for line in file:
if (line.startswith("r")) :
svnNumber = line.split('|')[0]
tempList.append(svnNumber)
if line.find('APP-80') != -1 :
tempList.append(line)
revList.append(tempList)
tempList = []
linen +=1
svnRevList=[]
for i in range(len(revList)):
svnRev = "".join(revList[i][-2:-1])
svnRevList.append(svnRev.strip()[1:])
#for j in range(len(revList[i])):
# print revList[i][j]
print svnRevList
svnRevList.sort()
for i in range(len(svnRevList)):
print svnRevList[i]
file.close()
~
根据SVN的MESSAGE进行多版本输出,反向排序,真是曲折~~~啊的相关教程结束。
本文地址:
https://www.ufcn.cn/tutorials/2644423.html
如非特殊说明,本站内容均来自于网友自主分享,概不代表本站观点,如有任何问题我们都将在收到反馈后的第一时间进行处理!