Skip to content

Odd option "-lang" in "dotnet new --help" #4277

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
am11 opened this issue Dec 10, 2019 · 0 comments
Open

Odd option "-lang" in "dotnet new --help" #4277

am11 opened this issue Dec 10, 2019 · 0 comments

Comments

@am11
Copy link
Member

am11 commented Dec 10, 2019

Steps to reproduce

dotnet new --help

Expected behavior

should not have -lang as a shorthand for --language, which is sufficient on its own:

.. snip ..
  --language   Filters templates based on language and specifies the language of the template to create.
.. snip ..

Actual behavior

has -lang, --language, which is a odd one out as the convention is to either have "single character followed by a single hyphen" and/or "full name after double hyphen".

FWIW, gcc and clang use -x to specify language:

// C++
gcc -x c++ -O -Wall -o myapp.exe /dev/stdin <<<"int main(){return 0;}"

// or C

clang -x c -O -Wall -o myapp.exe /dev/stdin <<<"int main(void){return 0;}"

which dotnet-new can use as well.

Environment data

dotnet --info output:

.NET Core SDK (reflecting any global.json):
 Version:   3.1.100
 Commit:    cd82f021f4

Runtime Environment:
 OS Name:     Mac OS X
 OS Version:  10.14
 OS Platform: Darwin
 RID:         osx.10.14-x64
 Base Path:   /Users/adeel/.dotnet/sdk/3.1.100/

Host (useful for support):
  Version: 3.1.0
  Commit:  65f04fb6db
@msftgits msftgits transferred this issue from dotnet/toolset Jan 31, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant