Skip to content

Commit

Permalink
Merge branch 'main' into feat/search-improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
frarees authored Nov 4, 2024
2 parents c85bd41 + 7f7afad commit 9fc9483
Show file tree
Hide file tree
Showing 379 changed files with 21,330 additions and 17,782 deletions.
3 changes: 2 additions & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,8 @@ csharp_prefer_simple_using_statement = false:none # IDE006
csharp_using_directive_placement = outside_namespace:suggestion # IDE0065: using directive placement

# File header preferences
file_header_template = unset # IDE0073: Require file header
dotnet_diagnostic.IDE0073.severity = warning # IDE0073: Require file header
file_header_template = Licensed to the .NET Foundation under one or more agreements.\nThe .NET Foundation licenses this file to you under the MIT license.

# Namespace naming preferences
dotnet_style_namespace_match_folder = true:suggestion # IDE0130: Namespace does not match folder structure
Expand Down
5 changes: 3 additions & 2 deletions .github/actions/build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@ runs:
steps:
- uses: actions/setup-node@v4
with:
node-version: 20
node-version: 22

- uses: actions/setup-dotnet@v4
with:
dotnet-version: |
9.x
8.x
- run: npm install
- run: npm ci
shell: bash
working-directory: templates

Expand Down
27 changes: 0 additions & 27 deletions .github/actions/report-failed-tests/action.yml

This file was deleted.

