Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
0e0e0dc
Add System.CommandLine.StaticCompletions project
slang25 Apr 16, 2026
19c194f
Merge branch 'main' into slang25/static-completions
slang25 Apr 17, 2026
3c361ae
Use [suggest] directive for dynamic completions
slang25 Apr 17, 2026
2ba8e19
Make dynamic completion invocation configurable
slang25 Apr 17, 2026
0402530
Drop stale dotnet references in docs and comments
slang25 Apr 17, 2026
ab2e46e
Drop configurable CompletionInvocation; inline [suggest] directive
slang25 Apr 22, 2026
955e8c2
Update dependencies from build 320196
dotnet-maestro[bot] Jun 27, 2026
71f7724
Update dependencies from build 320520
dotnet-maestro[bot] Jun 28, 2026
e546097
Update dependencies from build 320578
dotnet-maestro[bot] Jun 29, 2026
e65ce12
Update dependencies from build 320799
dotnet-maestro[bot] Jun 30, 2026
283fc20
Backflow from https://github.com/dotnet/dotnet / a9679a8 build 320973
dotnet-maestro[bot] Jul 1, 2026
42aba6e
Update dependencies from build 320973
dotnet-maestro[bot] Jul 1, 2026
358819c
Update dependencies from build 321130
dotnet-maestro[bot] Jul 2, 2026
ae3c7e9
Merge remote-tracking branch 'origin/main' into static-completions-work
slang25 Jul 2, 2026
64bdd23
Sync fish and nushell providers with dotnet/sdk; warn when [suggest] …
slang25 Jul 2, 2026
7a0168b
Update dependencies from build 321265
dotnet-maestro[bot] Jul 3, 2026
2749c60
Update dependencies from build 321416
dotnet-maestro[bot] Jul 4, 2026
d78a4b1
Update dependencies from build 321469
dotnet-maestro[bot] Jul 6, 2026
1d9c537
Update src/System.CommandLine.StaticCompletions/System.CommandLine.St…
baronfel Jul 6, 2026
e68e953
Merge remote-tracking branch 'origin/main' into static-completions-work
slang25 Jul 6, 2026
9dbcf45
Merge remote-tracking branch 'fork/slang25/static-completions' into s…
slang25 Jul 6, 2026
d82fb83
Merge branch 'main' into darc-main-618890fd-928f-453a-8b0a-4acc43fdfc1e
baronfel Jul 6, 2026
0ae2631
Merge pull request #2799 from slang25/slang25/static-completions
baronfel Jul 6, 2026
08f4e83
Follow-up feedback from recently merged PR
ViktorHofer Jul 6, 2026
3602062
Merge pull request #2829 from ViktorHofer/ReactToMoreCleanup
baronfel Jul 6, 2026
4d41667
Add README for System.CommandLine.StaticCompletions package
baronfel Jul 6, 2026
85b7db9
Update src/System.CommandLine.StaticCompletions/README.md
baronfel Jul 6, 2026
21ad866
Merge pull request #2830 from dotnet/baronfel-staticcompletions-readme
baronfel Jul 6, 2026
11430a8
Merge main into darc-main-618890fd-928f-453a-8b0a-4acc43fdfc1e
dotnet-maestro[bot] Jul 7, 2026
d423c6a
Update dependencies from build 321546
dotnet-maestro[bot] Jul 7, 2026
8b00b7d
Merge pull request #2825 from dotnet/darc-main-618890fd-928f-453a-8b0…
baronfel Jul 7, 2026
bc16495
Merge pull request #2820 from jonsequitur/fix-2812
baronfel Jul 8, 2026
75e39ef
Expect NativeAOT lib prefix on Unix for .NET 11 SDK
baronfel Jul 8, 2026
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
4 changes: 3 additions & 1 deletion Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
<PackageVersion Include="AwesomeAssertions" Version="8.1.0" />
<PackageVersion Include="Microsoft.DotNet.PlatformAbstractions" Version="3.1.6" />
<PackageVersion Include="Newtonsoft.Json" Version="13.0.4" />
<PackageVersion Include="Verify.Xunit" Version="28.13.0" />
<PackageVersion Include="Verify.DiffPlex" Version="3.1.2" />
</ItemGroup>

</Project>
</Project>
4 changes: 4 additions & 0 deletions NuGet.config
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,8 @@
<add key="dotnet11" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet11/nuget/v3/index.json" />
</packageSources>
<disabledPackageSources />
<auditSources>
<clear />
<add key="nuget.org" value="https://data.nuget.org/v3/index.json" />
</auditSources>
</configuration>
2 changes: 2 additions & 0 deletions System.CommandLine.slnx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
</Folder>
<Folder Name="/src/">
<Project Path="src/System.CommandLine.ApiCompatibility.Tests/System.CommandLine.ApiCompatibility.Tests.csproj" />
<Project Path="src/System.CommandLine.StaticCompletions.Tests/System.CommandLine.StaticCompletions.Tests.csproj" />
<Project Path="src/System.CommandLine.StaticCompletions/System.CommandLine.StaticCompletions.csproj" />
<Project Path="src/System.CommandLine.Suggest.Tests/dotnet-suggest.Tests.csproj" />
<Project Path="src/System.CommandLine.Suggest/dotnet-suggest.csproj" />
<Project Path="src/System.CommandLine.Tests/System.CommandLine.Tests.csproj" />
Expand Down
2 changes: 1 addition & 1 deletion eng/Version.Details.props
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This file should be imported by eng/Versions.props
<Project>
<PropertyGroup>
<!-- dotnet-dotnet dependencies -->
<MicrosoftDotNetArcadeSdkPackageVersion>11.0.0-beta.26319.105</MicrosoftDotNetArcadeSdkPackageVersion>
<MicrosoftDotNetArcadeSdkPackageVersion>11.0.0-beta.26356.103</MicrosoftDotNetArcadeSdkPackageVersion>
</PropertyGroup>
<!--Property group for alternate package version names-->
<PropertyGroup>
Expand Down
6 changes: 3 additions & 3 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<Dependencies>
<Source Uri="https://github.com/dotnet/dotnet" Mapping="command-line-api" Sha="b756a8d8a0e64905e16c81911bb09a8110bc3395" BarId="319511" />
<Source Uri="https://github.com/dotnet/dotnet" Mapping="command-line-api" Sha="a67d575054ff3bcb905ea6699734d0ed8816aa2b" BarId="321546" />
<ProductDependencies>
</ProductDependencies>
<ToolsetDependencies>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="11.0.0-beta.26319.105">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="11.0.0-beta.26356.103">
<Uri>https://github.com/dotnet/dotnet</Uri>
<Sha>b756a8d8a0e64905e16c81911bb09a8110bc3395</Sha>
<Sha>a67d575054ff3bcb905ea6699734d0ed8816aa2b</Sha>
</Dependency>
</ToolsetDependencies>
</Dependencies>
2 changes: 1 addition & 1 deletion eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<PropertyGroup>
<VersionPrefix>3.0.0</VersionPrefix>
<PreReleaseVersionLabel>preview</PreReleaseVersionLabel>
<PreReleaseVersionIteration>6</PreReleaseVersionIteration>
<PreReleaseVersionIteration>7</PreReleaseVersionIteration>
<!-- Allowed values: '', 'prerelease', 'release'. Set to 'release' when stabilizing. -->
<DotNetFinalVersionKind></DotNetFinalVersionKind>
</PropertyGroup>
Expand Down
9 changes: 9 additions & 0 deletions eng/common/core-templates/job/helix-job-monitor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,14 @@ parameters:
type: number
default: 30

# When 'true' (the default), Helix work items that exit 0 but have failed AzDO test results
# are treated as failed: they count toward the monitor's exit code and are resubmitted by a
# later invocation's retry pass. Set to 'false' to fall back to exit-code-only outcomes.
# Forwarded as --fail-on-failed-tests.
- name: failWorkItemsWithFailedTests
type: boolean
default: true

