Is it possible to have git encrypt and decrypt a file during a push/pull?

Possible Duplicate:
git encrypt/decrypt remote repository files while push/pull

I’d like to store some private data in a git repository that is going out in the world, basically some private configuration, and so on. I’d like to (somehow) have the file encrypted either as I commit it, or as I push it (preferably the latter, because then I can do reasonable diffs against the text form), and also obviously the inverse.

  • What do I need for Travis-CI to decrypt secure variables on my fork?
  • Cannot communicate securely with peer: no common encryption algorithm(s)
  • Securely deploy public repo to remote VM from Travis CI?
  • How do I force a re-decryption of my local transcrypt objects?
  • Is there an encrypted version control system?
  • Are git push and pulls encrypted?
  • Is this possible with git’s hooks?

  • Why does Git returns these characters when I pull from my remote repository?
  • update svn repo weekly with changes from a git repository with losing history
  • Switching a branch after aborting current changes in git
  • Hooks for git-svn
  • Why does ls work in GitShell, but ls -a or ls -la not work?
  • How do I customize the format of git rebase --interactive commit messages?
  • One Solution collect form web for “Is it possible to have git encrypt and decrypt a file during a push/pull?”

    One way of doing this is is to encrypt the objects as they’re being staged, and decrypted on checkout. This is rather earlier than doing it solely on push / pull, but might be useful to you.

    The way to do this is to use git’s “smudge” and “clean” filters, but it’s not necessarily recommended for reasons that are explained here by Junio C Hamano, the maintainer of git:

    If you still decide to go ahead, you may want to look at this implementation of encrypting/decrypting clean/smudge filters:

    Git Baby is a git and github fan, let's start git clone.