Find inconsistent line endings in CotEditor on Mac

CotEditor automatically detects line endings inconsistent with the document line ending setting. Inconsistent line endings can cause problems in various ways, such as running a script.

Detect line endings in the document

When a document is opened, CotEditor automatically inspects its line endings and uses the most common one as the document line ending.

If the document contains multiple types of line endings, CotEditor warns you. In the dialog, you can choose whether to convert all inconsistent line endings to the most common one or leave them as they are so you can review them first.

If you select the “Don’t ask again for this document” checkbox, the warning dialog no longer appears for that document. To suppress this warning for all documents, go to General settings > Manage Warnings, then turn on “Inconsistent line endings.”

Look over the location of inconsistent line endings

  1. In the CotEditor app on your Mac, open a document.

  2. Choose View > Inspector > Warnings.

    The Warnings inspector lists all the line endings inconsistent with the document line ending.

Find inconsistent line endings in the editor

When line endings are shown as invisible characters, inconsistent line endings are drawn in a different color from other invisible characters. See Show invisible characters for instructions on how to change their visibility.

Normalize line endings

You can convert all line endings including inconsistent ones to a single line ending type by selecting the document line ending in the Line Endings menu in the Format menu or the status bar.

See also