Get the latest tech news
Git-crypt – transparent file encryption in Git
git-crypt - transparent file encryption in git git-crypt enables transparent encryption and decryption of files in a git repository. Files which you choose to protect are encrypted when committed, and decrypted when checked out.
git-crypt gracefully degrades, so developers without the secret key can still clone and commit to a repository with encrypted files. Note: git-crypt add-gpg-user will add and commit a GPG-encrypted key file in the .git-crypt directory of the root of your repository. git-crypt does not encrypt file names, commit messages, symlink targets, gitlinks, or other metadata.
Or read this on Hacker News