Download and process #113
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Download and process | |
on: | |
workflow_dispatch: | |
inputs: | |
colId: | |
description: 'Collection ID' | |
required: true | |
default: '171233' | |
docId: | |
description: 'Document ID' | |
required: true | |
default: '1233893' | |
jobs: | |
build_pages: | |
name: Download METS files from Transkribus and convert them to TEIs | |
runs-on: ubuntu-latest | |
env: | |
ANT_OPTS: -Xmx6g | |
TR_USER: ${{ secrets.TR_USER }} | |
TR_PW: ${{ secrets.TR_PW}} | |
COL_ID: ${{ github.event.inputs.colId }} | |
DOC_ID: ${{ github.event.inputs.docId }} | |
steps: | |
- name: Perform Checkout | |
uses: actions/checkout@v4 | |
- name: Install Saxon and Ant | |
run: | | |
mkdir -p mets | |
mkdir -p tei | |
apt-get update && apt-get install openjdk-11-jre-headless ant -y --no-install-recommend | |
pip install acdh-transkribus-utils | |
wget https://sourceforge.net/projects/saxon/files/Saxon-HE/9.9/SaxonHE9-9-1-7J.zip/download && unzip download -d saxon && rm -rf download | |
- name: Download METS Files | |
run: | | |
python ./scripts/fetch_mets.py | |
- name: Transform to TEI | |
run: | | |
ant -DCOL_ID=${COL_ID} -f ./build_tei.xml | |
- uses: stefanzweifel/git-auto-commit-action@v5 | |
with: | |
commit_message: Exported and Transformed ColId ${{ github.event.inputs.colId }} |