tests: Support git-worktree(1)
git-worktree(1) uses a regular file for <.git>, instead of a directory. Signed-off-by: Alejandro Colomar <alx@kernel.org>
This commit is contained in:
		
				
					committed by
					
						 Serge Hallyn
						Serge Hallyn
					
				
			
			
				
	
			
			
			
						parent
						
							4445cee19d
						
					
				
				
					commit
					a72065a108
				
			| @@ -3,10 +3,10 @@ | ||||
| set -e | ||||
|  | ||||
| build_path=$(pwd) | ||||
| while [ "${build_path}" != "/" -a ! -d "${build_path}/.git" ]; do | ||||
| while [ "${build_path}" != "/" -a ! -e "${build_path}/.git" ]; do | ||||
| 	build_path=$(dirname ${build_path}) | ||||
| done | ||||
| if [ ! -d "${build_path}/.git" ]; then | ||||
| if [ ! -e "${build_path}/.git" ]; then | ||||
| 	echo "Not inside git directory" 1>&2 | ||||
| 	exit 1 | ||||
| fi | ||||
|   | ||||
		Reference in New Issue
	
	Block a user