我的目标是
\n\n我已完成第 1 步,但我似乎找不到从 API 调用中提取的文件。\n这是获取邮递员脚本的 API 调用的日志:
\n\n2020-02-11T13:54:34.8779080Z attempting to call Postman API for environment..\n2020-02-11T13:54:34.8781038Z file /home/vsts/work/1/a/postman\\EA.API.pipeline.json Saved!\nRun Code Online (Sandbox Code Playgroud)\n\n这是测试阶段运行邮递员脚本步骤的结果(我尝试访问pilot.environment和EA.API.pipeline.json):
\n\nerror: ENOENT: no such file or directory, open \'/home/vsts/work/1/a/postman/environments/pilot.environment.json\'\nRun Code Online (Sandbox Code Playgroud)\n\n现在我考虑的一个选项是在阶段之间擦除这些目录。我在构建阶段获取脚本,并尝试在测试阶段运行它们。这就是为什么在提取脚本后,我确保它们实际上在存储中,然后我尝试将它们作为工件发布:
\n\n========================== Starting Command Output ===========================\n/bin/bash --noprofile --norc /home/vsts/work/_temp/xxxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx.sh\n/home/vsts/work/1/a\n\xe2\x94\x9c\xe2\x94\x80\xe2\x94\x80 postman\\\n\xe2\x94\x9c\xe2\x94\x80\xe2\x94\x80 postman\\EA.API.pipeline.json\nRun Code Online (Sandbox Code Playgroud)\n\n但在同一构建阶段的下一步中,我尝试将这些测试作为工件发布,并收到此错误:
\n\n##[error]Path does not exist: /home/vsts/work/1/a/postman/EA.API.pipeline.json\nRun Code Online (Sandbox Code Playgroud)\n\n这是 yaml:
\n\n - task: OneLuckiDev.getPostmanJSON.vsts-release-web-test.oneLuckiGetPostmanScripts@1\n displayName: \'Get Postman Script\'\n inputs:\n fileLocation: \'$(build.artifactstagingdirectory)/postman\'\n apiKey: \'$(PostmanAPIKey)\'\n - script: \'sudo apt-get …Run Code Online (Sandbox Code Playgroud)