mirror of
https://github.com/Ralim/IronOS.git
synced 2025-02-26 07:53:55 +00:00
Langs check (#2006)
Some checks failed
CI / tests (push) Has been cancelled
CI / check_c-cpp (push) Has been cancelled
Docs / deploy-docs (push) Has been cancelled
CI / build (MHP30) (push) Has been cancelled
CI / check_python (push) Has been cancelled
CI / build (Pinecil) (push) Has been cancelled
CI / build (Pinecilv2) (push) Has been cancelled
CI / build (S60) (push) Has been cancelled
CI / build (S60P) (push) Has been cancelled
CI / build (T55) (push) Has been cancelled
CI / build (TS100) (push) Has been cancelled
CI / check_shell (push) Has been cancelled
CI / build (TS101) (push) Has been cancelled
CI / build (TS80) (push) Has been cancelled
CI / build (TS80P) (push) Has been cancelled
CI / build_multi-lang (Pinecil) (push) Has been cancelled
CI / build_multi-lang (Pinecilv2) (push) Has been cancelled
CI / check_docs (push) Has been cancelled
CI / upload_metadata (push) Has been cancelled
Some checks failed
CI / tests (push) Has been cancelled
CI / check_c-cpp (push) Has been cancelled
Docs / deploy-docs (push) Has been cancelled
CI / build (MHP30) (push) Has been cancelled
CI / check_python (push) Has been cancelled
CI / build (Pinecil) (push) Has been cancelled
CI / build (Pinecilv2) (push) Has been cancelled
CI / build (S60) (push) Has been cancelled
CI / build (S60P) (push) Has been cancelled
CI / build (T55) (push) Has been cancelled
CI / build (TS100) (push) Has been cancelled
CI / check_shell (push) Has been cancelled
CI / build (TS101) (push) Has been cancelled
CI / build (TS80) (push) Has been cancelled
CI / build (TS80P) (push) Has been cancelled
CI / build_multi-lang (Pinecil) (push) Has been cancelled
CI / build_multi-lang (Pinecilv2) (push) Has been cancelled
CI / check_docs (push) Has been cancelled
CI / upload_metadata (push) Has been cancelled
* source/Makefile: add temp change for demo * scripts/deploy.sh: add test check for languages * scripts/deploy.sh: shellcheck sanitization * source/Makefile: revert changes for the demo
This commit is contained in:
@@ -90,6 +90,22 @@ docs_history()
|
||||
return "${ret}"
|
||||
}
|
||||
|
||||
# source/Makefile:ALL_LANGUAGES & Translations/*.json automagical routine
|
||||
build_langs()
|
||||
{
|
||||
mk="../source/Makefile"
|
||||
cd Translations/ || exit 1
|
||||
langs="$(echo "$(find ./*.json | sed -ne 's,^\./translation_,,; s,\.json$,,; /[A-Z]/p' ; sed -ne 's/^ALL_LANGUAGES=//p;' "${mk}")" | sed 's, ,\n,g; s,\r,,g' | sort | uniq -u)"
|
||||
ret=0
|
||||
if [ -n "${langs}" ]; then
|
||||
ret=1
|
||||
echo "It seems there is mismatch between supported languages and enabled builds."
|
||||
echo "Please, check files in Translations/ and ALL_LANGUAGES variable in source/Makefile for:"
|
||||
echo "${langs}"
|
||||
fi;
|
||||
return "${ret}"
|
||||
}
|
||||
|
||||
# Helper function to check code style using clang-format & grep/sed custom parsers:
|
||||
# - basic logic moved from source/Makefile : `check-style` target for better maintainance since a lot of sh script involved;
|
||||
# - output goes in gcc-like error compatible format for IDEs/editors.
|
||||
@@ -173,7 +189,9 @@ if [ "docs" = "${cmd}" ]; then
|
||||
readme="${?}"
|
||||
docs_history
|
||||
hist="${?}"
|
||||
if [ "${readme}" -eq 0 ] && [ "${hist}" -eq 0 ]; then
|
||||
build_langs
|
||||
langs="${?}"
|
||||
if [ "${readme}" -eq 0 ] && [ "${hist}" -eq 0 ] && [ "${langs}" -eq 0 ]; then
|
||||
ret=0
|
||||
else
|
||||
ret=1
|
||||
@@ -195,6 +213,11 @@ if [ "docs_history" = "${cmd}" ]; then
|
||||
exit "${?}"
|
||||
fi;
|
||||
|
||||
if [ "build_langs" = "${cmd}" ]; then
|
||||
build_langs
|
||||
exit "${?}"
|
||||
fi;
|
||||
|
||||
if [ "check_style_file" = "${cmd}" ]; then
|
||||
check_style_file "${2}"
|
||||
exit "${?}"
|
||||
|
||||
Reference in New Issue
Block a user