# Advanced: optional pipeline artifact (produced earlier in this run) that contains the tool
# nupkg. When set, the artifact is downloaded and the tool is installed from the nupkg into
# a local tool-path; this bypasses the repo's .config/dotnet-tools.json manifest and is
Expand Down Expand Up @@ -170,6 +178,7 @@ jobs:
toolArgs=(
--helix-base-uri '${{ parameters.helixBaseUri }}'
--polling-interval-seconds '${{ parameters.pollingIntervalSeconds }}'
--fail-on-failed-tests '${{ parameters.failWorkItemsWithFailedTests }}'
--max-wait-minutes "$((${{ parameters.timeoutInMinutes }} - 5))" # Set the tool's timeout slightly lower than the Azure DevOps job timeout to allow it to exit gracefully.
--stage-name '$(System.StageName)'
)
Expand Down
22 changes: 20 additions & 2 deletions eng/common/core-templates/steps/send-to-helix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ parameters:
HelixConfiguration: '' # optional -- additional property attached to a job
HelixPreCommands: '' # optional -- commands to run before Helix work item execution
HelixPostCommands: '' # optional -- commands to run after Helix work item execution
UseHelixMonitor: false # optional -- true will submit Helix jobs configured for the standalone Helix Job Monitor (results are reported/waited on out-of-band; this step will not wait, and WaitForWorkItemCompletion will be overridden)
WorkItemDirectory: '' # optional -- a payload directory to zip up and send to Helix; requires WorkItemCommand; incompatible with XUnitProjects
WorkItemCommand: '' # optional -- a command to execute on the payload; requires WorkItemDirectory; incompatible with XUnitProjects
WorkItemTimeout: '' # optional -- a timeout in TimeSpan.Parse-ready value (e.g. 00:02:00) for the work item command; requires WorkItemDirectory; incompatible with XUnitProjects
Expand All @@ -31,7 +32,15 @@ parameters:
continueOnError: false # optional -- determines whether to continue the build if the step errors; defaults to false

steps:
- powershell: 'powershell "$env:BUILD_SOURCESDIRECTORY\eng\common\msbuild.ps1 $env:BUILD_SOURCESDIRECTORY/${{ parameters.HelixProjectPath }} /restore /p:TreatWarningsAsErrors=false ${{ parameters.HelixProjectArguments }} /t:Test /bl:$env:BUILD_SOURCESDIRECTORY\artifacts\log\$env:BuildConfig\SendToHelix.binlog"'
- powershell: >
$(Build.SourcesDirectory)\eng\common\msbuild.ps1
$(Build.SourcesDirectory)/${{ parameters.HelixProjectPath }}
/restore
/p:TreatWarningsAsErrors=false
/p:EnableHelixJobMonitor=${{ parameters.UseHelixMonitor }}
${{ parameters.HelixProjectArguments }}
/t:Test
/bl:$(Build.SourcesDirectory)/artifacts/log/$(_BuildConfig)/SendToHelix.binlog
displayName: ${{ parameters.DisplayNamePrefix }} (Windows)
env:
BuildConfig: $(_BuildConfig)
Expand Down Expand Up @@ -61,7 +70,15 @@ steps:
SYSTEM_ACCESSTOKEN: $(System.AccessToken)
condition: and(${{ parameters.condition }}, eq(variables['Agent.Os'], 'Windows_NT'))
continueOnError: ${{ parameters.continueOnError }}
- script: $BUILD_SOURCESDIRECTORY/eng/common/msbuild.sh $BUILD_SOURCESDIRECTORY/${{ parameters.HelixProjectPath }} /restore /p:TreatWarningsAsErrors=false ${{ parameters.HelixProjectArguments }} /t:Test /bl:$BUILD_SOURCESDIRECTORY/artifacts/log/$BuildConfig/SendToHelix.binlog
- script: >
$(Build.SourcesDirectory)/eng/common/msbuild.sh
$(Build.SourcesDirectory)/${{ parameters.HelixProjectPath }}
/restore
/p:TreatWarningsAsErrors=false
/p:EnableHelixJobMonitor=${{ parameters.UseHelixMonitor }}
${{ parameters.HelixProjectArguments }}
/t:Test
/bl:$(Build.SourcesDirectory)/artifacts/log/$(_BuildConfig)/SendToHelix.binlog
displayName: ${{ parameters.DisplayNamePrefix }} (Unix)
env:
BuildConfig: $(_BuildConfig)
Expand Down Expand Up @@ -91,3 +108,4 @@ steps:
SYSTEM_ACCESSTOKEN: $(System.AccessToken)
condition: and(${{ parameters.condition }}, ne(variables['Agent.Os'], 'Windows_NT'))
continueOnError: ${{ parameters.continueOnError }}

3 changes: 2 additions & 1 deletion eng/common/cross/build-rootfs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,9 @@ __FreeBSDPackages+=" terminfo-db"
__OpenBSDVersion="7.8"
__OpenBSDPackages="heimdal-libs"
__OpenBSDPackages+=" icu4c"
__OpenBSDPackages+=" inotify-tools"
__OpenBSDPackages+=" libinotify"
__OpenBSDPackages+=" openssl"
__OpenBSDPackages+=" e2fsprogs"

__IllumosPackages="icu"
__IllumosPackages+=" mit-krb5"
Expand Down
8 changes: 6 additions & 2 deletions eng/common/cross/install-debs.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,14 @@ async def fetch_release_file(session, mirror, suite, keyring):
await download_file(session, release_gpg_url, release_gpg_file.name)

print("Verifying signature of Release with Release.gpg.")
verify_command = ["gpg"]
# Use gpgv rather than gpg for verification. gpgv verifies a detached
# signature against a fixed keyring without involving gpg-agent or
# keyboxd, which makes it robust on hosts running GnuPG 2.4+ (e.g. Azure
# Linux) where "gpg --keyring" routes through keyboxd and can fail.
verify_command = ["gpgv"]
if keyring:
verify_command += ["--keyring", keyring]
verify_command += ["--verify", release_gpg_file.name, release_file.name]
verify_command += [release_gpg_file.name, release_file.name]
result = subprocess.run(verify_command, stdout=subprocess.PIPE, stderr=subprocess.PIPE)

if result.returncode != 0:
Expand Down
16 changes: 7 additions & 9 deletions eng/common/cross/toolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ elseif(TARGET_ARCH_NAME STREQUAL "arm64")
set(TIZEN_TOOLCHAIN "aarch64-tizen-linux-gnu")
endif()
elseif(FREEBSD)
set(triple "aarch64-unknown-freebsd12")
set(TOOLCHAIN "aarch64-unknown-freebsd14")
elseif(OPENBSD)
set(triple "aarch64-unknown-openbsd")
set(TOOLCHAIN "aarch64-unknown-openbsd")
endif()
elseif(TARGET_ARCH_NAME STREQUAL "armel")
set(CMAKE_SYSTEM_PROCESSOR armv7l)
Expand Down Expand Up @@ -117,9 +117,9 @@ elseif(TARGET_ARCH_NAME STREQUAL "x64")
set(TIZEN_TOOLCHAIN "x86_64-tizen-linux-gnu")
endif()
elseif(FREEBSD)
set(triple "x86_64-unknown-freebsd12")
set(TOOLCHAIN "x86_64-unknown-freebsd14")
elseif(OPENBSD)
set(triple "x86_64-unknown-openbsd")
set(TOOLCHAIN "x86_64-unknown-openbsd")
elseif(ILLUMOS)
set(TOOLCHAIN "x86_64-illumos")
elseif(HAIKU)
Expand Down Expand Up @@ -160,8 +160,6 @@ if(TIZEN)
find_toolchain_dir("${CROSS_ROOTFS}/usr/lib64/gcc/${TIZEN_TOOLCHAIN}")
endif()

message(STATUS "TIZEN_TOOLCHAIN_PATH set to: ${TIZEN_TOOLCHAIN_PATH}")

include_directories(SYSTEM ${TIZEN_TOOLCHAIN_PATH}/include/c++)
include_directories(SYSTEM ${TIZEN_TOOLCHAIN_PATH}/include/c++/${TIZEN_TOOLCHAIN})
endif()
Expand Down Expand Up @@ -206,9 +204,9 @@ if(ANDROID)
include(${CROSS_ROOTFS}/../build/cmake/android.toolchain.cmake)
elseif(FREEBSD OR OPENBSD)
# we cross-compile by instructing clang
set(CMAKE_C_COMPILER_TARGET ${triple})
set(CMAKE_CXX_COMPILER_TARGET ${triple})
set(CMAKE_ASM_COMPILER_TARGET ${triple})
set(CMAKE_C_COMPILER_TARGET ${TOOLCHAIN})
set(CMAKE_CXX_COMPILER_TARGET ${TOOLCHAIN})
set(CMAKE_ASM_COMPILER_TARGET ${TOOLCHAIN})
set(CMAKE_SYSROOT "${CROSS_ROOTFS}")
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fuse-ld=lld")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fuse-ld=lld")
Expand Down
2 changes: 2 additions & 0 deletions eng/common/native/NativeAotSupported.props
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
<!-- Reject unsupported architectures via RID suffix match -->
<_NativeAotSupportedArch Condition="
'$(TargetArchitecture)' != 'wasm' and
'$(TargetArchitecture)' != 's390x' and
'$(TargetArchitecture)' != 'ppc64le' and
('$(TargetArchitecture)' != 'x86' or '$(TargetOS)' == 'windows')
">true</_NativeAotSupportedArch>

Expand Down
7 changes: 0 additions & 7 deletions eng/common/tools.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -741,13 +741,6 @@ function MSBuild() {
Write-PipelineTelemetryError -Category 'Build' -Message 'Binary log must be enabled in CI build, or explicitly opted-out from with the -excludeCIBinarylog switch.'
ExitWithExitCode 1
}

# Node reuse must be disabled in CI builds unless explicitly opted in via MSBUILD_NODEREUSE_ENABLED.
# Internal testing only; this env var will be replaced with a switch (https://github.com/dotnet/arcade/issues/17013) and must not be depended on.
if ($nodeReuse -and $env:MSBUILD_NODEREUSE_ENABLED -ne "1") {
Write-PipelineTelemetryError -Category 'Build' -Message 'Node reuse must be disabled in CI build.'
ExitWithExitCode 1
}
}

$buildTool = InitializeBuildTool
Expand Down
14 changes: 4 additions & 10 deletions eng/common/tools.sh
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ function InitializeToolset {
if [[ -z "$nuget_config" ]]; then
# Search for any variation of nuget.config in the RepoRoot
local found_config
found_config=$(find "$repo_root" -maxdepth 1 -type f -iname "nuget.config" -print -quit)
found_config=$(find "$repo_root" -maxdepth 1 -type f -iname nuget.config | head -n 1)

if [[ -n "$found_config" ]]; then
nuget_config="$found_config"
Expand Down Expand Up @@ -466,7 +466,8 @@ function ExitWithExitCode {
function StopProcesses {
echo "Killing running build processes..."
pkill -9 "dotnet" || true
pkill -9 "vbcscompiler" || true
pkill -9 -i -x VBCSCompiler || true
pkill -9 -i -x MSBuild || true
return 0
}

Expand All @@ -493,14 +494,7 @@ function DotNet {
function MSBuild {
if [[ "$ci" == true ]]; then
if [[ "$binary_log" != true && "$exclude_ci_binary_log" != true ]]; then
Write-PipelineTelemetryError -category 'Build' "Binary log must be enabled in CI build, or explicitly opted-out from with the -noBinaryLog switch."
ExitWithExitCode 1
fi

# Node reuse must be disabled in CI builds unless explicitly opted in via MSBUILD_NODEREUSE_ENABLED.
# Internal testing only; this env var will be replaced with a switch (https://github.com/dotnet/arcade/issues/17013) and must not be depended on.
if [[ "$node_reuse" == true && "${MSBUILD_NODEREUSE_ENABLED:-}" != "1" ]]; then
Write-PipelineTelemetryError -category 'Build' "Node reuse must be disabled in CI build."
Write-PipelineTelemetryError -category 'Build' "Binary log must be enabled in CI build, or explicitly opted-out from with the --excludeCIBinarylog switch."
ExitWithExitCode 1
fi
fi
Expand Down
6 changes: 3 additions & 3 deletions global.json
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
{
"sdk": {
"version": "11.0.100-preview.5.26227.104",
"version": "11.0.100-preview.5.26302.115",
"allowPrerelease": true,
"rollForward": "major"
},
"tools": {
"dotnet": "11.0.100-preview.5.26227.104",
"dotnet": "11.0.100-preview.5.26302.115",
"runtimes": {
"dotnet": [
"10.0.2"
]
}
},
"msbuild-sdks": {
"Microsoft.DotNet.Arcade.Sdk": "11.0.0-beta.26319.105"
"Microsoft.DotNet.Arcade.Sdk": "11.0.0-beta.26356.103"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

#nullable disable

namespace System.CommandLine.StaticCompletions.Tests;

using System.CommandLine.StaticCompletions.Shells;

public class BashShellProviderTests(ITestOutputHelper log)
{
private IShellProvider provider = new BashShellProvider();
[Fact]
public async Task GenericCompletions()
{
await provider.Verify(new("mycommand"), log);
}

[Fact]
public async Task SimpleOptionCompletion()
{
await provider.Verify(new("mycommand") {
new Option<string>("--name")
}, log);
}

[Fact]
public async Task SubcommandAndOptionInTopLevelList()
{
await provider.Verify(new("mycommand") {
new Option<string>("--name"),
new Command("subcommand")
}, log);
}

[Fact]
public async Task NestedSubcommandCompletion()
{
await provider.Verify(new("mycommand") {
new Command("subcommand") {
new Command("nested")
}
}, log);
}

[Fact]
public async Task DynamicCompletionsGeneration()
{
var dynamicOption = new Option<string>("--name") { IsDynamic = true };
var dynamicArg = new Argument<string>("target") { IsDynamic = true };
await provider.Verify(new("mycommand") { dynamicOption, dynamicArg }, log);
}
}
Loading