Re: Server-side preventing some files from being overwritten
- From
Thorsten Glaser <t.glaser@tarent.de>
- Date
- Jul 14, 2016, 18:50 UTC
- Message-ID
- <alpine.DEB.2.20.1607142049240.25238@tglase.lan.tarent.de>
- In-Reply-To
- <xmqqpoqgqdlz.fsf@gitster.mtv.corp.google.com>
On Thu, 14 Jul 2016, Junio C Hamano wrote:
> Can't this become simpler, e.g. > > if ! git diff-tree --quiet "$old" "$new" -- "$subdir"
Thought about diff-tree, but additions are permitted, and diffing the actual file content has overhead too.
Just counting the number of object hashes removed from the old tree (recursed) works out just fine.
bye, //mirabilos
-- tarent solutions GmbH Rochusstraße 2-4, D-53123 Bonn • http://www.tarent.de/ Tel: +49 228 54881-393 • Fax: +49 228 54881-235 HRB 5168 (AG Bonn) • USt-ID (VAT): DE122264941 Geschäftsführer: Dr. Stefan Barth, Kai Ebenrett, Boris Esser, Alexander Steeg