Skip to content

Instantly share code, notes, and snippets.

View tdemarest's full-sized avatar

Timothy Demarest tdemarest

View GitHub Profile
@thomsh
thomsh / git-crypt-rm-gpg-user.sh
Last active October 19, 2023 05:14 — forked from Falkor/git-crypt-rm-gpg-user.sh
Allow you to rotate your git-crypt key and re-encrypt your repository after removing GPG user (Safer version)
#!/usr/bin/env bash
#
# Script to remove GPG user (recipient) with git-crypt
#
# It will re-initialize git-crypt for the repository and re-add all keys except
# the one requested for removal.
#
# Note: You still need to change all your secrets to fully protect yourself.
# Removing a user will prevent them from reading future changes but they will
# still have a copy of the data up to the point of their removal.