원클릭으로
dotnet-enable-autocomplete
Enables tab autocomplete for the dotnet CLI. Use when the user wants to set up shell completion for dotnet commands.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Enables tab autocomplete for the dotnet CLI. Use when the user wants to set up shell completion for dotnet commands.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Analyzes and configures a .NET project or solution for Native AOT compatibility. Orchestrates source generator skills and applies AOT settings.
Converts a .NET solution to use Central Package Management (CPM). Use when the user wants to centralize, consolidate, or unify NuGet package versions across projects.
Enables the Microsoft Testing Platform runner in global.json. Use when the user wants to enable or migrate to the new .NET testing platform.
Configures polymorphic JSON serialization with [JsonPolymorphic] and [JsonDerivedType] attributes
Configures System.Text.Json source generation for AOT-compatible JSON serialization
Converts logging to use the LoggerMessage source generator for high-performance, AOT-compatible logging. Use when the user wants to optimize logging or organize log messages.
| name | dotnet-enable-autocomplete |
| description | Enables tab autocomplete for the dotnet CLI. Use when the user wants to set up shell completion for dotnet commands. |
| license | MIT |
| metadata | {"author":"Im5tu","version":"1.0","repositoryUrl":"https://github.com/im5tu/dotnet-skills"} |
| allowed-tools | Bash(dotnet:*) Read AskUserQuestion |
Enable tab autocomplete for the dotnet CLI in your preferred shell.
Determine .NET version (CRITICAL - commands differ by version)
dotnet sdk check
dotnet completions script <shell> (native completions)dotnet complete --position (dynamic completions)Ask user which shells they use, allowing multi-select:
For each user shell:
Detect profile file location based on shell:
| Shell | Profile Path |
|---|---|
| PowerShell | $PROFILE |
| bash | ~/.bashrc |
| zsh | ~/.zshrc |
| fish | ~/.config/fish/config.fish |
| nushell | ~/.config/nushell/config.nu |
Check if completion already configured
Append completion script to profile based on .NET version and shell
Inform user to restart their shell or source the profile
PowerShell:
dotnet completions script pwsh | Out-String | Invoke-Expression
bash:
eval "$(dotnet completions script bash)"
zsh:
eval "$(dotnet completions script zsh)"
fish:
dotnet completions script fish | source
nushell: See .NET CLI docs for config.nu setup.
PowerShell:
# dotnet CLI tab completion
Register-ArgumentCompleter -Native -CommandName dotnet -ScriptBlock {
param($wordToComplete, $commandAst, $cursorPosition)
dotnet complete --position $cursorPosition "$commandAst" | ForEach-Object {
[System.Management.Automation.CompletionResult]::new($_, $_, 'ParameterValue', $_)
}
}
bash:
# dotnet CLI tab completion
_dotnet_bash_complete() {
local cur="${COMP_WORDS[COMP_CWORD]}"
local IFS=$'\n'
local candidates
read -d '' -ra candidates < <(dotnet complete --position "${COMP_POINT}" "${COMP_LINE}" 2>/dev/null)
read -d '' -ra COMPREPLY < <(compgen -W "${candidates[*]}" -- "$cur")
}
complete -f -F _dotnet_bash_complete dotnet
zsh:
# dotnet CLI tab completion
_dotnet_zsh_complete() {
local completions=("$(dotnet complete --position ${CURSOR} "${BUFFER}" 2>/dev/null)")
reply=("${(ps:\n:)completions}")
}
compctl -K _dotnet_zsh_complete dotnet
fish:
# dotnet CLI tab completion
complete -f -c dotnet -a "(dotnet complete --position (commandline -cp) (commandline -op))"
nushell:
# Add to external_completer in config.nu
let external_completer = {|spans|
match $spans.0 {
dotnet => (
dotnet complete (
$spans | skip 1 | str join " "
) | lines
)
}
}
dotnet sdk check fails: Ensure .NET SDK is installeddotnet completions commanddotnet complete with dynamic scripts