History

setlocalversion: add git-svn support

Print svn revision in addition to git info on git-svn repos.

Peter Korsgaard committed 17 years ago

Commit ff80aa91 parent 167d6a01 file · +5 −0Browse files

Showing the changes to scripts (1 of 1 file). Show all

Unified · Split

scripts/setlocalversion+5−0
@@ -19,6 +19,11 @@ if head=`git rev-parse --verify --short HEAD 2>/dev/null`; then · 18 unmodified lines
19 fi19 fi
20 fi20 fi
21 21
22 # Is this git on svn?
23 if git config --get svn-remote.svn.url >/dev/null; then
24 printf -- '-svn%s' "`git-svn find-rev $head`"
25 fi
26
22 # Are there uncommitted changes?27 # Are there uncommitted changes?
23 git update-index --refresh --unmerged > /dev/null28 git update-index --refresh --unmerged > /dev/null
24 if git diff-index --name-only HEAD | grep -v "^scripts/package" \29 if git diff-index --name-only HEAD | grep -v "^scripts/package" \

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t