A script for extracting version information useful in release/build scripting.
Shell Makefile Python C
Latest commit f965df0 Aug 13, 2016 @pabs3 pabs3 mkexamp.sh: use bash instead of sh
The -d option to read is not standard and only implemented by bash.

The script isn't easy to convert to POSIX shell.

Suggested-by: checkbashisms
Suggested-by: shellcheck
Suggested-by: sh -n



A shell script for extracting revision information useful in release/build scripting from repositories.

Supported repository types include git, hg, bzr, and svn. The record can be emitted in a ready-to-use form for C, C++, Java, bash, Python, Perl, lua, php, ini and others.

Emitted information includes the ID of the most recent commit, its branch, its date, and several other useful pieces of meta-information.

There is support for reading and writing a cache file so autorevision will remain useful during a build from an unpacked distribution tarball.

See the manual page, included in the distribution, for invocation details.

You can check out examples of the different output that autorevision can produce in examples.