summaryrefslogtreecommitdiff
path: root/Command/WebApp.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Command/WebApp.hs')
-rw-r--r--Command/WebApp.hs7
1 files changed, 5 insertions, 2 deletions
diff --git a/Command/WebApp.hs b/Command/WebApp.hs
index d5f43432c..b252d4d7c 100644
--- a/Command/WebApp.hs
+++ b/Command/WebApp.hs
@@ -107,8 +107,11 @@ startNoRepo _ = do
(d:_) -> do
setCurrentDirectory d
state <- Annex.new =<< Git.CurrentRepo.get
- void $ Annex.eval state $ callCommandAction $
- start' False listenhost
+ void $ Annex.eval state $ do
+ whenM (fromRepo Git.repoIsLocalBare) $
+ error $ d ++ " is a bare git repository, cannot run the webapp in it"
+ callCommandAction $
+ start' False listenhost
{- Run the webapp without a repository, which prompts the user, makes one,
- changes to it, starts the regular assistant, and redirects the