Skip to content

v0.2

v0.2 #19

Workflow file for this run

name: CD
on:
push:
branches: [ "master" ]
release:
types: [created]
jobs:
build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: make install
- name: Cache LexDB
id: cache-lexdb
uses: actions/cache@v4.0.0
with:
save-always: true
path: dta_lexdb.sqlite
key: lexdb-sql
- name: Get LexDB
if: steps.cache-lexdb.outputs.cache-hit != 'true'
run: make dta_lexdb.sqlite
- name: Cache word lists
id: cache-lists
uses: actions/cache@v4.0.0
with:
save-always: true
path: |
dta_lexdb_10.words
dta_lexdb_50.words
dta_lexdb_100.words
key: lexdb-words
- name: Extract word lists
if: steps.cache-lists.outputs.cache-hit != 'true'
run: make dta_lexdb_10.words dta_lexdb_50.words dta_lexdb_100.words
- name: Cache models
id: cache-models
uses: actions/cache@v4.0.0
with:
save-always: true
path: |
frak2021.traineddata
GT4HistOCR.traineddata
ONB.traineddata
Fraktur_5000000.traineddata
german_print.traineddata
frk.traineddata
Fraktur.traineddata
key: lexdb-models
- name: Download models
if: steps.cache-models.outputs.cache-hit != 'true'
run: make get-tess
- name: Create Tesseract models
run: make all-tess
- name: Create Hunspell dict
run: make all-hunspell
- name: Create release
if: github.event_name != 'release'
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.sha }}
release_name: Release ${{ github.sha }}
body: Auto generated release
draft: true
prerelease: false
- name: Upload assets
uses: csexton/release-asset-action@master
with:
pattern: "{*_dta*.traineddata,de-dta.*}"
github-token: ${{ secrets.GITHUB_TOKEN }}
release-url: ${{ steps.create_release.outputs.upload_url }}