Template file line-endings are inconsistent

• Mar 30, 2011 - 23:10
Reported version
2.1
Type
Functional
Severity
S4 - Minor
Status
closed
Project

The files:
instruments-band.xml
instruments_ca.xml
instruments_nl.xml
instruments_pt.xml

Have a mixture of Windows (CR/LF) and Unix (LF) Line-endings. The attached file has the line-endings updated to Unix style.

Attachment Size
instruments.zip 26.5 KB

Comments

I don't know whether this is still an issue or not, but it seems like an easy one that I can handle. I am assigning it to myself so that I don't forget about it, and will look into it later.

Reported version 3.0 2.1

instruments_ca.xml, instruments_nl.xml, instruments_pt.xml etc. sine 2.0 no longer exist, only instruments_XX.ts and instruments_XX.qm, these get generated from instruments.xml and instruments_xml.h via a Python script and lupdate/lrelease

instruments-band.xml still exists in the source tree, but since 2.0 is no longer part of the Installation. I can't seen and CR/LF glitches in it, but even if, it is unused and probably should just get deleted from the source repo

Status (old) active patch (code needs review)

see https://github.com/musescore/MuseScore/pull/2805

It does change line endings too for files that are using in Windows only, some .bat files for example, this probably (I haven't test, but command.com is pretty picky on this IIRC) renders them useless for use under Windows, which is their only purpose in life.

That PR contains a huge amont of changes for no obvious benefit.
If we want UNIX line feeds only in the repo, but need other style line feeds in Windows (or on Mac) git can do this conversion for us automagically.

Also I'd rather change files' line endings only if and when there is a real issue with them, or maybe as a 'side effect' of some other change to the file, similar to changing the copyright date or changing from Qt's foreach(a, b) to C++11's for(a : ab) or to using the new style isELEMENT()()/toELEMENT() macros.

The issue at hand here really is just to get rid of instruments-band.xml

I can modify my pull request so that only *.xml files are affected, since that was the original issue. I agree - the change isn't "important", but I suppose consistency doesn't hurt anything. I'll also get rid of instruments-band.xml as part of the PR.

For my future reference - when a PR is submitted for an issue, should the status be changed to "patch (code needs review)"?

Only modify (and deleting) XML files should be better. Unless there are needed to test whether MuseScore imports them (MusicXML) correctly regardless of their line endings. So it depends...

And yes, "patch (code needs review)" or "patch (ready to commit)" IMHO is the status meant to be used after a PR has been made

Cool, it looks like these are the files then:

  • ./mtest/build.xml
  • ./share/instruments/instruments-band.xml
  • ./share/locale/languages.xml
  • ./share/styles/cchords_muse.xml
  • ./share/styles/cchords_nrb.xml
  • ./share/styles/cchords_rb.xml
  • ./share/styles/cchords_sym.xml
  • ./share/styles/chords.xml
  • ./share/styles/jazzchords.xml
  • ./test/lilyXml/00l-Basics-MultiMeasureRests.xml
  • ./test/lilyXml/03a-Directions-MusicXML.xml
  • ./test/lilyXml/03b-AccordionRegistrations-MusicXML.xml
  • ./test/lilyXml/04a-Spanners-Finale.xml
  • ./test/lilyXml/05a-HeaderQuotes-Finale.xml
  • ./test/lilyXml/06a-Lyrics-Finale.xml
  • ./test/lilyXml/06c-Lyrics-Pianostaff-Finale.xml
  • ./test/lilyXml/06d-Lyrics-Melisma-Finale.xml
  • ./test/lilyXml/06e-Lyrics-Chords-Finale.xml
  • . /test/lilyXml/06f-Lyrics-GracedNotes-Finale.xml
  • ./test/lilyXml/08g-OverlappingPartGroups-Finale.xml
  • ./test/lilyXml/09a-SimpleRepeat-Finale.xml
  • ./test/lilyXml/09b-RepeatWithAlternatives-Finale.xml
  • ./test/lilyXml/09c-Barlines-Finale.xml
  • ./test/lilyXml/09d-RepeatMultipleTimes-Finale.xml
  • ./test/lilyXml/09e-Alternatives-Finale.xml
  • ./test/lilyXml/09f-Repeats-Finale.xml
  • ./test/lilyXml/09g-Endings-Finale.xml
  • ./test/lilyXml/09h-RepeatsNoEndBar-Finale.xml
  • ./test/lilyXml/09k-Upbeats-ImplicitMeasures-Finale.xml
  • ./test/lilyXml/10a-TwoVoicesOnStaff-Finale.xml
  • ./test/lilyXml/14c-StaffChange-Finale.xml
  • ./test/lilyXml/17a-Chords-Finale.xml
  • ./test/lilyXml/17b-Fretboards-Finale.xml
  • ./test/lilyXml/17c-ChordsFrets-Finale.xml
  • ./test/lilyXml/17d-ChordsFretsOnMultistaff-Finale.xml
  • ./test/lilyXml/17e-TabStaves-Finale.xml
  • ./test/lilyXml/17f-AllChordTypes.xml
Status (old) patch (code needs review) closed

This was deemed useless and unimportant by lasconic. Therefore, I am closing the issue and the PR.

The EOL is a non issue, MuseScore compiles and work with or without the windows EOL.
If you find some files that are not needed, please make an issue and a PR to delete it.