Staging
v0.5.2
https://github.com/git/git
Revision 3368d11f308eb4ba2ad5703aa059bb0e5a82212f authored by Jürgen Rühle on 07 January 2007, 19:18:26 UTC, committed by Junio C Hamano on 08 January 2007, 02:04:57 UTC
Since git-reset has learned restoring the absence of paths git-rm --cached is
no longer necessary. Therefore remove it from the cached content header hint.

Also remove the unfortunate wording 'Cached' from the header itself.

Signed-off-by: Jürgen Rühle <j-r@online.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
1 parent 515377e
Raw File
Tip revision: 3368d11f308eb4ba2ad5703aa059bb0e5a82212f authored by Jürgen Rühle on 07 January 2007, 19:18:26 UTC
Remove unnecessary git-rm --cached reference from status output
Tip revision: 3368d11
show-index.c
#include "cache.h"

int main(int argc, char **argv)
{
	int i;
	unsigned nr;
	unsigned int entry[6];
	static unsigned int top_index[256];

	if (fread(top_index, sizeof(top_index), 1, stdin) != 1)
		die("unable to read index");
	nr = 0;
	for (i = 0; i < 256; i++) {
		unsigned n = ntohl(top_index[i]);
		if (n < nr)
			die("corrupt index file");
		nr = n;
	}
	for (i = 0; i < nr; i++) {
		unsigned offset;

		if (fread(entry, 24, 1, stdin) != 1)
			die("unable to read entry %u/%u", i, nr);
		offset = ntohl(entry[0]);
		printf("%u %s\n", offset, sha1_to_hex((void *)(entry+1)));
	}
	return 0;
}
back to top