Skip to content

Merge pull request #68 from djarecka/new_library_gen #9

Merge pull request #68 from djarecka/new_library_gen

Merge pull request #68 from djarecka/new_library_gen #9

name: generating yaml file
on:
push:
branches:
- main
paths:
- 'linkml-schema/source_library_generation/**'
permissions:
contents: write
jobs:
generate:
runs-on: ubuntu-latest
steps:
- name: Checkout this repository
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Install the required python packages
run: |
python -m pip install .[test]
pip install git+https://github.com/brain-bican/bkbit.git
pip install git+https://github.com/linkml/schemasheets.git@649af7e1
- name: Other installations
run: |
sudo apt-get update
sudo apt-get install -y build-essential git wget curl
- name: Generate yaml model
run: |
cd linkml-schema
bkbit schema2model -o library_generation.yaml --template source_library_generation/classes_base.yaml --gsheet --gsheet-download-dir source_library_generation/gsheet_output source_library_generation/gsheet.yaml
cd ..
- name: Adding other model representations to git
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add linkml-schema/library_generation.yaml
git add linkml-schema/source_library_generation/gsheet_output
if ! git diff --quiet; then
git commit -m "generate new yaml file"
git push
else
echo "No changes to commit"
fi