From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mout.web.de (mout.web.de [212.227.15.14]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C810F19D06A for ; Mon, 14 Apr 2025 18:03:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=212.227.15.14 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744653829; cv=none; b=O4AQ5rwWDvhNY57aHGbV40Dm5x6bFOcZ43pOLROq9S16q6F4LrFSzKOfhujfIk4Zf66rrw502PTXjNUxaRNkezl2CY1GicllsLjvoKzB0kLThOkrymjah9ZaISBj87cQtyqWAj7dan8seMXmRrRVwfujtm4aYkLmJEkp7KtaYxE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744653829; c=relaxed/simple; bh=eioYxrW3IYGdlIb0t7B7PwezIfFdDlhwVIHdaOwuqxE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=CWZR0538M2+7GzkrZ4N12JK977EU7VUI/xtBVwLRj6p+Ol3sFuL89feWeXKW+VHT2XcOfuYstgDq6TuQlfhBcaTGdCxOjjPulE8/2KlJJwI5N7RfnBnLhM6yFXgX4/sREUDh6fhfh9w4oaSQQ6O4dVhARQ1uX3TnuPvDdFRYSuQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=web.de; spf=pass smtp.mailfrom=web.de; dkim=pass (2048-bit key) header.d=web.de header.i=tboegi@web.de header.b=NZVakIFG; arc=none smtp.client-ip=212.227.15.14 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=web.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=web.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=web.de header.i=tboegi@web.de header.b="NZVakIFG" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=web.de; s=s29768273; t=1744653819; x=1745258619; i=tboegi@web.de; bh=HaMplDlW1faCopmIVUHihCZFqVJW2mFasPIXlDHMJuU=; h=X-UI-Sender-Class:Date:From:To:Cc:Subject:Message-ID:References: MIME-Version:Content-Type:In-Reply-To:Content-Transfer-Encoding: cc:content-transfer-encoding:content-type:date:from:message-id: mime-version:reply-to:subject:to; b=NZVakIFGQXL5kwvoajG7dNaU3VSENKzZAXkOYIYqt34p+acKyCCDbpOZSCOnMXyS QPaRecI7Rsg7oG6FoIrLYwW4lGGhhS/qCP2y+m1g9AFaw3x/37Lo1wnLz5GTyayvE zSFtCBAgw/A2wdMtHA/wC2V9c9MjRGtPJZzDNtyXmPv84Q/JIDHi7Zki+/4CkRGV+ e0nemvOE4MjhdIb7dKshssgjhO3I+g6CqHpq89raUx1AM1G7UfrLm13/fetekWeqW zT1ZmnVz4sf1zIGreD30aSz4fxT72h4yj29hSFqgxNWPLBSbI9p/+KJmRUaD3Azir zoBnL32Zy9ijR4zohw== X-UI-Sender-Class: 814a7b36-bfc1-4dae-8640-3722d8ec6cd6 Received: from localhost ([81.231.143.213]) by smtp.web.de (mrweb006 [213.165.67.108]) with ESMTPSA (Nemesis) id 1M28SL-1u1u780FJp-009sNH; Mon, 14 Apr 2025 20:03:39 +0200 Date: Mon, 14 Apr 2025 20:03:38 +0200 From: Torsten =?iso-8859-1?Q?B=F6gershausen?= To: Lucas Seiki Oshiro Cc: messester , "git@vger.kernel.org" Subject: Re: Potential bug: Git instantly converts utf-8-bom to utf-8 Message-ID: <20250414180338.GA2398@tb-raspi4> References: Precedence: bulk X-Mailing-List: git@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-Provags-ID: V03:K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kq/2YIHfuDsnOlpZiHy6HC4OL MU4QvLqTqgjHQWwUoqzLTIoyShXzvG22zUKXRcg3DxblVcf7UrM7T9YLgxa3quBpL+6gJgzYA kDFSo7Q0z4tuyiDQ8zPjhGw1Gw1yyRqQE0kZu8Y0QKB7rJYjlTDIMYKeCfWkrUq3GrJqPv06B u5+el6MRsip1R46MM9WaB+UCsKqe6b2leC/OS2LhyDYClbaMubrlSzyZAxY1Xl6diEIBwg8U7 j7nbciQz6IRaYku/VhCnVSR2XaeiK7h762oVWfUXfs2w4VcLMEaLjsahLs92SYT7eXJMDrg3i E623Z9ZWCORLULabpSE4E8SJh/rAS2531OeaGkzaHzC1CgEADRUne3fhAT410y0bljL3JgGn+ 2P2ZXdDH7KfJrWesM4ddzG85XvviZspfwu5HN39VFfD/tceQxTUQbapymRov9st1+nOxyKcn8 UAsBXDlW8yzsPFLi7EBeZGdHdd9hSJqCG7aImojRnCpdcoTNyOVJXUaX/irIpBBgz1fG1R8vv 0LiH7lKNgiIJo4B3Yg3wejYNPNWLj4uTpfeT4L++bB1gb7yrAqFkSsu2OsEfiZMZDZvDlo065 JaeQV91RdO5LP5FU4qa8K6lCKMyGnc5SDKKBCyTzeEWrWrb1x4xEi/DBqFnfkl9Kangh7Z+yg GqRZQzDEsXdu//h7S9za8vThuPudTeOkuUHdnYWnmSEF5Xhti Content-Transfer-Encoding: quoted-printable On Mon, Apr 14, 2025 at 02:19:05PM -0300, Lucas Seiki Oshiro wrote: > > > When I clone the git repository https://github.com/NinekoTheCat/infini= lore.cs.git into an empty directory and run git status it shows changes wh= ere all the files are deleted and then added again. > > I tried here. I'm in a Mac, it shows that several file changes. > > > The difference seems to be in the first line as opening it in a text e= ditor aware of encodings shows the change from utf-8-bom to utf-8. > > Given the warning messages it looks like it is more related > to CRLF/LF than to UTF-8. > > At least here, for example, the listed modified '*.cs' files > are the ones that ends their lines in CRLF. This is, running: > > ``` > file $(git ls-files '*.cs') | grep CRLF | cut -d ':' -f1 | sort > ``` > > shows me the same files as > > ``` > git status '*.cs' > ``` > > You can also see that are some '*.cs' files that are not > CRLF-terminated by running: > > ``` > file $(git ls-files '*.cs') | grep -v CRLF | sort > ``` > > > I'd be very very grateful if anyone could explain what's going on and = have a solution. > > Perhaps a solution is: > > - Define a CRLF or LF as a standard > - Convert all the files that don't follow the standard that you > have chosen to the one that you have chosen > - Declare it in the .gitattributes file > > Hope that it helps you! I think that this is already done :-) However, the repo must be normalized: git add --renormalize . will do that.