File tree Expand file tree Collapse file tree 2 files changed +81
-0
lines changed
Expand file tree Collapse file tree 2 files changed +81
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ push :
5+ pull_request :
6+ workflow_dispatch :
7+
8+ jobs :
9+ build :
10+ name : Build
11+ runs-on : ubuntu-latest
12+
13+ steps :
14+ - name : actions/checkout@v4
15+ uses : actions/checkout@v4
16+
17+ - name : actions/setup-dotnet@v4
18+ uses : actions/setup-dotnet@v4
19+ with :
20+ dotnet-version : ' 9.0.x'
21+
22+ - name : dotnet restore
23+ run : dotnet restore
24+
25+ - name : dotnet build
26+ run : dotnet build --no-restore --configuration Release
Original file line number Diff line number Diff line change 1+ name : Deploy
2+
3+ on :
4+ push :
5+ branches : [ main, master ]
6+ workflow_dispatch :
7+
8+ permissions :
9+ contents : read
10+ pages : write
11+ id-token : write
12+
13+ concurrency :
14+ group : " pages"
15+ cancel-in-progress : false
16+
17+ jobs :
18+ build :
19+ name : Build
20+ runs-on : ubuntu-latest
21+ if : github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master'
22+ steps :
23+ - name : actions/checkout@v4
24+ uses : actions/checkout@v4
25+
26+ - name : actions/setup-dotnet@v4
27+ uses : actions/setup-dotnet@v4
28+ with :
29+ dotnet-version : ' 9.0.x'
30+
31+ - name : dotnet restore
32+ run : dotnet restore
33+
34+ - name : dotnet publish
35+ run : dotnet publish DapperCodeGenerator.Web -c Release -o dist
36+
37+ - name : actions/configure-pages@v4
38+ uses : actions/configure-pages@v4
39+
40+ - name : actions/upload-pages-artifact@v3
41+ uses : actions/upload-pages-artifact@v3
42+ with :
43+ path : ./dist/wwwroot
44+
45+ deploy :
46+ name : Deploy
47+ environment :
48+ name : github-pages
49+ url : ${{ steps.deployment.outputs.page_url }}
50+ runs-on : ubuntu-latest
51+ needs : build
52+ steps :
53+ - name : actions/deploy-pages@v4
54+ id : deployment
55+ uses : actions/deploy-pages@v4
You can’t perform that action at this time.
0 commit comments