Dump action as JSON
This commit is contained in:
parent
a869dd36b2
commit
a360fcb184
|
@ -130,8 +130,7 @@ runs:
|
||||||
- name: Create Docker container action
|
- name: Create Docker container action
|
||||||
run: |
|
run: |
|
||||||
# Create Docker container action
|
# Create Docker container action
|
||||||
python -m pip install -r requirements/github-actions.txt
|
python create-docker-action.py
|
||||||
python create-docker-action.py ${{ steps.set-image.outputs.image }}
|
|
||||||
env:
|
env:
|
||||||
EVENT: ${{ github.event_name }}
|
EVENT: ${{ github.event_name }}
|
||||||
REF: ${{ steps.set-repo-and-ref.outputs.ref }}
|
REF: ${{ steps.set-repo-and-ref.outputs.ref }}
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
|
import json
|
||||||
import os
|
import os
|
||||||
import pathlib
|
import pathlib
|
||||||
|
|
||||||
import yaml
|
|
||||||
|
|
||||||
DESCRIPTION = 'description'
|
DESCRIPTION = 'description'
|
||||||
REQUIRED = 'required'
|
REQUIRED = 'required'
|
||||||
|
|
||||||
|
@ -83,6 +82,4 @@ action = {
|
||||||
|
|
||||||
action_path = pathlib.Path('.github/actions/run-docker-container/action.yml')
|
action_path = pathlib.Path('.github/actions/run-docker-container/action.yml')
|
||||||
action_path.parent.mkdir(parents=True, exist_ok=True)
|
action_path.parent.mkdir(parents=True, exist_ok=True)
|
||||||
|
action_path.write_text(json.dumps(action, ensure_ascii=False), encoding='utf-8')
|
||||||
with action_path.open(mode='w', encoding='utf-8') as file:
|
|
||||||
yaml.dump(action, file, allow_unicode=True, sort_keys=False)
|
|
||||||
|
|
|
@ -1,2 +0,0 @@
|
||||||
# NOTE: used by create-docker-action.py
|
|
||||||
pyyaml
|
|
|
@ -1,8 +0,0 @@
|
||||||
#
|
|
||||||
# This file is autogenerated by pip-compile with Python 3.12
|
|
||||||
# by the following command:
|
|
||||||
#
|
|
||||||
# pip-compile --allow-unsafe --config=../.pip-tools.toml --output-file=github-actions.txt --strip-extras github-actions.in
|
|
||||||
#
|
|
||||||
pyyaml==6.0.1
|
|
||||||
# via -r github-actions.in
|
|
Loading…
Reference in New Issue