[Bug] Edits done by Copilot should honor the property "line.separator" or the files lineDelimiter. · Issue #48 · eclipse-copilot/eclipse-copilot · GitHub
Skip to content

[Bug] Edits done by Copilot should honor the property "line.separator" or the files lineDelimiter. #48

Open

Description

@HHartvig

Environment

  • OS: Windows
  • Eclipse Version: 4.31
  • Plugin Version: 0.11

When Copilot makes edit to your code either via Agent or directly in the editor spanning across multiple lines, it seems that a default line delimiter character is used. Running on Windows our SCM expects line delimiters to be "\r\n", but this is not what Copilots adds to the code, hence the SCM complains about this when pushing change.

You would most likely have to debug to see that Copilot add "\n" or "\r" as default line delimiter.

I would expect that System.getProperty("line.separator") or Document.getLineDeimiter(0), or something like that would be used instead, and if those return null you can fallback to default line delimiter.

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

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions