commandlineparser / commandlineparser/commandline

Bug: \r\n not removed for last argument

Open
#144 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
C#
Stars
4.8k
Forks
478
PR merge metrics
No merged PRs in 30d

Description

**Issue by [Stretto](https://github.com/Stretto)**
_Saturday Jun 17, 2017 at 09:54 GMT_
_Originally opened as https://github.com/gsscoder/commandline/issues/453_

----

I have an app that works fine when ran from the console but fails in visual studio. Seems the last 2 characters a single command, like "app --late" is "--late\r\n" which breaks the parser.

Adding

for(var i = 0; i < args.Length; i++)
args[i] = args[i].Trim('\n','\r');

allows it to work.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.