11 changes: 3 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: ci
on:
pull_request_target:
pull_request:
branches: [ main, feature/*, hotfix/* ]
push:
branches: [ main, feature/*, hotfix/* ]
Expand All @@ -9,7 +9,6 @@ on:
jobs:
test:
runs-on: ${{ matrix.os }}
environment: ci
strategy:
fail-fast: false
matrix:
Expand All @@ -34,9 +33,9 @@ jobs:
- run: dotnet test -c Release -f net8.0 --no-build --collect:"XPlat Code Coverage" --consoleLoggerParameters:"Summary;Verbosity=Minimal"
id: test-net80

- run: dotnet test -c Release -f net6.0 --no-build --collect:"XPlat Code Coverage" --consoleLoggerParameters:"Summary;Verbosity=Minimal"
- run: dotnet test -c Release -f net9.0 --no-build --collect:"XPlat Code Coverage" --consoleLoggerParameters:"Summary;Verbosity=Minimal"
if: matrix.os == 'ubuntu-latest'
id: test-net60
id: test-net90

- run: npm i -g @percy/cli
if: matrix.os == 'ubuntu-latest'
Expand Down Expand Up @@ -73,10 +72,6 @@ jobs:
name: dump
path: /tmp/coredump*

- name: Report failed tests
if: ${{ failure() && (steps.test-net80.outcome == 'failure' || steps.test-net60.outcome == 'failure') }}
uses: ./.github/actions/report-failed-tests

publish-docs:
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
needs: [test]
Expand Down
5 changes: 0 additions & 5 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,6 @@ jobs:
permissions:
packages: write
steps:
- uses: actions/setup-dotnet@v4
with:
dotnet-version: |
9.x
- uses: actions/checkout@v4
with:
fetch-depth: 0
Expand Down
58 changes: 58 additions & 0 deletions .github/workflows/reports.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: report-test-results
run-name: Generate Test Report for ${{ github.event.workflow_run.head_commit.message }}
on:
workflow_run:
workflows:
- ci
types:
- completed

permissions:
contents: read
actions: read
checks: write

jobs:
report:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event.workflow_run.conclusion == 'failure' }}
steps:
- name: Create Test Report
uses: dorny/test-reporter@31a54ee7ebcacc03a09ea97a7e5465a47b84aea5 # v1.9.1
id : test-reports
with:
artifact: /^logs-(.*)/ # Name of artifact to report
name: test-results # Name of the `check run` which will be created
path: 'test/TestResults/*.trx'
reporter: dotnet-trx
fail-on-error: false
fail-on-empty: false

- name: Output message to job summary
id: output-job-summary
shell: pwsh
if: ${{ steps.test-reports.outputs.time != '0' }}
run: |
$conclusion = "${{ steps.test-reports.outputs.conclusion }}"
$passed = "${{ steps.test-reports.outputs.passed }}"
$failed = "${{ steps.test-reports.outputs.failed }}"
$skipped = "${{ steps.test-reports.outputs.skipped }}"
$time = "${{ steps.test-reports.outputs.time }}"
$url_html = "${{ steps.test-reports.outputs.url_html }}"
$content = @"
## Summary of Test Report
- **Report URL**: $url_html
| Conclusion | Passed | Failed | Skipped | Time |
|-------------|---------|---------|----------|------------|
| $conclusion | $passed | $failed | $skipped | $time [ms] |
"@
Write-Output $content >> $env:GITHUB_STEP_SUMMARY
if($failed -ne '0'){
echo "::error::Test Report contains ${failed} errors."
exit 1
}
10 changes: 1 addition & 9 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<ContinuousIntegrationBuild Condition="'$(GITHUB_ACTIONS)' == 'true'">true</ContinuousIntegrationBuild>
<TargetFrameworks>net6.0;net8.0</TargetFrameworks>
<TargetFrameworks>net8.0;net9.0</TargetFrameworks>
<TargetFrameworks Condition="'$(DOCFX_PREVIEW_BUILD)' == 'true'">net8.0;net9.0</TargetFrameworks>
<LangVersion>Preview</LangVersion>
<ImplicitUsings>enable</ImplicitUsings>
Expand Down Expand Up @@ -45,21 +45,13 @@
<None Include="$(MSBuildThisFileDirectory)\README.md" Pack="true" PackagePath="\"/>
</ItemGroup>

<ItemGroup Condition="'$(ProjectName)' != 'Docfx.Common'">
<PackageReference Include="PolySharp">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.SourceLink.GitHub">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
</ItemGroup>


<!-- Remove Node.js runtime dependencies that used by playwright -->
<Target Name="RemoveNodeJsRuntimes" AfterTargets="CopyPlaywrightFilesToOutput">
<ItemGroup>
Expand Down
39 changes: 12 additions & 27 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -4,45 +4,30 @@
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="HtmlAgilityPack" Version="1.11.65" />
<PackageVersion Include="HtmlAgilityPack" Version="1.11.70" />
<PackageVersion Include="ICSharpCode.Decompiler" Version="8.2.0.7535" />
<PackageVersion Include="IgnoresAccessChecksToGenerator" Version="0.7.0" />
<PackageVersion Include="Jint" Version="4.0.2" />
<PackageVersion Include="JsonSchema.Net" Version="7.2.2" />
<PackageVersion Include="Markdig" Version="0.37.0" />
<PackageVersion Include="Microsoft.Playwright" Version="1.46.0" />
<PackageVersion Include="Jint" Version="4.1.0" />
<PackageVersion Include="JsonSchema.Net" Version="7.2.3" />
<PackageVersion Include="Markdig" Version="0.38.0" />
<PackageVersion Include="Microsoft.Playwright" Version="1.48.0" />
<PackageVersion Include="Microsoft.SourceLink.GitHub" Version="8.0.0" />
<PackageVersion Include="Newtonsoft.Json" Version="13.0.3" />
<PackageVersion Include="OneOf" Version="3.0.271" />
<PackageVersion Include="OneOf.SourceGenerator" Version="3.0.271" />
<PackageVersion Include="PdfPig" Version="0.1.9-alpha-20240904-cd2a8" />
<PackageVersion Include="PdfPig" Version="0.1.9" />
<PackageVersion Include="PlantUml.Net" Version="1.4.80" />
<PackageVersion Include="PolySharp" Version="1.14.1" />
<PackageVersion Include="Spectre.Console" Version="0.49.1" />
<PackageVersion Include="Spectre.Console.Cli" Version="0.49.1" />
<PackageVersion Include="Stubble.Core" Version="1.10.8" />
<PackageVersion Include="System.Collections.Immutable" Version="8.0.0" />
<PackageVersion Include="System.Composition" Version="8.0.0" />
<PackageVersion Include="System.Formats.Asn1" Version="8.0.1" />
<PackageVersion Include="System.Text.Json" Version="8.0.4" />
<PackageVersion Include="System.Text.Json" Version="8.0.5" />
<PackageVersion Include="YamlDotNet" Version="15.3.0" />
</ItemGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'net6.0'">
<!-- "17.3.2" is the latest compatible version for .NET 6 -->
<PackageVersion Include="Microsoft.Build" Version="[17.3.2]" />
<PackageVersion Include="Microsoft.Build.Locator" Version="1.7.8" />
<PackageVersion Include="Microsoft.CodeAnalysis" Version="[4.8.0]" />
<PackageVersion Include="Microsoft.CodeAnalysis.Common" Version="[4.8.0]" />
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="[4.8.0]" />
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp" Version="[4.8.0]" />
<PackageVersion Include="Microsoft.CodeAnalysis.VisualBasic.Workspaces" Version="[4.8.0]" />
<PackageVersion Include="Microsoft.CodeAnalysis.VisualBasic" Version="[4.8.0]" />
<PackageVersion Include="Microsoft.CodeAnalysis.Workspaces.Common" Version="[4.8.0]" />
<PackageVersion Include="Microsoft.CodeAnalysis.Workspaces.MSBuild" Version="[4.8.0]" />
</ItemGroup>

<ItemGroup Condition="'$(TargetFramework)' != 'net6.0'">
<ItemGroup>
<PackageVersion Include="Microsoft.CodeAnalysis" Version="4.11.0" />
<PackageVersion Include="Microsoft.CodeAnalysis.Common" Version="4.11.0" />
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="4.11.0" />
Expand All @@ -56,12 +41,12 @@
<ItemGroup>
<!-- Test only -->
<PackageVersion Include="coverlet.collector" Version="6.0.2" />
<PackageVersion Include="FluentAssertions" Version="6.12.0" />
<PackageVersion Include="FluentAssertions" Version="6.12.1" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.11.1" />
<PackageVersion Include="PublicApiGenerator" Version="11.1.0" />
<PackageVersion Include="Verify.DiffPlex" Version="3.1.0" />
<PackageVersion Include="Verify.Xunit" Version="26.4.0" />
<PackageVersion Include="Verify.DiffPlex" Version="3.1.2" />
<PackageVersion Include="Verify.Xunit" Version="28.1.3" />
<PackageVersion Include="xunit.runner.visualstudio" Version="2.8.2" />
<PackageVersion Include="xunit" Version="2.9.0" />
<PackageVersion Include="xunit" Version="2.9.2" />
</ItemGroup>
</Project>
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ We welcome code contributions through pull requests, issues tagged as **[`help-w
### Prerequisites
- Install [Visual Studio 2022 (Community or higher)](https://www.visualstudio.com/) and make sure you have the latest updates.
- Install [.NET SDK](https://dotnet.microsoft.com/download/dotnet) 6.x and 8.x.
- Install NodeJS (20.x.x).
- Install [.NET SDK](https://dotnet.microsoft.com/download/dotnet) 8.x and 9.x.
- Install NodeJS (22.x.x).
### Build and Test
Expand Down
6 changes: 6 additions & 0 deletions docs/docfx.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"$schema": "https://raw.githubusercontent.com/dotnet/docfx/main/schemas/docfx.schema.json",
"metadata": [
{
"src": [
Expand All @@ -25,6 +26,11 @@
{
"files": [ "**/images/**", "**/media/**", "codesnippet/**" ],
"exclude": [ "_site/**", "obj/**" ]
},
{
"src": "../schemas",
"files": [ "**/*.json" ],
"dest": "schemas"
}
],
"postProcessors": [ "ExtractSearchIndex" ],
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ Replace [new URL] with the URL that you want to redirect users to. You can use a

## Metadata

Metadata are attributes attached to an file. It helps shape the look and feel of a page and provides extra context to the article.
Metadata are attributes attached to a file. It helps shape the look and feel of a page and provides extra context to the article.

To add metadata to an article, use "YAML Front Matter" markdown extension syntax:

Expand Down
2 changes: 1 addition & 1 deletion docs/docs/dotnet-api-docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ If your project targets multiple target frameworks, docfx internally builds each
}],
"dest": "api",
"properties": {
"TargetFramework": "net6.0"
"TargetFramework": "net8.0"
}
},
}
Expand Down
Loading

0 comments on commit 9fc9483

Please sign in to comment.