简体   繁体   中英

svn: how to list last tags from svn command line?

Whe have built a packager who diff the last due tag in svn and prepare directory folding and copy the 'diff' files in the right plave.

but we must enter on commnand line the two tag name, and so we must consult revision graph (from windows).

Is there a way to list tags from svn command line client ?

这可以在Windows,Mac或Linux上的命令行中使用,但它要求当前工作目录位于工作副本中:

svn ls "^/tags"

With power shell:

$path = (([Xml] (svn log --xml $Url --verbose --username $Username --password $Password)).Log.LogEntry.Paths.Path |
? { $_.action -eq 'A' -and $_.kind -eq 'dir' -and $_.InnerText -like '*tags*'} |
Select -Property @(
    @{N='date'; E={$_.ParentNode.ParentNode.Date}},
    @{N='path'; E={$_.InnerText}} )|
Sort Date -Descending |
Select -First 1).path

Where $Url is the url of you tags

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM