Skip to content

Commit 16b5bd5

Browse files
committed
Merge remote-tracking branch 'origin/vnext' into release/2.0.0
2 parents 8058d24 + 47ed933 commit 16b5bd5

File tree

383 files changed

+8593
-6117
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

383 files changed

+8593
-6117
lines changed

.azure-pipelines/ci-build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ stages:
216216
displayName: publish Hidi as executable
217217
inputs:
218218
command: 'publish'
219-
arguments: -c Release --runtime win-x64 /p:PublishSingleFile=true --self-contained --output $(Build.ArtifactStagingDirectory)/Microsoft.OpenApi.Hidi-v$(hidiversion) -p:PublishTrimmed=true
219+
arguments: -c Release --runtime win-x64 /p:PublishSingleFile=true /p:PackAsTool=false --self-contained --output $(Build.ArtifactStagingDirectory)/Microsoft.OpenApi.Hidi-v$(hidiversion)
220220
projects: 'src/Microsoft.OpenApi.Hidi/Microsoft.OpenApi.Hidi.csproj'
221221
publishWebProjects: False
222222
zipAfterPublish: false

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ csharp_prefer_braces = true:silent
8484
csharp_style_deconstructed_variable_declaration = true:suggestion
8585
csharp_prefer_simple_default_expression = true:suggestion
8686
csharp_style_pattern_local_over_anonymous_function = true:suggestion
87-
csharp_style_inlined_variable_declaration = true:suggestion
87+
csharp_style_inlined_variable_declaration = true:error
8888
###############################
8989
# C# Formatting Rules #
9090
###############################

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
* @irvinesunday @darrelmiller @peombwa @zengin @baywet @millicentachieng @MaggieKimani1
1+
* @irvinesunday @darrelmiller @peombwa @zengin @baywet @millicentachieng @MaggieKimani1 @andrueastman
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Auto-merge dependabot updates
2+
3+
on:
4+
pull_request:
5+
branches: [ main ]
6+
7+
permissions:
8+
pull-requests: write
9+
contents: write
10+
11+
jobs:
12+
13+
dependabot-merge:
14+
15+
runs-on: ubuntu-latest
16+
17+
if: ${{ github.actor == 'dependabot[bot]' }}
18+
19+
steps:
20+
- name: Dependabot metadata
21+
id: metadata
22+
uses: dependabot/[email protected]
23+
with:
24+
github-token: "${{ secrets.GITHUB_TOKEN }}"
25+
26+
- name: Enable auto-merge for Dependabot PRs
27+
# Only if version bump is not a major version change
28+
if: ${{steps.metadata.outputs.update-type != 'version-update:semver-major'}}
29+
run: gh pr merge --auto --merge "$PR_URL"
30+
env:
31+
PR_URL: ${{github.event.pull_request.html_url}}
32+
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

.github/workflows/ci-cd.yml

