Skip to content

Add an explicit command to convert line endings (CRLF / LF) #72

Description

@janitor-manager

Request

Sideleaf keeps the line endings of every file byte-for-byte (see #71). It never converts CRLF to LF or LF to CRLF silently. Add an explicit, user-invoked command that converts the current document to LF or to CRLF.

Open questions

  • Placement: a menu item (Edit or Format), the command palette, a status-bar indicator that shows the current ending, or a CLI subcommand.
  • Mixed endings: show them, and let the user normalize them with the same command.
  • Also consider a trailing newline and a UTF-8 BOM, with the same explicit-only rule.

Done when

The user can see the line-ending style of a document and convert it deliberately. The change is one undoable edit. No other path changes line endings.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions