Bash-Beautify icon indicating copy to clipboard operation
Bash-Beautify copied to clipboard

Doesn't work with SVN 1.7

Open cjunge opened this issue 12 years ago • 4 comments

SVN 1.7 only has one .svn folder in the root, so the check for "! -d .svn" doesn't work properly.

Otherwise... great script!

cjunge avatar Dec 13 '12 04:12 cjunge

Thanks for the update. We're still running 1.6 at the office. I'll see if I can throw 1.7 on at home and branch the project. Sounds like you have a little bash in you. Care to take a stab at forking it and helping me adapt it for 1.7?

ChrisAlbrechtNREL avatar Dec 13 '12 16:12 ChrisAlbrechtNREL

I have a little experience, more digging around with google ;)

I tried:

function svn_branch {
  # Get the current URL of the SVN repo
  URL=`svn info --xml | fgrep "<url>"`

  if [[ "$URL" != *url* ]]
  then
    exit 1
  fi

But then I'm getting "svn: E155007: '/srv/not-svn/' is not a working copy" error, which I can't seem to prevent being spat out. svn info 2> /dev/null doesn't seem to be working for me... not sure why.

cjunge avatar Dec 13 '12 20:12 cjunge

Alternative might be to walk the directories up until a .svn folder is found... haven't tried that yet.

cjunge avatar Dec 13 '12 20:12 cjunge

Ignore my previous comment about stderr redirect not working... was a typo in the line!

So redirecting stderr seems to work fine!

cjunge avatar Dec 13 '12 20:12 cjunge