SVN版本号

1.脚本bat中,获取svn最新版本号:

set versionNum=0

for /f %%i in ('svn info --show-item revision') do (

set versionNum=%%i

)

2.在安卓项目中app目录下build.gradle中获取svn版本号:

task getGitVersion() {

def svnVersion ="1"

def svnVersionStream = ne ByteArrayOutputStream()

try{

exec {

executable "svn" args "info"

standardOutput = svnVersionStream

}

svnVersion = svnVersionStream.toString().find("Revision:(\d+)");

svnVersion = svnVersion.toString().find("(\d+)) ;

} catch (Exception e) {

println("svn not found"+ e.toString())

project.version = svnVersion

相关推荐
▍ 小太阳 ☼3 天前
如何让Codex读svn项目
svn·chatgpt
云小逸5 天前
【SVN 详细使用指南:从入门到团队协作】
c++·svn
曹牧23 天前
Eclipse:SVN 回复
java·svn·eclipse
NexTunnel25 天前
公司老项目还在 SVN,远程维护怎么做更稳?
git·svn·gitlab·远程工作·nextunnel
鱼听禅1 个月前
CentOS 源码模式配置SVNAdmin2管理SVN仓库
linux·svn·centos
_阿伟_1 个月前
SVN简单使用教程
svn
NexTunnel1 个月前
告别传统组网,也能安全访问公司 GitLab / SVN
安全·svn·gitlab
2601_961875242 个月前
花生十三公考课程|网课|视频
数据库·windows·git·svn·eclipse·github
2601_961875242 个月前
花生十三资料网盘|百度云|下载
数据库·windows·git·svn·eclipse·github
WSKH09292 个月前
【操作记录】Mac 系统安装并使用 SVN
macos·svn