webapp: When setting up a bare shared repository, enable non-fast-forward pushes.
This commit is contained in:
parent
0c0e0e5550
commit
0dfe604ddc
4 changed files with 20 additions and 1 deletions
|
@ -390,7 +390,7 @@ prepSsh' newgcrypt origsshdata sshdata keypair a = sshSetup
|
|||
remoteCommand = shellWrap $ intercalate "&&" $ catMaybes
|
||||
[ Just $ "mkdir -p " ++ shellEscape remotedir
|
||||
, Just $ "cd " ++ shellEscape remotedir
|
||||
, if rsynconly then Nothing else Just "if [ ! -d .git ]; then git init --bare --shared; fi"
|
||||
, if rsynconly then Nothing else Just "if [ ! -d .git ]; then git init --bare --shared && git config receive.denyNonFastforwards false; fi"
|
||||
, if rsynconly || newgcrypt then Nothing else Just "git annex init"
|
||||
, if needsPubKey origsshdata
|
||||
then addAuthorizedKeysCommand (hasCapability origsshdata GitAnnexShellCapable) remotedir . sshPubKey <$> keypair
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue