Skip to content

Updating Mental Health Ontology mapping to LSRs.xlsx #64

Updating Mental Health Ontology mapping to LSRs.xlsx

Updating Mental Health Ontology mapping to LSRs.xlsx #64

on:
push:
branches:
- main
paths:
- "Mapping to LSRs/Mental Health Ontology mapping to LSRs.xlsx"
permissions:
contents: write
jobs:
get_context:
runs-on: ubuntu-latest
outputs:
action_bot_email: "41898282+github-actions[bot]@users.noreply.github.com"
commit_author: ${{ steps.get_author.outputs.out }}
steps:
- uses: actions/checkout@v4
- id: get_author
run: >
echo out=$(git log -1 "$SHA" --format="%aE") >> "$GITHUB_OUTPUT"
env:
SHA: ${{ github.sha }}
convert_to_csv:
runs-on: ubuntu-latest
name: Convert LSR mapping from Excel to CSV
needs: get_context
if: ${{ needs.get_context.outputs.commit_author != needs.get_context.outputs.action_bot_email }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
cache: 'pip' # caching pip dependencies
- name: Install dependencies
run: pip install -r scripts/requirements.txt
- name: Run conversion
run: python3 scripts/excel2csv.py -i "Mapping to LSRs/Mental Health Ontology mapping to LSRs.xlsx"
- uses: EndBug/add-and-commit@v9 # You can change this to use a specific version.
with:
add: '"Mapping to LSRs"'
default_author: 'github_actions'
message: "Converted LSR mapping Excel to CSV"
push: true