通过CMD远程执行命令(tortoisehg)(PSEXEC)

发布于 2025-02-01 09:05:31 字数 225 浏览 5 评论 0原文

基本上,我想使用PSEXEC来导航到远程计算机中的特定文件夹并执行“ HG Update Branch”。我试图创建以下批次,但我无法执行命令:

psexec cmd.exe /c "cd C:\Project\hg update Test"

它正在阅读,因为“ HG Update Test”是一个文件夹,而不是要完成的命令...我在这里倾斜,这似乎就像基本的东西:(。

Basically I want to use PsExec in order to navigate to a specificar folder in a remote computer and performe "hg update branch". I've tried to create the following batch but I'm not able to perform the command:

psexec cmd.exe /c "cd C:\Project\hg update Test"

It's reading as the "hg update Test" was a folder instead of command to be done... I'm tilting over here and this seems like a basic thing :(. How do I pass the "hg update branch" as cmd command through PsExec?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

栖竹 2025-02-08 09:05:31

您不需要更改目录,只需告诉HG什么路径操作:

psexec cmd.exe /c "hg update -R C:\Project\ Test"

帮助说:

  -r  -  Repository Repo存储库根目录...
 

You don't need to change directory, just tell HG what path to operate in:

psexec cmd.exe /c "hg update -R C:\Project\ Test"

The help says:

 -R --repository REPO   repository root directory ...
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文