webapp: Refuse to start in a bare git repository.
This commit is contained in:
parent
1681386b0d
commit
f70d0479d5
2 changed files with 6 additions and 2 deletions
|
@ -107,8 +107,11 @@ startNoRepo _ = do
|
||||||
(d:_) -> do
|
(d:_) -> do
|
||||||
setCurrentDirectory d
|
setCurrentDirectory d
|
||||||
state <- Annex.new =<< Git.CurrentRepo.get
|
state <- Annex.new =<< Git.CurrentRepo.get
|
||||||
void $ Annex.eval state $ callCommandAction $
|
void $ Annex.eval state $ do
|
||||||
start' False listenhost
|
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,
|
{- Run the webapp without a repository, which prompts the user, makes one,
|
||||||
- changes to it, starts the regular assistant, and redirects the
|
- changes to it, starts the regular assistant, and redirects the
|
||||||
|
|
1
debian/changelog
vendored
1
debian/changelog
vendored
|
@ -4,6 +4,7 @@ git-annex (5.20140228) UNRELEASED; urgency=medium
|
||||||
* webapp: Filter out from Switch Repository list any
|
* webapp: Filter out from Switch Repository list any
|
||||||
repositories listed in autostart file that don't have a
|
repositories listed in autostart file that don't have a
|
||||||
git directory anymore.
|
git directory anymore.
|
||||||
|
* webapp: Refuse to start in a bare git repository.
|
||||||
|
|
||||||
-- Joey Hess <joeyh@debian.org> Fri, 28 Feb 2014 14:52:15 -0400
|
-- Joey Hess <joeyh@debian.org> Fri, 28 Feb 2014 14:52:15 -0400
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue