File tree Expand file tree Collapse file tree 3 files changed +54
-8
lines changed Expand file tree Collapse file tree 3 files changed +54
-8
lines changed Original file line number Diff line number Diff line change 7
7
DOTNET_CLI_TELEMETRY_OPTOUT : 1
8
8
DOTNET_SKIP_FIRST_TIME_EXPERIENCE : 1
9
9
DOTNET_NOLOGO : 1
10
-
10
+
11
11
defaults :
12
12
run :
13
13
shell : pwsh
14
-
14
+
15
15
jobs :
16
16
docs :
17
17
name : Update Markdown (embedded snippets)
@@ -20,28 +20,31 @@ jobs:
20
20
-
21
21
name : Checkout
22
22
uses : actions/checkout@v5
23
+ if : github.event_name == 'push'
24
+ with :
25
+ token : ${{ secrets.PUSH_GITHUB_TOKEN }}
23
26
-
24
27
name : Setup .NET SDK
25
28
uses : actions/setup-dotnet@v5
26
29
with :
27
30
global-json-file : global.json
28
- -
31
+ -
29
32
name : Run MarkdownSnippets
30
33
run : |
31
34
dotnet tool install --global MarkdownSnippets.Tool
32
35
mdsnippets --write-header false
33
36
working-directory : ${{ github.workspace }}/docs/input
34
- -
37
+ -
35
38
name : Check for changes
36
39
id : status
37
40
run : |
38
41
if ($null -ne (git status --porcelain)) { echo "has_changes=1"; echo "has_changes=1" >> $env:GITHUB_OUTPUT }
39
- -
42
+ -
40
43
name : Push changes
41
44
run : |
42
45
git add --verbose .
43
46
git config user.name 'Artur Stolear'
44
47
git config user.email '[email protected] '
45
48
git commit -m 'Docs changes' --allow-empty
46
49
git push --force
47
- if : steps.status.outputs.has_changes == '1'
50
+ if : steps.status.outputs.has_changes == '1'
Original file line number Diff line number Diff line change
1
+ name : Mark public API as shipped
2
+
3
+ on :
4
+ workflow_dispatch :
5
+ repository_dispatch :
6
+ types : [ publish-release ]
7
+
8
+ defaults :
9
+ run :
10
+ shell : pwsh
11
+
12
+ permissions :
13
+ contents : read
14
+
15
+ jobs :
16
+ homebrew :
17
+ permissions :
18
+ contents : none
19
+ name : Mark public API as shipped
20
+ runs-on : ubuntu-24.04
21
+ steps :
22
+ -
23
+ name : Checkout
24
+ uses : actions/checkout@v5
25
+ if : github.event_name == 'repository_dispatch' || github.event_name == 'workflow_dispatch'
26
+ with :
27
+ token : ${{ secrets.PUSH_GITHUB_TOKEN }}
28
+ -
29
+ name : Mark public API as shipped
30
+ run : ./src/mark-shipped.ps1
31
+ -
32
+ name : Check for changes
33
+ id : status
34
+ run : |
35
+ if ($null -ne (git status --porcelain)) { echo "has_changes=1"; echo "has_changes=1" >> $env:GITHUB_OUTPUT }
36
+ -
37
+ name : Push changes
38
+ run : |
39
+ git add --verbose .
40
+ git config user.name 'Artur Stolear'
41
+ git config user.email '[email protected] '
42
+ git commit -m 'Mark public API as shipped' --allow-empty
43
+ git push --force
44
+ if : steps.status.outputs.has_changes == '1'
Original file line number Diff line number Diff line change @@ -30,8 +30,7 @@ function MarkShipped([string]$dir) {
30
30
}
31
31
32
32
$shipped | Sort-Object - Unique | Where-Object { -not $removed.Contains ($_ ) } | Out-File $shippedFilePath - Encoding Ascii
33
- " #nullable enable" | Out-File " PublicAPI.empty.txt" - Encoding Ascii
34
- Copy-Item ./ PublicAPI.empty.txt $unshippedFilePath
33
+ " #nullable enable" | Out-File $unshippedFilePath - Encoding Ascii
35
34
}
36
35
37
36
try {
You can’t perform that action at this time.
0 commit comments