init
Some checks failed
Docker. / Ubuntu (push) Has been cancelled
User-agent updater. / User-agent (push) Failing after 15s
Lock Threads / lock (push) Failing after 10s
Waiting for answer. / waiting-for-answer (push) Failing after 22s
Needs user action. / needs-user-action (push) Failing after 8s
Can't reproduce. / cant-reproduce (push) Failing after 8s
Close stale issues and PRs / stale (push) Has been cancelled
Some checks failed
Docker. / Ubuntu (push) Has been cancelled
User-agent updater. / User-agent (push) Failing after 15s
Lock Threads / lock (push) Failing after 10s
Waiting for answer. / waiting-for-answer (push) Failing after 22s
Needs user action. / needs-user-action (push) Failing after 8s
Can't reproduce. / cant-reproduce (push) Failing after 8s
Close stale issues and PRs / stale (push) Has been cancelled
This commit is contained in:
38
Telegram/ThirdParty/hime/scripts/hime-user-setup
vendored
Normal file
38
Telegram/ThirdParty/hime/scripts/hime-user-setup
vendored
Normal file
@@ -0,0 +1,38 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ -z "$1" ] || [ -z "$2" ]; then
|
||||
echo "please specify hime_table_dir hime_bin_dir"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
pushd "$HOME"
|
||||
|
||||
if [ ! -d .config/hime/config ]; then
|
||||
mkdir -p .config/hime/config
|
||||
fi
|
||||
|
||||
cd "$1" || echo "$1 is not a hime table dir"
|
||||
|
||||
for i in pho.tab2 pho-huge.tab2 s-pho.tab2 s-pho-huge.tab2 tsin* s-tsin* symbol-table phrase.table; do
|
||||
if [ ! -f "$HOME/.config/hime/$i" ]; then
|
||||
cp "$i" ~/.config/hime
|
||||
fi
|
||||
done
|
||||
|
||||
pushd "$HOME/.config/hime"
|
||||
|
||||
diff1=''
|
||||
if ! diff tsin-1.src "$1/tsin-1.src" >/dev/null 2>&1; then
|
||||
diff1='Y'
|
||||
fi
|
||||
|
||||
if [ ! -f tsin-1.src ] || [ -n "$diff1" ]; then
|
||||
echo "merge tsin-1.src"
|
||||
cp "$1/tsin-1.src" .
|
||||
"$2/hime-tsd2a32" tsin32 >tmpfile
|
||||
cat tsin-1.src >>tmpfile
|
||||
"$2/hime-tsa2d32" tmpfile
|
||||
fi
|
||||
|
||||
popd # ~/.config/hime
|
||||
popd # ~/
|
||||
Reference in New Issue
Block a user