only push when needsinit
This commit is contained in:
parent
49d8cb1bf6
commit
52ecf232fb
1 changed files with 6 additions and 5 deletions
|
@ -506,11 +506,12 @@ prepSsh' needsinit origsshdata sshdata keypair a
|
|||
{- To ensure the repository is initialized, try to push the
|
||||
- git-annex branch to it. Then git-annex-shell will see
|
||||
- the branch and auto-initialize. -}
|
||||
void $ liftAnnex $ inRepo $ Git.Command.runBool
|
||||
[ Param "push"
|
||||
, Param (genSshUrl sshdata)
|
||||
, Param (fromRef Annex.Branch.name)
|
||||
]
|
||||
when needsinit $ do
|
||||
void $ liftAnnex $ inRepo $ Git.Command.runBool
|
||||
[ Param "push"
|
||||
, Param (genSshUrl sshdata)
|
||||
, Param (fromRef Annex.Branch.name)
|
||||
]
|
||||
a sshdata
|
||||
| otherwise = sshSetup (mkSshInput origsshdata)
|
||||
[ "-p", show (sshPort origsshdata)
|
||||
|
|
Loading…
Reference in a new issue