Lines changed: 3 additions & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
4242
- name: Checkout repository
4343
id: checkout_repo
44-
uses: actions/checkout@v3
44+
uses: actions/checkout@v4
4545
with:
4646
token: ${{ secrets.GITHUB_TOKEN }}
4747
fetch-depth: 0
@@ -59,85 +59,10 @@ jobs:
5959
id: build_projects
6060
shell: pwsh
6161
run: |
62-
$projectsArray = @(
63-
'.\src\Microsoft.OpenApi\Microsoft.OpenApi.csproj',
64-
'.\src\Microsoft.OpenApi.Readers\Microsoft.OpenApi.Readers.csproj',
65-
'.\src\Microsoft.OpenApi.Hidi\Microsoft.OpenApi.Hidi.csproj'
66-
)
67-
$gitNewVersion = if ("${{ steps.tag_generator.outputs.new_version }}") {"${{ steps.tag_generator.outputs.new_version }}"} else {$null}
68-
$projectCurrentVersion = ([xml](Get-Content .\src\Microsoft.OpenApi\Microsoft.OpenApi.csproj)).Project.PropertyGroup.Version
69-
$projectNewVersion = $gitNewVersion ?? $projectCurrentVersion
70-
71-
$projectsArray | ForEach-Object {
72-
dotnet build $PSItem `
73-
-c Release # `
74-
# -o $env:ARTIFACTS_FOLDER `
75-
# /p:Version=$projectNewVersion
76-
}
77-
78-
# Move NuGet packages to separate folder for pipeline convenience
79-
# New-Item Artifacts/NuGet -ItemType Directory
80-
# Get-ChildItem Artifacts/*.nupkg | Move-Item -Destination "Artifacts/NuGet"
62+
dotnet build Microsoft.OpenApi.sln -c Release
8163
8264
- name: Run unit tests
8365
id: run_unit_tests
8466
shell: pwsh
8567
run: |
86-
$testProjectsArray = @(
87-
'.\test\Microsoft.OpenApi.Tests\Microsoft.OpenApi.Tests.csproj',
88-
'.\test\Microsoft.OpenApi.Readers.Tests\Microsoft.OpenApi.Readers.Tests.csproj',
89-
'.\test\Microsoft.OpenApi.SmokeTests\Microsoft.OpenApi.SmokeTests.csproj'
90-
)
91-
92-
$testProjectsArray | ForEach-Object {
93-
dotnet test $PSItem `
94-
-c Release
95-
}
96-
97-
# - if: steps.tag_generator.outputs.new_version != ''
98-
# name: Upload NuGet packages as artifacts
99-
# id: ul_packages_artifact
100-
# uses: actions/upload-artifact@v1
101-
# with:
102-
# name: NuGet packages
103-
# path: Artifacts/NuGet/
104-
105-
cd:
106-
if: needs.ci.outputs.is_default_branch == 'true' && needs.ci.outputs.latest_version != ''
107-
name: Continuous Deployment
108-
needs: ci
109-
runs-on: ubuntu-latest
110-
steps:
111-
# - name: Download and extract NuGet packages
112-
# id: dl_packages_artifact
113-
# uses: actions/download-artifact@v2
114-
# with:
115-
# name: NuGet packages
116-
# path: NuGet/
117-
118-
# - name: Push NuGet packages to NuGet.org
119-
# id: push_nuget_packages
120-
# continue-on-error: true
121-
# shell: pwsh
122-
# run: |
123-
# Get-ChildItem NuGet/*.nupkg | ForEach-Object {
124-
# nuget push $PSItem `
125-
# -ApiKey $env:NUGET_API_KEY `
126-
# -Source https://api.nuget.org/v3/index.json
127-
# }
128-
# env:
129-
# NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }}
130-
131-
- name: Create and publish release
132-
id: create_release
133-
uses: softprops/action-gh-release@v1
134-
with:
135-
name: OpenApi v${{ needs.ci.outputs.latest_version }}
136-
tag_name: v${{ needs.ci.outputs.latest_version }}
137-
# files: |
138-
# NuGet/Microsoft.OpenApi.${{ needs.ci.outputs.latest_version }}.nupkg
139-
# NuGet/Microsoft.OpenApi.Readers.${{ needs.ci.outputs.latest_version }}.nupkg
140-
env:
141-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
142-
143-
# Built with ❤ by [Pipeline Foundation](https://pipeline.foundation)
68+
dotnet test Microsoft.OpenApi.sln -c Release -v n

.github/workflows/codeql-analysis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
steps:
1515
- name: Checkout repository
1616
id: checkout_repo
17-
uses: actions/checkout@v3
17+
uses: actions/checkout@v4
1818

1919
- name: Setup .NET
2020
uses: actions/setup-dotnet@v3

.github/workflows/docker.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ jobs:
1515
runs-on: ubuntu-latest
1616
steps:
1717
- name: Check out the repo
18-
uses: actions/checkout@v3
18+
uses: actions/checkout@v4
1919
- name: Login to GitHub package feed
20-
uses: docker/login-action@v2.1.0
20+
uses: docker/login-action@v3.0.0
2121
with:
2222
username: ${{ secrets.ACR_USERNAME }}
2323
password: ${{ secrets.ACR_PASSWORD }}
@@ -30,13 +30,13 @@ jobs:
3030
id: getversion
3131
- name: Push to GitHub Packages - Nightly
3232
if: ${{ github.ref == 'refs/heads/vnext' }}
33-
uses: docker/build-push-action@v4.0.0
33+
uses: docker/build-push-action@v5.1.0
3434
with:
3535
push: true
3636
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:nightly
3737
- name: Push to GitHub Packages - Release
3838
if: ${{ github.ref == 'refs/heads/master' }}
39-
uses: docker/build-push-action@v4.0.0
39+
uses: docker/build-push-action@v5.1.0
4040
with:
4141
push: true
4242
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest,${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.getversion.outputs.version }}

.github/workflows/sonarcloud.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ jobs:
4242
uses: actions/setup-dotnet@v3
4343
with:
4444
dotnet-version: 7.0.x
45-
- uses: actions/checkout@v3
45+
- uses: actions/checkout@v4
4646
with:
4747
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
4848
- name: Cache SonarCloud packages

.vscode/launch.json

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,36 @@
55
// Use IntelliSense to find out which attributes exist for C# debugging
66
// Use hover for the description of the existing attributes
77
// For further information visit https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md
8-
"name": ".NET Core Launch (console)",
8+
"name": "Launch Hidi",
99
"type": "coreclr",
1010
"request": "launch",
1111
"preLaunchTask": "build",
1212
// If you have changed target frameworks, make sure to update the program path.
1313
"program": "${workspaceFolder}/src/Microsoft.OpenApi.Hidi/bin/Debug/net7.0/Microsoft.OpenApi.Hidi.dll",
14-
"args": [],
14+
"args": ["plugin",
15+
"-m","C:\\Users\\darrmi\\src\\github\\microsoft\\openapi.net\\test\\Microsoft.OpenApi.Hidi.Tests\\UtilityFiles\\exampleapimanifest.json",
16+
"--of","./output"],
1517
"cwd": "${workspaceFolder}/src/Microsoft.OpenApi.Hidi",
1618
// For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console
1719
"console": "internalConsole",
1820
"stopAtEntry": false
1921
},
22+
{
23+
// Use IntelliSense to find out which attributes exist for C# debugging
24+
// Use hover for the description of the existing attributes
25+
// For further information visit https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md
26+
"name": "Launch Workbench",
27+
"type": "coreclr",
28+
"request": "launch",
29+
"preLaunchTask": "build",
30+
// If you have changed target frameworks, make sure to update the program path.
31+
"program": "${workspaceFolder}/src/Microsoft.OpenApi.WorkBench/bin/Debug/net7.0-windows/Microsoft.OpenApi.Workbench.exe",
32+
"args": [],
33+
"cwd": "${workspaceFolder}/src/Microsoft.OpenApi.Workbench",
34+
// For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console
35+
"console": "internalConsole",
36+
"stopAtEntry": false
37+
},
2038
{
2139
"name": ".NET Core Attach",
2240
"type": "coreclr",

.vscode/settings.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,8 @@
44
"titleBar.activeBackground": "#054754",
55
"titleBar.activeForeground": "#F0FCFE"
66
},
7-
"omnisharp.enableRoslynAnalyzers": true
7+
"cSpell.words": [
8+
"csdl",
9+
"Hidi"
10+
]
811
}

0 commit comments

Comments
 (0)