Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 16 additions & 3 deletions custom-completions/dotnet/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# .NET CLI completions

Completions for the .NET CLI (`dotnet`), which comes with .NET SDK.

.NET is, to quote the official documentation, an "open-source developer platform for building many different types of applications".

For more information, see
Expand All @@ -9,6 +10,18 @@ For more information, see
- [CLI documentation](https://learn.microsoft.com/en-us/dotnet/core/tools/),
- [General dotnet documentation](https://learn.microsoft.com/en-us/dotnet/fundamentals/).

This plugin uses built-in `dotnet complete` command, which unfortunately does not provide comments for the completions.
On the other hand, it is officially supported, and completions are always in sync with the installed .NET SDK.
For hand-crafted completions, see ones generated from Fish: (../auto-generate/completions/dotnet.nu).
## SDK dependency and Limitations

This plugin uses built-in `dotnet complete` command. Unfortunately, it does not cover all capabilities of Nushell, like completion comments.
(See [capabilities](https://learn.microsoft.com/en-us/dotnet/core/tools/enable-tab-autocomplete#completion-capabilities).)

Despite being the official, native, integrated completion mechanism, `dotnet complete` may not cover all commands.
For example, version 10.0.100 does not cover the new `dotnet completions` commands.

For hand-crafted completions, see other completions like the ones generated from Fish located in (../auto-generate/completions/dotnet.nu).

## .NET SDK 10 and `dotnet completions`

From the .NET SDK version 10 onwards, the `dotnet` CLI offers `dotnet completions script nushell` which generaltes a Nushell external completer configuration,
but in an outdated format.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. end line in comma then start the last part of a sentence on a new line?
  2. the last line isn't what i'd call helpful. the original syntax just needs to be figured out

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Markdown won't render the newline.

the original syntax just needs to be figured out

I don't get what you mean

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm saying what was previously there would probably work if it were updated to $env.config

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What I had there previously is the output from dotnet. Changing the code would defeat the purpose of showing what dotnet prints out.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Having non-working code in the help is also defeating the purpose. We need a PR to the dotnet repo too to fix their incorrect AI.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, that's what I'm saying and why I chose to drop it instead

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just don't agree with leaving it at "is an outdated format", we should say what the format should be so people can refer to it and someone could submit a PR to the dotnet docs repo.

As such, it can not be used with current Nushell versions.