Skip to content
This repository was archived by the owner on Jul 12, 2022. It is now read-only.

Added new rule for newline at end of file #61

Closed
wants to merge 1 commit into from

Conversation

khellang
Copy link
Member

This does the following:

  1. Removes all trailing EndOfLine trivia from the last node of the document.
  2. Replaces all leading EndOfLine trivia on the EndOfFile token with a single CarriageReturnLineFeed trivia.

Fixes #54

This does the following:
  1. Removes all trailing EndOfLine trivia from the last node of the
  document.
  2. Replaces all leading EndOfLine trivia on the EndOfFile token with a
  single CarriageReturnLineFeed trivia.

Fixes dotnet#54
@dnfclas
Copy link

dnfclas commented Feb 13, 2015

Hi @khellang, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!

In order for us to evaluate and accept your PR, we ask that you sign a contribution license agreement. It's all electronic and will take just minutes. I promise there's no faxing. https://cla2.dotnetfoundation.org.

TTYL, DNFBOT;

@dnfclas
Copy link

dnfclas commented Feb 13, 2015

@khellang, Thanks for signing the contribution license agreement so quickly! Actual humans will now validate the agreement and then evaluate the PR.

Thanks, DNFBOT;

syntaxRoot = syntaxRoot.ReplaceNode(node, RemoveNewLines(node));
}

var token = syntaxRoot.DescendantTokens().Single(x => x.IsKind(SyntaxKind.EndOfFileToken));

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add final newline to code files
5 participants