Skip to content

Unix/Linux line endings in CLI need to be enforced #2800

@ScottFreeCode

Description

@ScottFreeCode

bin/mocha and bin/_mocha need to have Unix line endings. Currently Git's autocrlf setting can screw this up. (See also #2799 for an example of when this goes wrong.) Our tests don't check for it either.

We will need to either check for or fix the line endings in these files as part of publishing. Or, if doing it on publish isn't feasible (prepublish vs. prepublishOnly seems to be a bit of an issue?), on version (most of our other publishing prep is in versioning already anyway...).

Ideally, I'd like to just run a Node command and convert the line endings, so it doesn't matter what Git did (or the user, etc) -- this isn't something that should have to be fixed manually when it is detected.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: windowsWindows-specificstatus: needs upstream fixdefect within Mocha's dependency treetype: choregenerally involving deps, tooling, configuration, etc.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions