-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathaction.yml
35 lines (27 loc) · 882 Bytes
/
action.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
name: Python Script in Actions
description: "Create an action in Python"
branding:
icon: 'terminal'
color: 'blue'
on: push
jobs:
makewarn:
runs-on: windows-latest
steps:
- name: Fail
run: if (${{ runner.os }} -ne Windows { echo "::error::Python action only supported on Windows. Please change your runner to windows-2022, windows-2019, or even better windows-latest." }
python3runner:
runs-on: windows-latest
steps:
- name: Install Python 3
run: >
choco install python3 --no-progress
- uses: actions/checkout@v2
with:
repository: ${{ env.OWNER }}/${{ env.REPO }}
path: ${{ github.events.input.path }}
- name: Run Python action
run: |
cd D:\a\${{ env.REPO }}/${{ env.REPO }}
python workflow.py
Exit $LASTEXITCODE