Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

模仿issues94写 node执行 #169

Closed
huanzhiyi opened this issue Jul 6, 2022 · 5 comments
Closed

模仿issues94写 node执行 #169

huanzhiyi opened this issue Jul 6, 2022 · 5 comments

Comments

@huanzhiyi
Copy link

#94

文件名 jd_bean_change.env.js
$exec('node jd_bean_change.js', {
cwd: 'script/JSFile',
env: {
JD_COOKIE: $store.get('CookiesJDV2P', 'string'),
},
timeout: 0,
cb(data, error){
error ? console.error(error) : console.log(data)
}
})

提示 $exec is not defined 运行版本3.6.8 定时任务 shell命令 node jd_bean_change.env.js -cwd script/JSFile
请问这个问题如何解决

@elecV2
Copy link
Owner

elecV2 commented Jul 6, 2022 via email

@huanzhiyi
Copy link
Author

的确如此。 另外请问如何在v2p中 更好的运行js脚本,有些脚本未适配到v2p。如https://github.com/LinYuanovo/scripts/blob/main/dygy.js 请问用比较便捷的方法令这脚本在v2p中正常运行

@elecV2
Copy link
Owner

elecV2 commented Jul 6, 2022 via email

@huanzhiyi
Copy link
Author

好的 明白 感谢解答

@huanzhiyi
Copy link
Author

huanzhiyi commented Oct 11, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants