Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-23 Thread Ashish Negi
Great work !!! Thanks On Fri, Nov 24, 2017 at 1:55 AM, Torsten Bögershausen wrote: > On Thu, Nov 23, 2017 at 10:01:40PM +0530, Ashish Negi wrote: >> Thanks for confirming. >> Is it possible to track this via a bug number ? >> It will help me to try out the fix when its available.

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-23 Thread Torsten Bögershausen
On Thu, Nov 23, 2017 at 10:01:40PM +0530, Ashish Negi wrote: > Thanks for confirming. > Is it possible to track this via a bug number ? > It will help me to try out the fix when its available. > No worry, the fix is nearly complete and will come out in a couple of days.

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-23 Thread Ashish Negi
Thanks for confirming. Is it possible to track this via a bug number ? It will help me to try out the fix when its available. On Thu, Nov 16, 2017 at 9:45 PM, Torsten Bögershausen wrote: > On Thu, Nov 16, 2017 at 12:35:33AM +0530, Ashish Negi wrote: >> On windows : >> > git

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-16 Thread Torsten Bögershausen
On Thu, Nov 16, 2017 at 12:35:33AM +0530, Ashish Negi wrote: > On windows : > > git --version > git version 2.14.2.windows.2 > > On linux : > > git --version > git version 2.7.4 > > I would like to understand the solution : > If i understood it correctly : it removes file_name.txt from index, so

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-15 Thread Ashish Negi
On windows : > git --version git version 2.14.2.windows.2 On linux : > git --version git version 2.7.4 I would like to understand the solution : If i understood it correctly : it removes file_name.txt from index, so git forgets about it. we then add the file again after changing encoding. This

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-15 Thread Torsten Bögershausen
On Wed, Nov 15, 2017 at 01:41:42PM +0530, Ashish Negi wrote: > > If you commit the file, it will be stored with LF in the index, > This is what i believe is not happening. > > Lets do this with a public repository and steps which are reproducible. > I have created a repo :

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-15 Thread Ashish Negi
> If you commit the file, it will be stored with LF in the index, This is what i believe is not happening. Lets do this with a public repository and steps which are reproducible. I have created a repo : https://github.com/ashishnegi/git_encoding If you clone this repo in linux and run `git

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-14 Thread Torsten Bögershausen
(Back to the beginning) You have a file ApplicationManifest.xml It is encoded in UTF-16 (and has CRLF) You convert it into UTF-8 The file has still CRLF (in the worktree) Now you add it and make a commit. Under both Linux and Windows you have "text=auto". I assume that you have efficiently

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-14 Thread Torsten Bögershausen
On 2017-11-14 17:13, Ashish Negi wrote: > Running the command gives me : > > git ls-files --eol file_name > i/-text w/-text attr/text=auto file_name > That is strange to me: According to that, Git would treat the file as text=auto. And the content is "not next", so there is

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-14 Thread Ashish Negi
After changing the encoding of file to utf-8, same command gives: git ls-files --eol file_name i/lfw/crlf attr/text=auto ApplicationManifest.xml On Tue, Nov 14, 2017 at 9:43 PM, Ashish Negi wrote: > Running the command gives me : > > git ls-files

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-14 Thread Ashish Negi
Running the command gives me : git ls-files --eol file_name i/-text w/-text attr/text=auto file_name

Re: Changing encoding of a file : What should happen to CRLF in file ?

2017-11-14 Thread Torsten Bögershausen
On 2017-11-14 13:31, Ashish Negi wrote: > Hello > > I have a cross platform project. I have a utf-16 file in it. > I changed its encoding to urf-8 and committed. When i pulled the file > in Linux, it shows that file is modified. This means that the commit > which changed the encoding does not

Changing encoding of a file : What should happen to CRLF in file ?

2017-11-14 Thread Ashish Negi
Hello I have a cross platform project. I have a utf-16 file in it. I changed its encoding to urf-8 and committed. When i pulled the file in Linux, it shows that file is modified. This means that the commit which changed the encoding does not convert crlf to lf, when new format is text based