-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction.yml
52 lines (47 loc) · 1.63 KB
/
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: Notebook Preflight
description: |
This action performs preflight checks on your notebook to ensure that it meets the standards required for publication on the Journal of Digital History.
inputs:
notebook:
description: 'The filename of the notebook to check.'
required: true
output_md:
description: 'The filename of the output report.'
required: true
default: 'preflight_report.md'
functions:
description: 'A comma-separated list of functions to apply to the notebook.'
required: true
default: 'checkmd,checkurls'
outputs:
size:
description: 'The number of total cells'
value: ${{ steps.preflight.outputs.size }}
notebook_path:
description: 'The notebook path'
value: ${{ steps.preflight.outputs.notebook_path }}
workspace:
description: 'The workspace'
value: ${{ steps.preflight.outputs.workspace }}
notebook:
description: 'The filename of the notebook to check'
value: ${{ steps.preflight.outputs.notebook }}
checkmd:
description: 'A markdown validation report'
value: ${{ steps.preflight.outputs.checkmd }}
checkurls:
description: 'The number of URLs that were checked.'
value: ${{ steps.preflight.outputs.checkurls }}
runs:
using: 'composite'
steps:
- name: Install Python
uses: actions/setup-python@v4
with:
python-version: '3.10.7'
- name: Install Dependencies and run preflight
id: preflight
run: |
pip install -r ${{ github.action_path }}/requirements.txt
python ${{ github.action_path }}/preflight.py ${{ inputs.notebook }} ${{ inputs.functions }} ${{ inputs.output_md }}
shell: bash