mirror of
https://github.com/juewuy/ShellCrash.git
synced 2026-03-11 07:51:45 +00:00
~Add i18n support (only menu.sh)
This commit is contained in:
8
scripts/libs/i18n.sh
Normal file
8
scripts/libs/i18n.sh
Normal file
@@ -0,0 +1,8 @@
|
||||
|
||||
load_lang() {
|
||||
i18n=$(cat "$CRASHDIR"/configs/i18n.cfg 2>/dev/null)
|
||||
[ -z "$i18n" ] && i18n=chs
|
||||
|
||||
file="$CRASHDIR/lang/$i18n/$1.lang"
|
||||
[ -s "$file" ] && . "$file"
|
||||
}
|
||||
Reference in New Issue
Block a user