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

Fix the help command to work with intrinsic commands. #1231

Merged
merged 1 commit into from Feb 16, 2016

Conversation

Projects
None yet
4 participants
@AustinWise
Contributor

AustinWise commented Feb 4, 2016

The old "dotnet help" code assumed every command is defined by a "dotnet-command" executable. However this is no longer true for intrinsic commands.

I tried this change out with both intrinsic and extrinsic commands and they now print help as expected.

I also added some tests to make sure the "dotnet help" command executes successfully.

@dnfclas

This comment has been minimized.

Show comment
Hide comment
@dnfclas

dnfclas Feb 4, 2016

Hi @AustinWise, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!

The agreement was validated by .NET Foundation and real humans are currently evaluating your PR.

TTYL, DNFBOT;

dnfclas commented Feb 4, 2016

Hi @AustinWise, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!

The agreement was validated by .NET Foundation and real humans are currently evaluating your PR.

TTYL, DNFBOT;

@AustinWise

This comment has been minimized.

Show comment
Hide comment
@AustinWise

AustinWise Feb 4, 2016

Contributor

The OS X build failed for an odd reason (build log said git was not installed). I rebased onto the tip of 1.0.0 and pushed to get it to try building again.

Contributor

AustinWise commented Feb 4, 2016

The OS X build failed for an odd reason (build log said git was not installed). I rebased onto the tip of 1.0.0 and pushed to get it to try building again.

Show outdated Hide outdated src/dotnet/Program.cs
Show outdated Hide outdated src/dotnet/Program.cs
Show outdated Hide outdated src/dotnet/Program.cs
@AustinWise

This comment has been minimized.

Show comment
Hide comment
@AustinWise

AustinWise Feb 5, 2016

Contributor

I push a new commit wherein I moved made 'help' be a command like any other. That seems cleaner than making Cli.Program pretend a help command exists.

I assume the plan is eventually make the help command more like Git's, i.e. show a manpage on Unix and open the documentation in a browser on Windows. So while the HelpCommand class is very small now, it should be big enough to justify its existence in the future.

Contributor

AustinWise commented Feb 5, 2016

I push a new commit wherein I moved made 'help' be a command like any other. That seems cleaner than making Cli.Program pretend a help command exists.

I assume the plan is eventually make the help command more like Git's, i.e. show a manpage on Unix and open the documentation in a browser on Windows. So while the HelpCommand class is very small now, it should be big enough to justify its existence in the future.

@AustinWise

This comment has been minimized.

Show comment
Hide comment
@AustinWise

AustinWise Feb 5, 2016

Contributor

I tried moving moving more of the help functions into the HelpCommand. This way the control flow is more consistently from Program to HelpCommand, which seems to make more sense than have HelpCommand call back to Program.

Contributor

AustinWise commented Feb 5, 2016

I tried moving moving more of the help functions into the HelpCommand. This way the control flow is more consistently from Program to HelpCommand, which seems to make more sense than have HelpCommand call back to Program.

@AustinWise

This comment has been minimized.

Show comment
Hide comment
@AustinWise

AustinWise Feb 5, 2016

Contributor

@dotnet-bot test this please
It seems like package restore failed.

Contributor

AustinWise commented Feb 5, 2016

@dotnet-bot test this please
It seems like package restore failed.

@davidfowl

This comment has been minimized.

Show comment
Hide comment
@davidfowl

davidfowl Feb 16, 2016

Collaborator

This needs another rebase 😢

Collaborator

davidfowl commented Feb 16, 2016

This needs another rebase 😢

Move the help command it it's own class.
Also fix the help command to work with intrinsic commands.
@AustinWise

This comment has been minimized.

Show comment
Hide comment
@AustinWise

AustinWise Feb 16, 2016

Contributor

@davidfowl I rebased and squashed the commits.

Contributor

AustinWise commented Feb 16, 2016

@davidfowl I rebased and squashed the commits.

@davidfowl

This comment has been minimized.

Show comment
Hide comment
@davidfowl

davidfowl Feb 16, 2016

Collaborator

So the command is dotnet help {command} which translates into dotnet-{command} --help should help be listed as a top level command?

Collaborator

davidfowl commented Feb 16, 2016

So the command is dotnet help {command} which translates into dotnet-{command} --help should help be listed as a top level command?

davidfowl added a commit that referenced this pull request Feb 16, 2016

Merge pull request #1231 from AustinWise/fixHelp
Fix the help command to work with intrinsic commands.

@davidfowl davidfowl merged commit 1e18150 into dotnet:rel/1.0.0 Feb 16, 2016

8 checks passed

CentOS7.1 Debug Build Build finished. 136 tests run, 1 skipped, 0 failed.
Details
CentOS7.1 Release Build Build finished. 136 tests run, 1 skipped, 0 failed.
Details
OSX Debug Build Build finished. 136 tests run, 1 skipped, 0 failed.
Details
OSX Release Build Build finished. 136 tests run, 1 skipped, 0 failed.
Details
Ubuntu Debug Build Build finished. 136 tests run, 1 skipped, 0 failed.
Details
Ubuntu Release Build Build finished. 136 tests run, 1 skipped, 0 failed.
Details
Windows_NT Debug Build Build finished. 136 tests run, 0 skipped, 0 failed.
Details
Windows_NT Release Build Build finished. 136 tests run, 0 skipped, 0 failed.
Details

wli3 pushed a commit to wli3/cli that referenced this pull request Jul 14, 2017

Merge pull request #1231 from eerhardt/ProfilingSymbols
Create profiling symbols by default.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment