-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
152 additions
and
10 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,10 +16,19 @@ jobs: | |
|
||
# Installation and Directories | ||
|
||
- name: Get SDK Version from config | ||
id: lookupSdkVersion | ||
uses: mikefarah/yq@master | ||
with: | ||
cmd: | | ||
yq -o=json CITATION.cff > CITATION.json | ||
|
||
|
||
- name: Download and install saxon | ||
run: | | ||
wget https://sourceforge.net/projects/saxon/files/Saxon-HE/10/Java/SaxonHE10-5J.zip/download | ||
unzip download | ||
wget https://github.com/Saxonica/Saxon-HE/releases/download/SaxonHE12-3/SaxonHE12-3J.zip | ||
unzip SaxonHE12-3J.zip | ||
- name: Make gh-pages_out, keyboards, doc folder | ||
|
@@ -38,42 +47,56 @@ jobs: | |
|
||
- name: Transform MUFI snapshot to Aletheia keyboard | ||
run: | | ||
java -jar saxon-he-10.5.jar -xsl:scripts/keyboard.xsl output=keyboards \ | ||
java -jar saxon-he-12.3.jar -xsl:scripts/keyboard.xsl output=keyboards \ | ||
-s:scripts/keyboard.xsl | ||
shell: bash | ||
|
||
- name: Transform MUFI snapshot to Transkribus keyboard | ||
run: | | ||
java -jar saxon-he-10.5.jar -xsl:scripts/keyboard.xsl output=tkeyboards \ | ||
java -jar saxon-he-12.3.jar -xsl:scripts/keyboard.xsl output=tkeyboards \ | ||
-s:scripts/keyboard.xsl | ||
shell: bash | ||
|
||
|
||
- name: Transform MUFI snapshot to LAREX keyboard | ||
run: | | ||
java -jar saxon-he-10.5.jar -xsl:scripts/keyboard.xsl output=lkeyboards \ | ||
java -jar saxon-he-12.3.jar -xsl:scripts/keyboard.xsl output=lkeyboards \ | ||
-s:scripts/keyboard.xsl | ||
shell: bash | ||
|
||
|
||
- name: Transform MUFI snapshot to qurator-neat keyboard | ||
run: | | ||
java -jar saxon-he-10.5.jar -xsl:scripts/keyboard.xsl output=qkeyboards \ | ||
java -jar saxon-he-12.3.jar -xsl:scripts/keyboard.xsl output=qkeyboards \ | ||
-s:scripts/keyboard.xsl | ||
shell: bash | ||
|
||
- name: Transform MUFI snapshot to eScriptorium keyboard | ||
run: | | ||
java -jar saxon-he-10.5.jar -xsl:scripts/keyboard.xsl output=ekeyboards \ | ||
java -jar saxon-he-12.3.jar -xsl:scripts/keyboard.xsl output=ekeyboards \ | ||
-s:scripts/keyboard.xsl | ||
shell: bash | ||
|
||
- name: Make compressed table view | ||
run: | | ||
java -jar saxon-he-10.5.jar -xsl:scripts/keyboard.xsl output=keytable release=$GITHUB_RUN_NUMBER \ | ||
java -jar saxon-he-12.3.jar -xsl:scripts/keyboard.xsl output=keytable release=$GITHUB_RUN_NUMBER \ | ||
-s:scripts/keyboard.xsl -o:ghout/overview.md | ||
shell: bash | ||
|
||
- name: generate CITATION.cff | ||
run: | | ||
java -jar saxon-he-12.3.jar -xsl:scripts/metadata.xsl \ | ||
output=CITATION repoBase=$GITHUB_REF_Name repoName=$GITHUB_REPOSITORY bagitDumpNum=$GITHUB_RUN_NUMBER releaseTag=$GITHUB_REF_NAME \ | ||
-s:scripts/metadata.xsl -o:rawCITATION.cff | ||
shell: bash | ||
|
||
- name: formating CITATION.cff | ||
id: lookupSdkVersion2 | ||
uses: mikefarah/yq@master | ||
with: | ||
cmd: | | ||
yq -I4 rawCITATION.cff > CITATION.cff | ||
# GH-style | ||
|
||
- name: Copy css styles, keyboards, docs and yml files | ||
|
@@ -101,7 +124,20 @@ jobs: | |
with: | ||
tag_name: v${{ github.run_number }} | ||
release_name: Keyboard-zip-package (Release${{ github.run_number }}) | ||
body_path: CHANGELOG.md | ||
body: | | ||
<dl> | ||
<dt>Version:</dt> | ||
<dd>Keyboard-zip-package (Release${{ github.run_number }}_${{ github.ref_name }})</dd> | ||
<dt>Info:</dt> | ||
<dd> | ||
The file Keyboard-zip-package-v${{ github.run_number }}.zip is a zip archive file.<br/> | ||
<ul><li>If you wish to use the rules, this file must first be unpacked.</li> | ||
<li>The archive file contains virtual keyboards for various transcription editors or tools.</li> | ||
<li>The keyboards are categorized according to the MUFI category scheme.</li> | ||
<li>The column <i>💁 Browse by code chart (Link to MUFI)</i> provides an overview of the scope of the respective keyboard.</li></ul> | ||
</dd> | ||
</dl> | ||
</dl> | ||
draft: false | ||
prerelease: false | ||
|
||
|
@@ -116,6 +152,14 @@ jobs: | |
asset_name: keyboardGT-v${{ github.run_number }}.zip | ||
asset_content_type: application/zip | ||
|
||
- name: Commit CITATION.cff | ||
run: | | ||
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com" | ||
git config --local user.name "github-actions[bot]" | ||
git add CITATION.cff | ||
git commit -m "[Automatic] Update CITATION.cff files" || echo "Nothing to update" | ||
git push origin HEAD:main | ||
- name: Deploy GT-Overview to GitHub Pages | ||
uses: JamesIves/[email protected] | ||
|
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# This CITATION.cff file was generated with cffinit. | ||
# Visit https://bit.ly/cffinit to generate yours today! | ||
|
||
cff-version: 1.2.0 | ||
title: gt-repo-scripts | ||
message: >- | ||
If you use this software, please cite it using the | ||
metadata from this file. | ||
type: software | ||
authors: | ||
- given-names: Matthias | ||
family-names: Boenig | ||
orcid: 'https://orcid.org/0000-0003-4615-4753' | ||
repository-code: 'https://github.com/tboenig/keyboardGT' | ||
url: 'https://tboenig.github.io/keyboardGT/overview.html' | ||
abstract: >- | ||
The Aletheia document image analysis system, Transkribus, | ||
LAREX, QURATOR-neat and eScriptorium offer the possibility | ||
to install additional virtual keyboards or to customize | ||
them. This repository offers about 80 keyboards based on | ||
the Medieval Unicode Font Initiative (MUFI) snapshot for | ||
download on the Github page. | ||
keywords: | ||
- ocr-d | ||
- transcription | ||
- ground-truth | ||
- aletheia | ||
- transkribus | ||
- escriptorium | ||
- larex | ||
- qurator-neat | ||
- page-xml | ||
license: CC-BY-SA-4.0 | ||
commit: v1.1.0 | ||
version: 5_v1.1.0 | ||
date-released: '2024-04-17' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<xsl:stylesheet | ||
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" | ||
xmlns:math="http://www.w3.org/2005/xpath-functions/math" | ||
xmlns:xs="http://www.w3.org/2001/XMLSchema" | ||
xmlns:fn="http://www.w3.org/2005/xpath-functions" | ||
xmlns:pc="http://schema.primaresearch.org/PAGE/gts/pagecontent/2019-07-15" | ||
xmlns:pt="http://schema.primaresearch.org/PAGE/gts/pagecontent/2013-07-15" | ||
xmlns:in="http://www.intern.de" | ||
xmlns:gt="http://www.ocr-d.de/GT/" | ||
xmlns:mets="http://www.loc.gov/METS/" | ||
xmlns:mods="http://www.loc.gov/mods/v3" | ||
xmlns:ns3="http://www.loc.gov/METS/" | ||
exclude-result-prefixes="#all" | ||
version="3.0"> | ||
<xsl:output indent="yes" omit-xml-declaration="yes" method="xml"/> | ||
|
||
|
||
<xsl:param name="repoName"/> | ||
<xsl:param name="repoBase"/> | ||
<xsl:param name="bagitDumpNum"/> | ||
<xsl:param name="releaseTag"/> | ||
|
||
|
||
|
||
|
||
<xsl:variable name="docMETADATA"> | ||
<xsl:copy-of select="json-to-xml(unparsed-text('../CITATION.json'))"/> | ||
</xsl:variable> | ||
|
||
<xsl:param name="output"/> | ||
|
||
<xsl:template match="/"> | ||
|
||
<xsl:if test="$output = 'CITATION'"> | ||
<xsl:variable name="Author"> | ||
<xsl:if test="$docMETADATA//fn:map/fn:array/@key='authors'">authors:<xsl:for-each select="$docMETADATA//fn:map/fn:array[@key='authors']/fn:map"> | ||
<xsl:variable name="combinedValue_name" select="fn:string[@key='name'] | fn:string[@key='given-names']"/> | ||
<xsl:variable name="combinedValue_surname" select="fn:string[@key='surname'] | fn:string[@key='family-names']"/> | ||
<xsl:if test="fn:string[@key='name'] or fn:string[@key='given-names'] !=''"> | ||
- given-names: <xsl:value-of select="$combinedValue_name"/></xsl:if> | ||
<xsl:if test="fn:string[@key='surname'] | fn:string[@key='family-names'] !=''"> | ||
family-names: <xsl:value-of select="$combinedValue_surname"/></xsl:if> | ||
<xsl:if test="fn:string[@key='orcid'] !=''"> | ||
orcid: '<xsl:value-of select="fn:string[@key='orcid']"/>'</xsl:if> | ||
</xsl:for-each></xsl:if> | ||
</xsl:variable>cff-version: 1.2.0 | ||
title: <xsl:value-of select="$docMETADATA//fn:map/fn:string[@key='title']"/> | ||
message: If you use this dataset, please cite it using the metadata from this file. | ||
type: dataset | ||
<xsl:value-of select="$Author"/> | ||
repository-code: '<xsl:text>https://github.com/</xsl:text><xsl:value-of select="$repoName"/>' | ||
url: '<xsl:text>https://github.com/</xsl:text><xsl:value-of select="$repoName"/>' | ||
abstract: <xsl:value-of select="normalize-space($docMETADATA//fn:map/fn:string[@key='abstract'])"/> | ||
keywords:<xsl:for-each select="$docMETADATA//fn:map/fn:array[@key='keywords']/fn:string"> | ||
- <xsl:value-of select="."/> | ||
</xsl:for-each> | ||
license: <xsl:value-of select="$docMETADATA//fn:map/fn:string[@key='license']"/> | ||
commit: <xsl:value-of select="$releaseTag"/> | ||
version: <xsl:value-of select="$bagitDumpNum"/>_<xsl:value-of select="$releaseTag"/> | ||
date-released: '<xsl:value-of select="format-date(current-date(), '[Y0001]-[M01]-[D01]')"/>'</xsl:if> | ||
</xsl:template> | ||
</xsl:stylesheet> |