]> git.ipfire.org Git - thirdparty/git.git/commit
rev-parse: add a --show-object-format option
authorbrian m. carlson <sandals@crustytoothpaste.net>
Mon, 28 Oct 2019 00:58:55 +0000 (00:58 +0000)
committerJunio C Hamano <gitster@pobox.com>
Mon, 28 Oct 2019 02:34:57 +0000 (11:34 +0900)
commit2eabd383134b7dedbda0e8367ef3df63c67a0445
tree09ac0abf9b20bd2063baf57d2743d89196893a65
parent1bcef512040979964816937162bfc9968d414a4d
rev-parse: add a --show-object-format option

Add an option to print the object format used for input, output, or
storage. This allows shell scripts to discover the hash algorithm in
use.

Since the transition plan allows for multiple input algorithms, document
that we may provide multiple results for input, and the format that the
results may take. While we don't support this now, documenting it early
means that script authors can future-proof their scripts for when we do.

Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/git-rev-parse.txt
builtin/rev-parse.c
t/t1500-rev-parse.sh