1 Star 0 Fork 47

一个梦一辈子 / moba协议

forked from liyonghelpme / moba协议 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
UpdateSln.py 556 Bytes
一键复制 编辑 原始数据 按行查看 历史
liyonghelpme 提交于 2016-07-09 22:41 . init commit
#coding:utf8
import os
import re
pat = re.compile('Compile Include')
res = ''
template = ' <Compile Include="%s" />\n'
replace = ''
allFiles = os.listdir('.')
for f in allFiles:
if f.find('.cs') != -1 and f.find('.cspr') == -1:
replace += template % (f)
f = open('protoDll.csproj').readlines()
first = True
for l in f:
if len(pat.findall(l)) > 0:
if first:
res += replace
first = False
else:
pass
else:
res += l
nf = open('new.csproj', 'w')
nf.write(res)
nf.close()
1
https://gitee.com/onedream/mobaXieYi.git
git@gitee.com:onedream/mobaXieYi.git
onedream
mobaXieYi
moba协议
moba

搜索帮助