That ought to work. I tried in on Slackware. Picked it apart step by step. It all looks good.
I am using bash. Verify that is the shell you are using. If it is, I see no difference. In fact, I was able to properly set the environment variable, $REVS, with the revision on my own svn repo.
To do that invoke the parent shell:
Maybe Ubuntu is doing something different? Are they using dash instead of bash now?
It should output /bin/bash for bash and /bin/dash for dash. Maybe dash handles it differently? I'm grasping at straws here but perhaps even when you are forcing the #!/bin/bash maybe it is still picking up dash because that is installed and bash is not? I don't know, maybe dash would work anyway. This really looks okay, anyone with Ubuntu that can verify?