Skip to content
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

feat(core): enhance repl '.help' command with nestjs functions #10608

Merged

Conversation

micalevisk
Copy link
Member

@micalevisk micalevisk commented Nov 28, 2022

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Other... Please describe:

What is the current behavior?

when using the REPL, typing .help only displays nodejs REPL commands

image

What is the new behavior?

People that are used with Node.js REPL are aware of the .help command and could try to use it in their Nest REPL. As a DX improvement, help() native function's output could be shown when using .help alongside with all available commands. Like this:

image

Another improvement on the .help command: if the user supplies an arg to it (eg: .help save or .hepl debug), the help message will be shown instead.

Now we got several ways to view helper messages on nestjs REPL.

Does this PR introduce a breaking change?

  • Yes
  • No

@coveralls
Copy link

coveralls commented Nov 28, 2022

Pull Request Test Coverage Report for Build 05b66a2e-5791-42d8-b42a-d6f7ff175a3e

  • 2 of 19 (10.53%) changed or added relevant lines in 2 files are covered.
  • 1 unchanged line in 1 file lost coverage.
  • Overall coverage decreased (-0.2%) to 93.167%

Changes Missing Coverage Covered Lines Changed/Added Lines %
packages/core/repl/repl.ts 1 2 50.0%
packages/core/repl/repl-native-commands.ts 1 17 5.88%
Files with Coverage Reduction New Missed Lines %
packages/core/repl/repl.ts 1 50.0%
Totals Coverage Status
Change from base Build a213a525-4c5b-48ee-9803-b76e72178509: -0.2%
Covered Lines: 6204
Relevant Lines: 6659

💛 - Coveralls

@micalevisk micalevisk force-pushed the feat/enhance-native-help-command-repl branch from 0d4c10d to f2dffaa Compare November 28, 2022 04:21
@kamilmysliwiec
Copy link
Member

lgtm

@micalevisk micalevisk deleted the feat/enhance-native-help-command-repl branch February 1, 2023 10:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants