Git-based deployment configuration tracking system
Branch: master
Clone or download
Pull request Compare This branch is even with bostjan:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Git-based application deployment configuration tracking system

Gitfig is intended to track and/or store configuration information that is used to finally deploy a code that is already tracked in some git repository.

Downloadable release packages are available here:


Minimal git version: TODO

Either use specified minimal git version, or patch your git installation with

Realpath tool

This tool is essential for searching upwards the directory tree for .git
repository. This tool is not present in coreutils releases before v8.16.


Classical autotools installation procedure:

tar -xzf gitfig-*.tar.gz
./configure ...
make install


Intended use case is when you are already using non-bare git repository as deployment of your application. In there you usually create a few deployment- specific configuration files that are normally ignored by .gitignore file at reposotiry root.

Gitfig is here to help you track changes to those deployment-specific but missing-critical files.

What gitfig is NOT intended for? If you already have more sophisticated method of deployment by packing code and deployment-specific configuration files into a package and then deploying that package as a whole, gitfig is not the tool for you.

Initialize with already-deployed application

  1. gitfig init

    This will create initial gitfig's git-based repository in .git/.gitfig. It will parse your .gitignore file in repo's root directory and invert it's contents. Result will be saved in .gitfigignore file in you repo's root directory. It will also store your code's origin repository location - FIXME yes or no?

  2. gitfig status

    This will show you which files are not tracked by your code repository and are thus candidates to be tracked by gitfig. This also shows changes to code that are not commited, if any.

  3. gitfig add FILE

    Add files you wish to track using gitfig.

  4. edit .gitfigignore

    Ignore files that you do not wish to track (application content files, etc). In .gitignore both configuration and content dirs/files are specified to be ignored. Gitfig can not distinguish between the two. Now is the time to specify locations of data files that are to be ignored by gitfig too.

  5. gitfig adduntracked

    Add all untracked files (which are reincluded, not ignored) at once.

  6. gitfig commit

    Commit your deployment configuration data.

Updating exclude patterns

  1. gitfig parse

    This will (re)parse .gitignore file. All exclude patterns, which are found in .gitignore, and their corresponding unignore patterns are missing in .gitfigignore, will be added to existing .gitfigignore file.

  2. gitfig status

    (See above.)

Initialize with initial code repo cloning - TODO


Deploy using gitfig - TODO

  1. gitfig deploy GITFIG_URI PATH

    This will deploy your code + configuration into PATH It will first clone GITFIG_URI into temporary location under PATH Then it will get code repo URI from gitfig configuration and clone it too It will then merge contents of these two repos Merged result will be moved to final location (PATH)

  2. gitfig status