git-meta ======== A less than freeform way of storing some metadata in git commit objects. What is this? ------------- It's a way to store data along with a git commit object that is less freeform than something like "Close gh-11" but more freeform than having to add extra data structures to the git commit object. It is also completely compatible for people wanting to read this metadata directly from an interface like git-log or github. Syntax ------ In your git commit, you just need a section that looks something like the following: ---git-meta--- foo: bar: "baz" ---git-meta--- This is a YAML formatted block. Currently the only way of setting this metadata is writing the YAML by hand in the commit message. Usage ===== Querying -------- You can use `git-meta [sha|ref] --get-all` to return just the YAML-block. You can also use `git-meta [sha|ref] --get foo.bar` to return "baz" from the earlier example. Will return an empty string if nothing is returned for that piece of metadata. If you were to specify just `--get foo` then the underlying YAML would be returned (in this case `bar: "baz"`). Storing ------- I have not yet got this sorted. I need to think a bit more about this. I originally thought i could use `./.git/COMMIT\_EDIT\_MSG` but it turns out that is overwritten just before every commit. Whack me an email or a github message if you want to help with this feature, or have an idea for implementation. Copyright --------- Copyright (c) 2009 Sam Elliott. See LICENSE for details. (MIT Licence)