-
Notifications
You must be signed in to change notification settings - Fork 7.1k
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
Enable experimental feature to support tab completion on abbreviated cmdlets #8109
Conversation
c5c5351
to
8e113da
Compare
de630aa
to
b95ae6d
Compare
This needs another |
b95ae6d
to
d7721be
Compare
@daxian-dbw @BrucePay This PR needs your review. |
This PR has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed if no further activity occurs within 10 days. |
d7721be
to
af7ea4e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there's nothing in my comments which are blocking, but I am worried about the case where we have an error (CompletionCompleters, line 193)
src/System.Management.Automation/engine/CommandCompletion/CompletionCompleters.cs
Outdated
Show resolved
Hide resolved
test/powershell/Modules/Microsoft.PowerShell.Utility/Get-Command.Tests.ps1
Outdated
Show resolved
Hide resolved
test/powershell/Modules/Microsoft.PowerShell.Utility/Get-Command.Tests.ps1
Outdated
Show resolved
Hide resolved
src/System.Management.Automation/engine/CommandCompletion/CompletionCompleters.cs
Outdated
Show resolved
Hide resolved
src/System.Management.Automation/engine/CommandCompletion/CompletionCompleters.cs
Outdated
Show resolved
Hide resolved
24c1d29
to
f130bd9
Compare
src/System.Management.Automation/engine/CommandCompletion/CompletionCompleters.cs
Outdated
Show resolved
Hide resolved
68d927c
to
0893d7c
Compare
248961b
to
9138e21
Compare
@SteveL-MSFT There is one comment pending #8109 (comment), can you please respond to it? |
fixed code to support returning multiple results and not just first one added test for automoduleloading which also covers multiple results from different modules
9138e21
to
dc7739e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@daxian-dbw Do we add experimental features to Change log? Do we need set |
Re-add wildcard when searching AST + Missed test case. ## PR Context In #8109, we removed the line that added a wildcard to the end of the command that was used to match commands in the script AST. This readds that line closer to where it is used.
Re-add wildcard when searching AST + Missed test case. ## PR Context In #8109, we removed the line that added a wildcard to the end of the command that was used to match commands in the script AST. This readds that line closer to where it is used.
PR Summary
While watching some demos at PSConfAsia, it's obvious that cmdlet nouns have gotten descriptive and wordy (Azure and AWS are good examples). This
experimental
feature enables tab-completion of abbreviated cmdlets and functions:Note that this only works for tab completion (interactive use), so
i-psdf
is still an invalid cmdlet name in scripts.The matching is entirely based on the capital letters of the verb and noun. To test this, create test.json:
And run:
Associated RFC
PR Checklist
.h
,.cpp
,.cs
,.ps1
and.psm1
files have the correct copyright headerWIP:
to the beginning of the title and remove the prefix when the PR is ready.[feature]
if the change is significant or affects feature tests