Gnucash 2.5/6 - jqplot

Geert Janssens janssens-geert at telenet.be
Thu Feb 21 12:55:31 EST 2013


Op 21-02-13 18:19, Mike Evans schreef:
> On Thu, 21 Feb 2013 18:04:37 +0100
> Geert Janssens <janssens-geert at telenet.be> wrote:
>
>> Op 21-02-13 16:54, Mike Evans schreef:
>>> A git|svn|brain issue follows.
>>>
>>> Having updated to the latest source using git-update script I can't
>>> change branches because some of the files have the wrong line
>>> endings, unless I commit the changes.
>>> I get this message:
>>> "Please, commit your changes or stash them before you can switch
>>> branches."
>>>
>>> Git stash doesn't work and I get similar output to that shown below.
>>>
>>> A git diff gives the following output.
>>>
>>> warning: CRLF will be replaced by LF in
>>> src/report/jqplot/excanvas.min.js. The file will have its original
>>> line endings in your working directory. warning: CRLF will be
>>> replaced by LF in src/report/jqplot/jquery.jqplot.min.js. The file
>>> will have its original line endings in your working directory.
> SNIP
>>> src/report/jqplot/plugins/jqplot.ciParser.min.js. The file will
>>> have its original line endings in your working directory. diff
>>> --git src/report/jqplot/excanvas.min.js
>>> src/report/jqplot/excanvas.min.js index 83373a5..e699a26 100644 ---
>>> src/report/jqplot/excanvas.min.js +++
>>> src/report/jqplot/excanvas.min.js @@ -1,3 +1,3 @@ -/* jqPlot
>>> @VERSION | (c) 2009-2013 Chris Leonello | jplot.com
>>> -   jsDate | (c) 2010-2013 Chris Leonello
>>> +/* jqPlot @VERSION | (c) 2009-2013 Chris Leonello | jplot.com
>>> +   jsDate | (c) 2010-2013 Chris Leonello
>>>
>>>
>>> Um.  Not sure what to do or why this situation occurred in the
>>> first place. I thought git took care of line ending translations.
>>>     
>>> I can commmit locally then dcommit but is that going to screw it up
>>> for anyone else?
>>>
>>> Advice needed.  My love/hate relationship with GIT continues.
>>>
>>>
>>> Mike Evans
>>>
>> Mike,
>>
>> These happen because the git configuration didn't have a definition
>> for the line ending style for javascript files (.js). While working
>> on the charts I added this definition. Some files that were already
>> in git before now are checked out with different line endings.
>>
>> Can you try to run
>> git checkout src/report/jqplot/*.js
>> git checkout src/report/jqplot/plugins/*.js
>>
>> Does that fix the issue ?
>>
>> Geert
> Hi Geert
>
> Afraid not.  Can I modify my config file manually?  What do I add|change
> if so?
>
> Mike E
It looks like the solution needs slightly more work. Read the part 
"Re-normalizing a repo" on this page:

https://help.github.com/articles/dealing-with-line-endings

Be sure to commit or stash your real changes before following this 
procedure. If at the end there are still files complaining about CRLF vs 
LF, you commit those. That would mean I have messed up in my commit.

Geert


More information about the gnucash-devel mailing list