From 5ce51053e9363f7fd5b06892336a8a7380ea8198 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Krzysztof=20Mo=C5=9B?= Date: Wed, 15 May 2019 23:48:15 +0200 Subject: [PATCH] =?UTF-8?q?Wywo=C5=82anie=20SCLITE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Jenkinsfile | 7 +++++++ kody-metryki.sh | 8 ++++++++ 2 files changed, 15 insertions(+) create mode 100644 kody-metryki.sh diff --git a/Jenkinsfile b/Jenkinsfile index 15f83e2..ab3ff4d 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -12,7 +12,14 @@ pipeline { sh label: '', script: './kody.sh' sh label: '', script: 'ls -l' archiveArtifacts 'plik1' + } + } + stage('Stage 2') { + steps { + echo 'Metryki' + sh label: '', script: 'chmod 755 ./kody-metryki.sh' + sh label: '', script: './kody-metryki.sh' } } } diff --git a/kody-metryki.sh b/kody-metryki.sh new file mode 100644 index 0000000..4cc97fb --- /dev/null +++ b/kody-metryki.sh @@ -0,0 +1,8 @@ +cut -f 2 wikiniews_results.tsv > reference.txt +cut -f 3 wikiniews_results.tsv > hypothesis.txt + +awk 'BEGIN{FS=OFS="\t"}{print $0,"(sp1_"NR")"}' < hypothesis.txt > hypothesis.trn +awk 'BEGIN{FS=OFS="\t"}{print $0,"(sp1_"NR")"}' < reference.txt > reference.trn + +sclite -f 0 -r reference.trn trn -h hypothesis.trn trn -e utf-8 -i rm -o all stdout > wynik.txt +cat wynik.txt \ No newline at end of file