Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-14186

Ensure Windows files retain CRLF endings

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: master (9.0), 8.4
    • Fix Version/s: master (9.0), 8.5, 8.4.2
    • Component/s: scripts and tools
    • Labels:
      None

      Description

      We've had several recent instances where our Windows files (solr.cmd, solr.in.cmd) end up getting their Windows-specific line-endings stripped out. This causes chunks of those scripts to fail when run on Windows.

      e.g. SOLR-13977 fixed an issue where bin\solr.cmd create -c failed, and the problem was fixed and recurred again within a week.

      Generally, contributors/committers can prevent this by setting their core.autocrlf git setting to input. But we should also put repository-wide settings in place exempting certain files from line-ending conversion entirely.

      This issue proposes adding a .gitattributes setting to special-case OS-specific files (bash scripts, Windows batch files, etc.) This will prevent solr.cmd's line endings from being changed by committers who forget to configure the setting on a new machine, etc.

        Attachments

          Activity

            People

            • Assignee:
              gerlowskija Jason Gerlowski
              Reporter:
              gerlowskija Jason Gerlowski
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 2h 40m
                2h 40m