diff --git a/README.md b/README.md index 86cbc8b73..45841eac2 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![License: GPL3+](https://img.shields.io/badge/License-GPL3+-blue.svg?style=flat-square)](https://www.gnu.org/licenses/gpl-3.0.en.html) [![status-badge](https://ci.codeberg.org/api/badges/Calciumdibromid/CaBr2/status.svg)](https://ci.codeberg.org/Calciumdibromid/CaBr2) -[![Crowdin](https://badges.crowdin.net/cabr2/localized.svg)](https://crowdin.com/project/cabr2) +[![Translation status](https://translate.codeberg.org/widgets/cabr2/-/svg-badge.svg)](https://translate.codeberg.org/engage/cabr2/) Generate "experiment wise safety sheets" in compliance to European law. @@ -43,6 +43,4 @@ To learn more about a specific part of this project, go to the corresponding REA ## Translate -Translation is done via [Crowdin](https://crowdin.com/project/cabr2). - -To improve the translation of a language or add a new one visit [https://crowdin.com/project/cabr2](https://crowdin.com/project/cabr2). +[![Translation Status](https://translate.codeberg.org/widgets/cabr2/-/open-graph.png)](https://translate.codeberg.org/engage/cabr2/) diff --git a/contrib/pull-translations b/contrib/pull-translations deleted file mode 100755 index 5931f079c..000000000 --- a/contrib/pull-translations +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/bash - -###################################### -# pull locale files from crowdin and # -# create a pull if there are changes # -###################################### - -cd "$(dirname "$0")/.." -token="$1" - -# make config if not exist -[ -f "crowdin.yml" ] || { - # make sure it exists - [ -z "$token" ] && { - echo "token not set" - exit 1 - } - sed "s/-TOKEN-/${token}/g" crowdin.example.yml >crowdin.yml -} - -# crowdin action -crowdin pull || exit 1 - -# normalize locales -for i in $(ls assets/translations/??_??.json); do - file_old=$i - file_new=$(echo "$file_old" | tr '[:upper:]' '[:lower:]') - [ "$file_old" == "$file_new" ] || { - cp -f "$file_old" "$file_new" && rm "$file_old" - } -done diff --git a/contrib/push-translations b/contrib/push-translations deleted file mode 100755 index 8bd7707fb..000000000 --- a/contrib/push-translations +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash - -################################ -# push locale files to crowdin # -################################ - -cd "$(dirname "$0")/.." -token="$1" - -# make config if not exist -[ -f "crowdin.yml" ] || { - # make sure it exists - [ -z "$token" ] && { - echo "token not set" - exit 1 - } - sed "s/-TOKEN-/${token}/g" crowdin.example.yml > crowdin.yml -} - -# crowdin action -crowdin push || exit 1 diff --git a/crowdin.example.yml b/crowdin.example.yml deleted file mode 100644 index 9aad160dd..000000000 --- a/crowdin.example.yml +++ /dev/null @@ -1,14 +0,0 @@ -# Use this file to create your own crowdin.yml that is in the .gitignore because of the token - -"project_id": "444900" -"api_token": "-TOKEN-" - -"base_path": "assets/translations" -"preserve_hierarchy": false -files: - [ - { - "source": "en_us.json", - "translation": "%locale_with_underscore%.json", - }, - ]