GIT_ANNEX_SHELL_APPENDONLY
Makes it allow writes, but not deletion of annexed content. Note that securing pushes to the git repository is left up to the user. This commit was sponsored by Jack Hill on Patreon.
This commit is contained in:
parent
0003109f5d
commit
85f9360d9b
7 changed files with 120 additions and 50 deletions
|
@ -26,6 +26,12 @@ readOnlyEnv = "GIT_ANNEX_SHELL_READONLY"
|
|||
checkNotReadOnly :: IO ()
|
||||
checkNotReadOnly = checkEnv readOnlyEnv
|
||||
|
||||
appendOnlyEnv :: String
|
||||
appendOnlyEnv = "GIT_ANNEX_SHELL_APPENDONLY"
|
||||
|
||||
checkNotAppendOnly :: IO ()
|
||||
checkNotAppendOnly = checkEnv appendOnlyEnv
|
||||
|
||||
checkEnv :: String -> IO ()
|
||||
checkEnv var = checkEnvSet var >>= \case
|
||||
False -> noop
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue