File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -305,6 +305,26 @@ fetch_git() {
305305 echo " error: please install \` git\` and try again" >&2
306306 exit 1
307307 fi
308+
309+ if [ ! -e " ${PREFIX_PATH} " ]; then
310+ local pkg_suffix=$( echo ${package_name} | sed s/^[a-z]* -//)
311+ local pfx_suffix=$( basename $PREFIX_PATH | sed s/^[a-z]* -//)
312+
313+ if [ " ${pfx_suffix} " == " ${pkg_suffix} " ]; then
314+ local revision
315+ { pushd " ${package_name} "
316+ local commit=$( git rev-parse " ${git_ref} " )
317+ if git log -1 | grep git-svn-id > /dev/null; then
318+ revision=" r$( git log -1 | grep git-svn-id: | sed ' s/.*@//; s/ .*//' ) "
319+ else
320+ revision=" ${commit: 0: 8} "
321+ fi
322+ popd
323+ } >&4 2>&1
324+ PREFIX_PATH=$( echo " ${PREFIX_PATH} " | sed " s/[a-z0-9]*$/${revision} /" )
325+ RUBY_BIN=" ${PREFIX_PATH} /bin/ruby"
326+ fi
327+ fi
308328}
309329
310330fetch_svn () {
You can’t perform that action at this time.
0 commit comments