-
Notifications
You must be signed in to change notification settings - Fork 4
107 lines (78 loc) · 2.73 KB
/
ubuntodotnet.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
name: .NET
#on: pull_request_target
on:
pull_request_target:
branches: [ "TestRuns" ]
jobs:
build:
runs-on: ubuntu-latest
permissions:
actions: write
pages: write
id-token: write
contents: write
pull-requests: write
deployments: write
environment:
name: github-pages
url: ${{ steps.change-page-url.outputs.new_page_url }}
defaults:
run:
working-directory: ./modelCsharp
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
- name: Install Python 3
uses: actions/setup-python@v1
with:
python-version: 3.11.6
#installing packages
- name: Install Python pandas
run: python -m pip install --upgrade pip pandas
- name: Install Python aspose
run: python -m pip install --upgrade pip aspose.words
- name: Install Python matplotlib
run: python -m pip install --upgrade pip matplotlib
- name: Install Python pyinstaller
run: python -m pip install --upgrade pip datetime
- name: Install Python datetime
run: pip install pyinstaller
- name: Create a temporary artifact downloads folder for graphs
run: mkdir graphs
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: run
run: dotnet run --project ConsoleAppSVS-test/ConsoleAppSVS-test.csproj
- name: run python
run: python TestModel/testGraph/testGraph/testGraph.py
- name: moving artfacts to temp folder
run: |
mv index.html graphs
mv index.001.png graphs
- name: Step 3 - Use the Upload Artifact GitHub Action
uses: actions/upload-artifact@v2
with:
name: folder for graphs
path: ./modelCsharp/graphs
- name: Deploy 🚀
uses: actions/upload-pages-artifact@v2
with:
path: ./modelCsharp/graphs
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Override page_url
id: change-page-url
run: echo "new_page_url=${{ steps.deployment.outputs.page_url }}index.html" >> $GITHUB_OUTPUT
- name: ls
run: ls -a
GIT commit and push all changed files