wxhelper-docker/install-wechat.sh
李寻欢 2ec2ac668a
Some checks failed
BuildImage / build-image (push) Has been cancelled
update
2024-02-23 13:57:40 +08:00

53 lines
1.1 KiB
Bash

#!/usr/bin/env bash
## https://gitlab.com/cunidev/gestures/-/wikis/xdotool-list-of-key-codes
function install() {
while :
do
xdotool search '微信安装向导'
NOTFOUND=$?
echo $NOTFOUND
if [ "$NOTFOUND" == "0" ]; then
echo "微信安装包已打开,等待安装"
sleep 80
xdotool key Tab
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key space
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key Return
sleep 16
xdotool key Tab
sleep 0.5
xdotool key Tab
sleep 0.5
xdotool key Return
break
fi
sleep 5
done
}
id
wine 'C:\WeChatSetup.exe' &
sudo ps -ef
sleep 1m
install
wait
sleep 10