Skip to content

Commit ab05feb

Browse files
committed
⬆️ Bump files with dotnet-file sync
# devlooped/oss - Fix improper first / in gh api repos devlooped/oss@f2b690c - Ensure lf for Scriban templates always devlooped/oss@4a9aa32 - Enable package pruning in Directory.Build.props devlooped/oss@0ff8b7b - Update create-pull-request action to version 8 devlooped/oss@0662872 - Group MEAI packages together devlooped/oss@e733294 - Improve default Product metadata, remove .git from user-facing URLs devlooped/oss@4339749 - Ensure dnx run succeeds even on Windows devlooped/oss@7f5f9ee - Use GH_TOKEN if available for PR devlooped/oss@77e83f2 - Ignore .env files recursively devlooped/oss@3776526 - Update nuget.config with new(ish?) MS certs devlooped/oss@032439d - Allow workflow to work cross-org devlooped/oss@af171b7 - Remove -l:trx since it's just for dotnet test, not build devlooped/oss@0f7f7f7 - Update to checkout@v4 devlooped/oss@5fb1723 - If we provide a docs category, don't exclude docs :) devlooped/oss@0c23e24 - Improve triage actions on issues devlooped/oss@33000c0 - Ignore slnx file format too devlooped/oss@68b409c - Add explicit write permissions from caller workflow devlooped/oss@8fa147d - Revert indent size for project files devlooped/oss@a62c459 - Skip discussion issues when generating changelog devlooped/oss@08d83cb
1 parent 2f7aef4 commit ab05feb

23 files changed

+584
-207
lines changed

.editorconfig

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ indent_size = 2
3030

3131
# Dotnet code style settings:
3232
[*.{cs,vb}]
33+
tab_width = 4
34+
3335
# Sort using and Import directives with System.* appearing first
3436
dotnet_sort_system_directives_first = true
3537
# Avoid "this." and "Me." if not necessary
@@ -57,6 +59,9 @@ dotnet_style_require_accessibility_modifiers = omit_if_default:error
5759
# IDE0040: Add accessibility modifiers
5860
dotnet_diagnostic.IDE0040.severity = error
5961

62+
# IDE1100: Error reading content of source file 'Project.TargetFrameworkMoniker' (i.e. from ThisAssembly)
63+
dotnet_diagnostic.IDE1100.severity = none
64+
6065
[*.cs]
6166
# Top-level files are definitely OK
6267
csharp_using_directive_placement = outside_namespace:silent
@@ -99,6 +104,9 @@ csharp_new_line_before_members_in_anonymous_types = true
99104
# xUnit1013: Public method should be marked as test. Allows using records as test classes
100105
dotnet_diagnostic.xUnit1013.severity = none
101106

107+
# CS9113: Parameter is unread (usually, ITestOutputHelper)
108+
dotnet_diagnostic.CS9113.severity = none
109+
102110
# Default severity for analyzer diagnostics with category 'Style'
103111
dotnet_analyzer_diagnostic.category-Style.severity = none
104112

.gitattributes

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,9 @@
1-
# sln, csproj files (and friends) are always CRLF, even on linux
2-
*.sln text eol=crlf
3-
*.proj text eol=crlf
4-
*.csproj text eol=crlf
1+
# normalize by default
2+
* text=auto encoding=UTF-8
3+
*.sh text eol=lf
4+
*.sbn eol=lf
55

66
# These are windows specific files which we may as well ensure are
77
# always crlf on checkout
88
*.bat text eol=crlf
99
*.cmd text eol=crlf
10-
11-
# Opt in known filetypes to always normalize line endings on checkin
12-
# and always use native endings on checkout
13-
*.c text
14-
*.config text
15-
*.h text
16-
*.cs text
17-
*.md text
18-
*.tt text
19-
*.txt text
20-
21-
# Some must always be checked out as lf so enforce that for those files
22-
# If these are not lf then bash/cygwin on windows will not be able to
23-
# excute the files
24-
*.sh text eol=lf

.github/actions/dotnet/action.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: ⚙ dotnet
2+
description: Configures dotnet if the repo/org defines the DOTNET custom property
3+
4+
runs:
5+
using: composite
6+
steps:
7+
- name: 🔎 dotnet
8+
id: dotnet
9+
shell: bash
10+
run: |
11+
VERSIONS=$(gh api repos/${{ github.repository }}/properties/values | jq -r '.[] | select(.property_name == "DOTNET") | .value')
12+
# Remove extra whitespace from VERSIONS
13+
VERSIONS=$(echo "$VERSIONS" | tr -s ' ' | tr -d ' ')
14+
# Convert comma-separated to newline-separated
15+
NEWLINE_VERSIONS=$(echo "$VERSIONS" | tr ',' '\n')
16+
# Validate versions
17+
while IFS= read -r version; do
18+
if ! [[ $version =~ ^[0-9]+(\.[0-9]+(\.[0-9]+)?)?(\.x)?$ ]]; then
19+
echo "Error: Invalid version format: $version"
20+
exit 1
21+
fi
22+
done <<< "$NEWLINE_VERSIONS"
23+
# Write multiline output to $GITHUB_OUTPUT
24+
{
25+
echo 'versions<<EOF'
26+
echo "$NEWLINE_VERSIONS"
27+
echo 'EOF'
28+
} >> $GITHUB_OUTPUT
29+
30+
- name: ⚙ dotnet
31+
if: steps.dotnet.outputs.versions != ''
32+
uses: actions/setup-dotnet@v4
33+
with:
34+
dotnet-version: |
35+
${{ steps.dotnet.outputs.versions }}

.github/dependabot.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,42 @@ updates:
77
directory: /
88
schedule:
99
interval: daily
10+
groups:
11+
Azure:
12+
patterns:
13+
- "Azure*"
14+
- "Microsoft.Azure*"
15+
Identity:
16+
patterns:
17+
- "System.IdentityModel*"
18+
- "Microsoft.IdentityModel*"
19+
System:
20+
patterns:
21+
- "System*"
22+
exclude-patterns:
23+
- "System.IdentityModel*"
24+
Extensions:
25+
patterns:
26+
- "Microsoft.Extensions*"
27+
exclude-patterns:
28+
- "Microsoft.Extensions.AI*"
29+
ExtensionsAI:
30+
patterns:
31+
- "Microsoft.Extensions.AI*"
32+
Web:
33+
patterns:
34+
- "Microsoft.AspNetCore*"
35+
Tests:
36+
patterns:
37+
- "Microsoft.NET.Test*"
38+
- "xunit*"
39+
- "coverlet*"
40+
ThisAssembly:
41+
patterns:
42+
- "ThisAssembly*"
43+
ProtoBuf:
44+
patterns:
45+
- "protobuf-*"
46+
Spectre:
47+
patterns:
48+
- "Spectre.Console*"

.github/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ changelog:
88
- invalid
99
- wontfix
1010
- need info
11-
- docs
1211
- techdebt
1312
authors:
1413
- devlooped-bot
@@ -24,6 +23,7 @@ changelog:
2423
- title: 📝 Documentation updates
2524
labels:
2625
- docs
26+
- documentation
2727
- title: 🔨 Other
2828
labels:
2929
- '*'

.github/workflows/build.yml

Lines changed: 32 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,31 @@
44
name: build
55
on:
66
workflow_dispatch:
7+
inputs:
8+
configuration:
9+
type: choice
10+
description: Configuration
11+
options:
12+
- Release
13+
- Debug
714
push:
815
branches: [ main, dev, 'dev/*', 'feature/*', 'rel/*' ]
916
paths-ignore:
1017
- changelog.md
11-
- code-of-conduct.md
12-
- security.md
13-
- support.md
1418
- readme.md
1519
pull_request:
1620
types: [opened, synchronize, reopened]
1721

1822
env:
1923
DOTNET_NOLOGO: true
24+
PackOnBuild: true
25+
GeneratePackageOnBuild: true
2026
VersionPrefix: 42.42.${{ github.run_number }}
2127
VersionLabel: ${{ github.ref }}
28+
GH_TOKEN: ${{ secrets.GH_TOKEN }}
29+
MSBUILDTERMINALLOGGER: auto
30+
Configuration: ${{ github.event.inputs.configuration || 'Release' }}
31+
SLEET_FEED_URL: ${{ vars.SLEET_FEED_URL }}
2232

2333
defaults:
2434
run:
@@ -31,7 +41,7 @@ jobs:
3141
matrix: ${{ steps.lookup.outputs.matrix }}
3242
steps:
3343
- name: 🤘 checkout
34-
uses: actions/checkout@v2
44+
uses: actions/checkout@v4
3545

3646
- name: 🔎 lookup
3747
id: lookup
@@ -50,44 +60,48 @@ jobs:
5060
os: ${{ fromJSON(needs.os-matrix.outputs.matrix) }}
5161
steps:
5262
- name: 🤘 checkout
53-
uses: actions/checkout@v2
63+
uses: actions/checkout@v4
5464
with:
5565
submodules: recursive
5666
fetch-depth: 0
5767

