Skip to content

Not reading CLI variables (v14.5.0) #5238

@MoeHamdan

Description

@MoeHamdan

Describe the bug

Nswag run command line not reading variables correctly anymore with version 14.5

To Reproduce

nswag run /runtime:Net80 /variables:Configuration=Release

now producing this error:
NConsole.UnusedArgumentException: Unrecognised arguments are present: []
at NConsole.CommandLineProcessor.ProcessSingleAsync(String[] args, Object input)
at NConsole.CommandLineProcessor.ProcessAsync(String[] args, Object input)
at NSwag.Commands.NSwagCommandProcessor.ProcessAsync(String[] args) in /_/src/NSwag.Commands/NSwagCommandProcessor.cs:line 61

The problem is with /variables:Configuration=Release
"nswag run /runtime:Net80" works fine without the /variables.

What makes it interesting is that adding extra "/" at the end makes it work
so for example if I execute this: nswag run /runtime:Net80 /variables:Configuration=Release /
it works fine

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions