Revert "Statusprüfungen in Taskfiles der Datenquelle #9"
This reverts commit 1286c8177b
.
This commit is contained in:
parent
489a5cf5b7
commit
3760451b36
20
Taskfile.yml
20
Taskfile.yml
|
@ -56,6 +56,10 @@ tasks:
|
||||||
- rm -f *.xml
|
- rm -f *.xml
|
||||||
# Identifier als Dateinamen
|
# Identifier als Dateinamen
|
||||||
- for f in xx*; do mv "$f" "$(xmllint --xpath "//*[local-name(.) = 'recordIdentifier']/text()" "$f").xml"; done
|
- for f in xx*; do mv "$f" "$(xmllint --xpath "//*[local-name(.) = 'recordIdentifier']/text()" "$f").xml"; done
|
||||||
|
sources:
|
||||||
|
- ../refine/{{.PROJECT}}.txt
|
||||||
|
generates:
|
||||||
|
- ./*.xml
|
||||||
|
|
||||||
validate:
|
validate:
|
||||||
dir: data/{{.PROJECT}}
|
dir: data/{{.PROJECT}}
|
||||||
|
@ -64,6 +68,10 @@ tasks:
|
||||||
# Validierung gegen METS Schema
|
# Validierung gegen METS Schema
|
||||||
- wget -q -nc https://www.loc.gov/standards/mets/mets.xsd
|
- wget -q -nc https://www.loc.gov/standards/mets/mets.xsd
|
||||||
- xmllint --schema mets.xsd --noout split/*.xml > validate.log 2>&1
|
- xmllint --schema mets.xsd --noout split/*.xml > validate.log 2>&1
|
||||||
|
sources:
|
||||||
|
- split/*.xml
|
||||||
|
generates:
|
||||||
|
- validate.log
|
||||||
|
|
||||||
zip:
|
zip:
|
||||||
dir: data/{{.PROJECT}}
|
dir: data/{{.PROJECT}}
|
||||||
|
@ -71,6 +79,10 @@ tasks:
|
||||||
- test -n "{{.PROJECT}}"
|
- test -n "{{.PROJECT}}"
|
||||||
# ZIP-Archiv mit Zeitstempel erstellen
|
# ZIP-Archiv mit Zeitstempel erstellen
|
||||||
- zip -q -FS -j {{.PROJECT}}_{{.DATE}}.zip split/*.xml
|
- zip -q -FS -j {{.PROJECT}}_{{.DATE}}.zip split/*.xml
|
||||||
|
sources:
|
||||||
|
- split/*.xml
|
||||||
|
generates:
|
||||||
|
- "{{.PROJECT}}_{{.DATE}}.zip"
|
||||||
|
|
||||||
diff:
|
diff:
|
||||||
dir: data/{{.PROJECT}}
|
dir: data/{{.PROJECT}}
|
||||||
|
@ -85,6 +97,10 @@ tasks:
|
||||||
- if (( 500 < $(wc -l <diff.log) )); then echo 1>&2 "Unerwartet große Änderungen in $PWD/diff.log!" && exit 1; fi
|
- if (( 500 < $(wc -l <diff.log) )); then echo 1>&2 "Unerwartet große Änderungen in $PWD/diff.log!" && exit 1; fi
|
||||||
# Diff archivieren
|
# Diff archivieren
|
||||||
- cp diff.log {{.PROJECT}}_{{.DATE}}.diff
|
- cp diff.log {{.PROJECT}}_{{.DATE}}.diff
|
||||||
|
sources:
|
||||||
|
- split/*.xml
|
||||||
|
generates:
|
||||||
|
- diff.log
|
||||||
status:
|
status:
|
||||||
# Task nicht ausführen, wenn weniger als zwei ZIP-Archive vorhanden
|
# Task nicht ausführen, wenn weniger als zwei ZIP-Archive vorhanden
|
||||||
- test -z $(ls -t *.zip | sed -n 2p)
|
- test -z $(ls -t *.zip | sed -n 2p)
|
||||||
|
@ -100,6 +116,10 @@ tasks:
|
||||||
- rm -rf links.txt
|
- rm -rf links.txt
|
||||||
# Logdatei auf status code != 2XX prüfen
|
# Logdatei auf status code != 2XX prüfen
|
||||||
- if grep '^[^2]' linkcheck.log; then echo 1>&2 "Logdatei $PWD/linkcheck.log enthält problematische status codes!" && exit 1; fi
|
- if grep '^[^2]' linkcheck.log; then echo 1>&2 "Logdatei $PWD/linkcheck.log enthält problematische status codes!" && exit 1; fi
|
||||||
|
sources:
|
||||||
|
- split/*.xml
|
||||||
|
generates:
|
||||||
|
- linkcheck.log
|
||||||
|
|
||||||
delete:
|
delete:
|
||||||
dir: data/{{.PROJECT}}
|
dir: data/{{.PROJECT}}
|
||||||
|
|
|
@ -3,16 +3,22 @@
|
||||||
version: '3'
|
version: '3'
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
|
# Tasks mit ":" sind für alle Datenquellen gleich in Taskfile.yml definiert
|
||||||
default:
|
default:
|
||||||
desc: OPUS Siegen
|
desc: OPUS Siegen
|
||||||
deps: [harvest]
|
deps: [harvest]
|
||||||
cmds:
|
cmds:
|
||||||
- task: refine
|
- task: refine
|
||||||
- task: check
|
- task: :check
|
||||||
- task: split
|
vars: {PROJECT: "siegen", MINIMUM: "1250"}
|
||||||
- task: validate
|
- task: :split
|
||||||
- task: zip
|
vars: {PROJECT: "siegen"}
|
||||||
- task: diff
|
- task: :validate
|
||||||
|
vars: {PROJECT: "siegen"}
|
||||||
|
- task: :zip
|
||||||
|
vars: {PROJECT: "siegen"}
|
||||||
|
- task: :diff
|
||||||
|
vars: {PROJECT: "siegen"}
|
||||||
|
|
||||||
harvest:
|
harvest:
|
||||||
dir: data/siegen/harvest
|
dir: data/siegen/harvest
|
||||||
|
@ -74,7 +80,6 @@ tasks:
|
||||||
# Temporäre Dateien löschen
|
# Temporäre Dateien löschen
|
||||||
- rm -rf ./*.project* && rm -f workspace.json
|
- rm -rf ./*.project* && rm -f workspace.json
|
||||||
sources:
|
sources:
|
||||||
# wenn "dir:" für task gesetzt ist, dann relative Links ausgehend von dir
|
|
||||||
- ../harvest/siegen.xml
|
- ../harvest/siegen.xml
|
||||||
- ../../../rules/siegen/*.json
|
- ../../../rules/siegen/*.json
|
||||||
- ../../../rules/siegen/template.txt
|
- ../../../rules/siegen/template.txt
|
||||||
|
@ -84,61 +89,11 @@ tasks:
|
||||||
- siegen.txt
|
- siegen.txt
|
||||||
- siegen.openrefine.tar.gz
|
- siegen.openrefine.tar.gz
|
||||||
|
|
||||||
check:
|
|
||||||
cmds:
|
|
||||||
# Tasks mit ":" sind für alle Datenquellen gleich in Taskfile.yml definiert
|
|
||||||
- task: :check
|
|
||||||
vars: {PROJECT: "siegen", MINIMUM: "1250"}
|
|
||||||
sources:
|
|
||||||
# wenn "dir:" für task nicht gesetzt ist, dann relative Links ausgehend von Taskfile.yml
|
|
||||||
- data/siegen/refine/openrefine.log
|
|
||||||
- data/siegen/refine/siegen.txt
|
|
||||||
|
|
||||||
split:
|
|
||||||
cmds:
|
|
||||||
- task: :split
|
|
||||||
vars: {PROJECT: "siegen"}
|
|
||||||
sources:
|
|
||||||
- data/siegen/refine/siegen.txt
|
|
||||||
generates:
|
|
||||||
- data/siegen/split/*.xml
|
|
||||||
|
|
||||||
validate:
|
|
||||||
cmds:
|
|
||||||
- task: :validate
|
|
||||||
vars: {PROJECT: "siegen"}
|
|
||||||
sources:
|
|
||||||
- data/siegen/split/*.xml
|
|
||||||
generates:
|
|
||||||
- data/siegen/validate.log
|
|
||||||
|
|
||||||
zip:
|
|
||||||
cmds:
|
|
||||||
- task: :zip
|
|
||||||
vars: {PROJECT: "siegen"}
|
|
||||||
sources:
|
|
||||||
- data/siegen/split/*.xml
|
|
||||||
generates:
|
|
||||||
- data/siegen/siegen_{{.DATE}}.zip
|
|
||||||
|
|
||||||
diff:
|
|
||||||
cmds:
|
|
||||||
- task: :diff
|
|
||||||
vars: {PROJECT: "siegen"}
|
|
||||||
sources:
|
|
||||||
- data/siegen/split/*.xml
|
|
||||||
generates:
|
|
||||||
- data/siegen/diff.log
|
|
||||||
|
|
||||||
linkcheck:
|
linkcheck:
|
||||||
desc: OPUS Siegen links überprüfen
|
desc: OPUS Siegen links überprüfen
|
||||||
cmds:
|
cmds:
|
||||||
- task: :linkcheck
|
- task: :linkcheck
|
||||||
vars: {PROJECT: "siegen"}
|
vars: {PROJECT: "siegen"}
|
||||||
sources:
|
|
||||||
- data/siegen/split/*.xml
|
|
||||||
generates:
|
|
||||||
- data/siegen/linkcheck.log
|
|
||||||
|
|
||||||
delete:
|
delete:
|
||||||
desc: OPUS Siegen cache löschen
|
desc: OPUS Siegen cache löschen
|
||||||
|
|
|
@ -9,11 +9,16 @@ tasks:
|
||||||
deps: [harvest]
|
deps: [harvest]
|
||||||
cmds:
|
cmds:
|
||||||
- task: refine
|
- task: refine
|
||||||
- task: check
|
- task: :check
|
||||||
- task: split
|
vars: {PROJECT: "wuppertal", MINIMUM: "1300"}
|
||||||
- task: validate
|
- task: :split
|
||||||
- task: zip
|
vars: {PROJECT: "wuppertal"}
|
||||||
- task: diff
|
- task: :validate
|
||||||
|
vars: {PROJECT: "wuppertal"}
|
||||||
|
- task: :zip
|
||||||
|
vars: {PROJECT: "wuppertal"}
|
||||||
|
- task: :diff
|
||||||
|
vars: {PROJECT: "wuppertal"}
|
||||||
|
|
||||||
harvest:
|
harvest:
|
||||||
dir: data/wuppertal/harvest
|
dir: data/wuppertal/harvest
|
||||||
|
@ -77,7 +82,6 @@ tasks:
|
||||||
# Temporäre Dateien löschen
|
# Temporäre Dateien löschen
|
||||||
- rm -rf ./*.project* && rm -f workspace.json
|
- rm -rf ./*.project* && rm -f workspace.json
|
||||||
sources:
|
sources:
|
||||||
# wenn "dir:" für task gesetzt ist, dann relative Links ausgehend von dir
|
|
||||||
- ../harvest/wuppertal.xml
|
- ../harvest/wuppertal.xml
|
||||||
- ../../../rules/wuppertal/*.json
|
- ../../../rules/wuppertal/*.json
|
||||||
- ../../../rules/wuppertal/template.txt
|
- ../../../rules/wuppertal/template.txt
|
||||||
|
@ -87,61 +91,11 @@ tasks:
|
||||||
- wuppertal.txt
|
- wuppertal.txt
|
||||||
- wuppertal.openrefine.tar.gz
|
- wuppertal.openrefine.tar.gz
|
||||||
|
|
||||||
check:
|
|
||||||
cmds:
|
|
||||||
# Tasks mit ":" sind für alle Datenquellen gleich in Taskfile.yml definiert
|
|
||||||
- task: :check
|
|
||||||
vars: {PROJECT: "wuppertal", MINIMUM: "1300"}
|
|
||||||
sources:
|
|
||||||
# wenn "dir:" für task nicht gesetzt ist, dann relative Links ausgehend von Taskfile.yml
|
|
||||||
- data/wuppertal/refine/openrefine.log
|
|
||||||
- data/wuppertal/refine/wuppertal.txt
|
|
||||||
|
|
||||||
split:
|
|
||||||
cmds:
|
|
||||||
- task: :split
|
|
||||||
vars: {PROJECT: "wuppertal"}
|
|
||||||
sources:
|
|
||||||
- data/wuppertal/refine/wuppertal.txt
|
|
||||||
generates:
|
|
||||||
- data/wuppertal/split/*.xml
|
|
||||||
|
|
||||||
validate:
|
|
||||||
cmds:
|
|
||||||
- task: :validate
|
|
||||||
vars: {PROJECT: "wuppertal"}
|
|
||||||
sources:
|
|
||||||
- data/wuppertal/split/*.xml
|
|
||||||
generates:
|
|
||||||
- data/wuppertal/validate.log
|
|
||||||
|
|
||||||
zip:
|
|
||||||
cmds:
|
|
||||||
- task: :zip
|
|
||||||
vars: {PROJECT: "wuppertal"}
|
|
||||||
sources:
|
|
||||||
- data/wuppertal/split/*.xml
|
|
||||||
generates:
|
|
||||||
- data/wuppertal/wuppertal_{{.DATE}}.zip
|
|
||||||
|
|
||||||
diff:
|
|
||||||
cmds:
|
|
||||||
- task: :diff
|
|
||||||
vars: {PROJECT: "wuppertal"}
|
|
||||||
sources:
|
|
||||||
- data/wuppertal/split/*.xml
|
|
||||||
generates:
|
|
||||||
- data/wuppertal/diff.log
|
|
||||||
|
|
||||||
linkcheck:
|
linkcheck:
|
||||||
desc: Elpub Wuppertal links überprüfen
|
desc: Elpub Wuppertal links überprüfen
|
||||||
cmds:
|
cmds:
|
||||||
- task: :linkcheck
|
- task: :linkcheck
|
||||||
vars: {PROJECT: "wuppertal"}
|
vars: {PROJECT: "wuppertal"}
|
||||||
sources:
|
|
||||||
- data/wuppertal/split/*.xml
|
|
||||||
generates:
|
|
||||||
- data/wuppertal/linkcheck.log
|
|
||||||
|
|
||||||
delete:
|
delete:
|
||||||
desc: Elpub Wuppertal cache löschen
|
desc: Elpub Wuppertal cache löschen
|
||||||
|
|
Loading…
Reference in New Issue