user246813
user246813

Reputation: 49

How to display only revision numbers from svn log command?

I am new to svn. I want to know how to display revision changes checked in between two dates.

I have used this command

svn log -r {2013-11-10}:{2014-01-01} url

It shows me correct output. But I want to display only revision numbers not log messages. I want output like this

r2077
r2078
r2079
...

Upvotes: 2

Views: 2980

Answers (3)

Jeremy Sarao
Jeremy Sarao

Reputation: 41

svn log -r {2013-11-10}:{2014-01-01} url | sed -n '/^r[0-9]/p' | cut -d '|' -f1

Upvotes: 1

opticyclic
opticyclic

Reputation: 8126

I couldn't get the accepted answer to match. Using cut seemed to work better than extended grep.

svn log -r {2013-11-10}:{2014-01-01} url| grep "r[0-9\s]*\|" |cut -d\| -f1

Upvotes: 1

Noam Rathaus
Noam Rathaus

Reputation: 5598

How about something like this:

svn log -r {2013-11-10}:{2014-01-01} url | grep -e "r[0-9]. |" | grep -oE "r[0-9]."

Upvotes: 0

Related Questions