Add parameter for git-crypt lock to ignore already locked repository
Aberta
- Linguagem predominante
- C++
- Estrelas
- 9.9k
- Forks
- 544
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Descrição
I'm writing a BASH script that operates on some data stored inside an encrypted repo, and I want to ensure that repo is locked when the script finishes regardless of anything. So, I'm setting a BASH trap that locks the repo, but in case of normal flow, I'm also locking repo earlier.
Currently `git-crypt lock` in the trap fails with error message `Error: this repository is already locked.` and exit code 1.
Would be nice to have a parameter to make `git-crypt lock` to behave like `mkdir -p` - if the repository is already locked, just do nothing and exit with code 0.
Guia de contribuição
Avaliação
Esta issue ainda não foi avaliada.