58-
- name: 🙏 build
59-
run: dotnet build -m:1
68+
- name: ⚙ dotnet
69+
uses: devlooped/actions-dotnet-env@v1
6070

61-
- name: ⚙ GNU grep
62-
if: matrix.os == 'macOS-latest'
63-
run: |
64-
brew install grep
65-
echo 'export PATH="/usr/local/opt/grep/libexec/gnubin:$PATH"' >> .bash_profile
71+
- name: 🙏 build
72+
run: dotnet build -m:1 -bl:build.binlog
6673

6774
- name: 🧪 test
68-
uses: ./.github/workflows/test
75+
shell: pwsh
76+
run: dnx --yes retest -- --no-build
6977

70-
- name: 📦 pack
71-
run: dotnet pack -m:1
78+
- name: 🐛 logs
79+
uses: actions/upload-artifact@v4
80+
if: runner.debug && always()
81+
with:
82+
name: logs
83+
path: '*.binlog'
7284

73-
# Only push CI package to sleet feed if building on ubuntu (fastest)
7485
- name: 🚀 sleet
7586
env:
7687
SLEET_CONNECTION: ${{ secrets.SLEET_CONNECTION }}
7788
if: env.SLEET_CONNECTION != ''
7889
run: |
79-
dotnet tool install -g --version 4.0.18 sleet
90+
dotnet tool update sleet -g --allow-downgrade --version $(curl -s --compressed ${{ vars.SLEET_FEED_URL }} | jq '.["sleet:version"]' -r)
8091
sleet push bin --config none -f --verbose -p "SLEET_FEED_CONTAINER=nuget" -p "SLEET_FEED_CONNECTIONSTRING=${{ secrets.SLEET_CONNECTION }}" -p "SLEET_FEED_TYPE=azure" || echo "No packages found"
8192
8293
dotnet-format:
8394
runs-on: ubuntu-latest
8495
steps:
8596
- name: 🤘 checkout
86-
uses: actions/checkout@v2
97+
uses: actions/checkout@v4
8798
with:
8899
submodules: recursive
89100
fetch-depth: 0
90101

102+
- name: ⚙ dotnet
103+
uses: devlooped/actions-dotnet-env@v1
104+
91105
- name: ✓ ensure format
92106
run: |
93107
dotnet format whitespace --verify-no-changes -v:diag --exclude ~/.nuget

.github/workflows/changelog.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
usernames-as-github-logins=true
22
issues_wo_labels=true
33
pr_wo_labels=true
4-
exclude-labels=bydesign,dependencies,duplicate,question,invalid,wontfix,need info,docs
4+
exclude-labels=bydesign,dependencies,duplicate,discussion,question,invalid,wontfix,need info,docs
55
enhancement-label=:sparkles: Implemented enhancements:
66
bugs-label=:bug: Fixed bugs:
77
issues-label=:hammer: Other:

.github/workflows/changelog.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
github_token: ${{ secrets.GITHUB_TOKEN }}
1818

1919
- name: 🤘 checkout
20-
uses: actions/checkout@v2
20+
uses: actions/checkout@v4
2121
with:
2222
fetch-depth: 0
2323
ref: main

.github/workflows/dotnet-env.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: dotnet-env
2+
on:
3+
workflow_dispatch:
4+
push:
5+
branches:
6+
- main
7+
paths:
8+
- '**/*.*proj'
9+
10+
jobs:
11+
which-dotnet:
12+
runs-on: ubuntu-latest
13+
permissions:
14+
contents: write
15+
pull-requests: write
16+
17+
steps:
18+
- name: 🤖 defaults
19+
uses: devlooped/actions-bot@v1
20+
with:
21+
name: ${{ secrets.BOT_NAME }}
22+
email: ${{ secrets.BOT_EMAIL }}
23+
gh_token: ${{ secrets.GH_TOKEN }}
24+
github_token: ${{ secrets.GITHUB_TOKEN }}
25+
26+
- name: 🤘 checkout
27+
uses: actions/checkout@v4
28+
with:
29+
token: ${{ env.GH_TOKEN }}
30+
31+
- name: 🤌 dotnet
32+
uses: devlooped/actions-which-dotnet@v1
33+
34+
- name: ✍ pull request
35+
uses: peter-evans/create-pull-request@v7
36+
with:
37+
base: main
38+
branch: which-dotnet
39+
delete-branch: true
40+
labels: dependencies
41+
title: "⚙ Update dotnet versions"
42+
body: "Update dotnet versions"
43+
commit-message: "Update dotnet versions"
44+
token: ${{ env.GH_TOKEN }}

0 commit comments

Comments
 (0)