comment
This commit is contained in:
parent
7ff96fad74
commit
a22eaaae27
3 changed files with 29 additions and 1 deletions
|
@ -73,6 +73,7 @@ stopDaemon = liftIO . Utility.Daemon.stopDaemon =<< fromRepo gitAnnexPidFile
|
||||||
- stdout and stderr descriptors. -}
|
- stdout and stderr descriptors. -}
|
||||||
startDaemon :: Bool -> Bool -> Maybe Duration -> Maybe String -> Maybe HostName -> Maybe (Maybe Handle -> Maybe Handle -> String -> FilePath -> IO ()) -> Annex ()
|
startDaemon :: Bool -> Bool -> Maybe Duration -> Maybe String -> Maybe HostName -> Maybe (Maybe Handle -> Maybe Handle -> String -> FilePath -> IO ()) -> Annex ()
|
||||||
startDaemon assistant foreground startdelay cannotrun listenhost startbrowser = do
|
startDaemon assistant foreground startdelay cannotrun listenhost startbrowser = do
|
||||||
|
|
||||||
Annex.changeState $ \s -> s { Annex.daemon = True }
|
Annex.changeState $ \s -> s { Annex.daemon = True }
|
||||||
pidfile <- fromRepo gitAnnexPidFile
|
pidfile <- fromRepo gitAnnexPidFile
|
||||||
logfile <- fromRepo gitAnnexLogFile
|
logfile <- fromRepo gitAnnexLogFile
|
||||||
|
|
|
@ -506,7 +506,7 @@ fsckOnRemote r params
|
||||||
[ ("GIT_WORK_TREE", Git.repoPath r')
|
[ ("GIT_WORK_TREE", Git.repoPath r')
|
||||||
, ("GIT_DIR", Git.localGitDir r')
|
, ("GIT_DIR", Git.localGitDir r')
|
||||||
] environ
|
] environ
|
||||||
batchCommandEnv program (Param "fsck" : params) $ Just environ'
|
batchCommandEnv program (Param "fsck" : params) (Just environ')
|
||||||
|
|
||||||
{- The passed repair action is run in the Annex monad of the remote. -}
|
{- The passed repair action is run in the Annex monad of the remote. -}
|
||||||
repairRemote :: Git.Repo -> Annex Bool -> Annex (IO Bool)
|
repairRemote :: Git.Repo -> Annex Bool -> Annex (IO Bool)
|
||||||
|
|
|
@ -0,0 +1,27 @@
|
||||||
|
[[!comment format=mdwn
|
||||||
|
username="joey"
|
||||||
|
subject="""comment 1"""
|
||||||
|
date="2015-02-09T17:54:00Z"
|
||||||
|
content="""
|
||||||
|
I've confirmed this behavior. Normally git-annex propigates --git-dir
|
||||||
|
to git commands it runs, but this is not done in a few cases in the
|
||||||
|
assistant, including when it starts `git-annex remotedaemon` but also
|
||||||
|
`git-annex fsck`, `git annex unused`, and `git annex transferkeys`.
|
||||||
|
|
||||||
|
(Just search for readProgramFile; Remote.Git.fsckOnRemote is the only
|
||||||
|
place outside the assistant that uses it, and it does take care to
|
||||||
|
propigate --git-dir and --work-tree.)
|
||||||
|
|
||||||
|
Also, restarting the assistant, either in the web ui or automatically due to
|
||||||
|
an upgrade also doesn't propigate --git-dir.
|
||||||
|
|
||||||
|
And, the assistant's autostart file doesn't support --git-dir.
|
||||||
|
|
||||||
|
All of which could be fixed, but I have to wonder, why? What's the use case
|
||||||
|
for a separate --git-dir with the assistant? I guess not vcsh because the
|
||||||
|
assistant would watch for all changes to the home directory, and add them,
|
||||||
|
and that's not how vcsh is used.
|
||||||
|
|
||||||
|
I'm tempted to just make the assistant refuse to start when given a
|
||||||
|
nonstandard --git-dir..
|
||||||
|
"""]]
|
Loading…
Reference in a new issue