🌱mimotion.js for V2P

This commit is contained in:
Leon 2021-08-13 00:12:32 +08:00 committed by GitHub
parent 8579d5f02d
commit b02d0bf487
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

23
Scripts/js/mimotion.js Normal file
View File

@ -0,0 +1,23 @@
// @grant nodejs
console.log("⏳ 初始化安装依赖中......")
$exec('pip3 install pytz', {
cwd: './script/Shell',
timeout: 0,
cb(data, error) {
error ? console.error(error) : console.log(data)
}
})
console.log("⏳ 开始执行 mimotion.py")
$exec('python3 https://raw.githubusercontent.com/Oreomeow/VIP/main/Scripts/py/mimotion.py', {
cwd: './script/Shell',
timeout: 0,
env: {
MI_USER: $store.get('MI_USER', 'string'),
MI_PWD: $store.get('MI_PWD', 'string'),
PMODE: $store.get('PMODE', 'string'),
PKEY: $store.get('PKEY', 'string')
},
cb(data, error) {
error ? console.error(error) : console.log(data)
}
})