You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Uses the .NET CLI `dotnet build`[command](https://learn.microsoft.com/en-us/dotnet/core/tools/dotnet-build) that builds specified projects or the solution itself including all of its dependencies.
4
4
@@ -20,7 +20,7 @@ Supports `projects` input we learned to appreciate from [AzDO DotNetCoreCLI](htt
20
20
To use this action in your GitHub repository, you can follow these steps:
21
21
22
22
```yaml
23
-
uses: codebeltnet/dotnet-build@v1
23
+
uses: codebeltnet/dotnet-build@v4
24
24
```
25
25
26
26
### Inputs
@@ -31,34 +31,32 @@ with:
31
31
# Supports globbing. Default is an empty string.
32
32
projects: ''
33
33
# Defines the build configuration.
34
-
configuration: 'Release'
34
+
configuration: 'Debug'
35
35
# Compiles for a specific framework. The framework must be defined in the project file. Default is an empty string.
36
36
framework: ''
37
37
# Sets the verbosity level of the command.
38
38
# Allowed values are q[uiet], m[inimal], n[ormal], d[etailed], and diag[nostic].
39
39
# The default is quiet.
40
-
level: 'quiet'
40
+
verbosity-level: 'quiet'
41
41
# Provides a way to fully customize the build. See https://learn.microsoft.com/en-us/visualstudio/msbuild/msbuild-command-line-reference?view=vs-2022#switches for more information.
42
-
buildSwitches: ''
43
-
# Upload the generated build artifact.
44
-
uploadBuildArtifact: 'true'
45
-
# When set, current workspace will be overwritten with the content of the restore cache.
46
-
restoreCacheKey: ''
47
-
# The name of the uploaded build artifact. Default, when left empty, is 'format('{0}-{1}', inputs.framework, inputs.configuration)'.
48
-
uploadBuildArtifactName: ''
42
+
build-switches: ''
49
43
```
50
44
51
45
### Outputs
52
46
53
47
This action has no outputs.
54
48
49
+
### Reusable Workflow
50
+
51
+
A complementary [jobs-dotnet-build](https://github.com/codebeltnet/jobs-dotnet-build) reusable workflow is available, allowing you to fully leverage the Codebelt experience in your GitHub Actions pipeline.
52
+
55
53
## Examples
56
54
57
55
### Build for Release in src folder and upload build artifact
58
56
59
57
```yaml
60
58
- name: Build for Release
61
-
uses: codebeltnet/dotnet-build@v1
59
+
uses: codebeltnet/dotnet-build@v4
62
60
with:
63
61
configuration: Release
64
62
```
@@ -67,247 +65,42 @@ This action has no outputs.
67
65
68
66
```yaml
69
67
- name: Build for Debug
70
-
uses: codebeltnet/dotnet-build@v1
68
+
uses: codebeltnet/dotnet-build@v4
71
69
with:
72
70
configuration: Debug
73
-
uploadBuildArtifact: false
74
71
```
75
72
76
-
### Time-consuming Builds for large projects
77
-
78
-
```yaml
79
-
- name: Build
80
-
uses: codebeltnet/dotnet-build@v2
81
-
with:
82
-
configuration: Debug
83
-
restoreCacheKey: dotnet-restore-sha256
84
-
```
85
-
86
-
### Sample workflow for .NET Class Library
87
-
88
-
```yaml
89
-
name: Generic CI/CD Pipeline (.NET Library)
90
-
on:
91
-
push:
92
-
branches: [main]
93
-
paths-ignore:
94
-
- .codecov
95
-
- .docfx
96
-
- .github
97
-
- .nuget
98
-
pull_request:
99
-
branches: [main]
100
-
workflow_dispatch:
101
-
inputs:
102
-
configuration:
103
-
type: choice
104
-
description: The build configuration to use in the deploy stage.
0 commit comments