Commit 468fac7b authored by Vitaly Lipatov's avatar Vitaly Lipatov

git: fix get_root_git_dir for recursive search

parent 03a7cfd5
......@@ -22,12 +22,14 @@ get_current_branch()
get_root_git_dir()
{
# FIXME
if [ -d ../.git ] ; then
readlink -f $(pwd)/..
local DIR="$1"
[ -n "$DIR" ] || DIR=$(pwd)
[ "$DIR" = "/" ] && return 1
if [ -d "$DIR/.git" ] ; then
readlink -f "$DIR"
return
fi
pwd
get_root_git_dir $(dirname "$DIR") || return 1
}
get_remote_git_list()
......
#!/bin/sh
. `dirname $0`/../share/eterbuild/functions/common
load_mod git
get_root_git_dir
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment