小编liv*_*luv的帖子

批处理脚本 - 为每个令牌调用子例程

我试图将令牌传递给批处理脚本中的子程序 -

SET devices=host1 host2 host3
FOR /F "tokens=* delims=," %%G IN (%devices%) DO CALL :sendReq %%G

:sendReq

curl.exe http://%1:1234/service/monitor

GOTO :EOF
Run Code Online (Sandbox Code Playgroud)

问题 - The system cannot find the file host1- 错误信息不确定原因.

%1是不是要解决host1

dos batch-file

2
推荐指数
1
解决办法
1万
查看次数

标签 统计

batch-file ×1

dos ×1