Close #506
@@ -705,6 +705,12 @@ function! s:prepare(...)
throw 'Invalid current working directory. Cannot proceed.'
endif
+ for evar in ['$GIT_DIR', '$GIT_WORK_TREE']
+ if exists(evar)
+ throw evar.' detected. Cannot proceed.'
+ endif
+ endfor
+
call s:job_abort()
if s:switch_in()
normal q