ci: make generate-and-upload.yml more beginner friendly
This commit is contained in:
parent
eb279d4fdf
commit
e0ef3be676
36
.github/workflows/generate-and-upload.yml
vendored
36
.github/workflows/generate-and-upload.yml
vendored
@ -1,11 +1,22 @@
|
|||||||
name: Generate and upload report to KTU Moodle
|
name: Generate and upload report to KTU Moodle
|
||||||
|
|
||||||
|
env:
|
||||||
|
CONFIG_FILENAME: report.toml
|
||||||
|
ASSIGNMENT_ID: 1499
|
||||||
|
MOODLE_FILENAME: IF-1-1_Rokas_Puzonas.pdf
|
||||||
|
DOTNET_VERSION: 3.0.103
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
push:
|
push:
|
||||||
branches: [ main ]
|
branches: [ main ]
|
||||||
pull_request:
|
paths:
|
||||||
branches: [ main ]
|
- 'report.toml'
|
||||||
|
- 'Lab1/Lab1.TouristInformationCenter/**'
|
||||||
|
- 'Lab2/Lab2.TouristInformationCenter/**'
|
||||||
|
- 'Lab3/Lab3.TouristInformationCenter/**'
|
||||||
|
- 'Lab4/Lab4.TouristInformationCenter/**'
|
||||||
|
- 'Lab5/Lab5.TouristInformationCenter/**'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
generate-and-upload:
|
generate-and-upload:
|
||||||
@ -14,17 +25,24 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- name: Generate report
|
- name: Generate report
|
||||||
uses: RokasPuzonas/ktu-oop-report-generator@v1.0.2
|
uses: RokasPuzonas/ktu-oop-report-generator@v1.0.3
|
||||||
with:
|
with:
|
||||||
dotnet-version: 3.0.103
|
dotnet-version: ${{ env.DOTNET_VERSION }}
|
||||||
config-filename: report.toml
|
config-filename: ${{ env.CONFIG_FILENAME }}
|
||||||
output-filename: report.pdf
|
output-filename: report.pdf
|
||||||
- name: Upload report
|
|
||||||
|
- name: Archive report
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: report
|
||||||
|
path: report.pdf
|
||||||
|
|
||||||
|
- name: Upload report to moodle
|
||||||
uses: RokasPuzonas/ktu-moodle-assignment-upload@v1.0.3
|
uses: RokasPuzonas/ktu-moodle-assignment-upload@v1.0.3
|
||||||
with:
|
with:
|
||||||
assignment-id: 1499
|
assignment-id: ${{ env.ASSIGNMENT_ID }}
|
||||||
target-filename: report.pdf
|
target-filename: report.pdf
|
||||||
upload-filename: IF-1-1_Rokas_Puzonas.pdf
|
upload-filename: ${{ env.MOODLE_FILENAME }}
|
||||||
ktu-username: ${{ secrets.KTU_USERNAME }}
|
ktu-username: ${{ secrets.KTU_USERNAME }}
|
||||||
ktu-password: ${{ secrets.KTU_PASSWORD }}
|
ktu-password: ${{ secrets.KTU_PASSWORD }}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user