我正在尝试为依赖关系管理工具修缮创建一个管道
# Runs the renovate bot on a schedule.
# Adapted from: https://blog.objektkultur.de/how-to-setup-renovate-in-azure-devops/
schedules:
- cron: "0 5 * * *"
displayName: "Every day at 7am"
branches:
include:
- main
- master
always: true
trigger: none
pool:
vmImage: ubuntu-latest
variables:
- group: "renovatebot"
steps:
- checkout: self
persistCredentials: true
fetchDepth: 1
- bash: |
git config --global user.email 'bot@renovateapp.com'
git config --global user.name 'Renovate Bot'
echo "TOKEN = $TOKEN"
echo "GITHUB_COM_TOKEN = $GITHUB_COM_TOKEN"
npx renovate
env:
TOKEN: $(System.AccessToken)
GITHUB_COM_TOKEN: $(githubtoken) # get a token from https://github.com/settings/tokens and save it in the 'renovatebot' variables group
#RENOVATE_CONFIG_FILE: "./pipelines/renovate/config.js" # use this environment variable if you prefer to have the renovate pipeline definition and the config file in it's own dictionary instead of the repository root.它使用System.AccessToken运行GIT命令。这适用于单个回购,但我试图将另一个存储库合并到同一个管道中--但是,我得到了以下错误:
ERROR: Repository is not found (repository=[REDACTED]/[REDACTED])
这使我相信访问第二个存储库存在一些问题。
steps:
- checkout: git://FabrikamFiber/FabrikamTools # Azure Repos Git repository in the same organization
- script: # Do something with that repo
# Or you can reference it with a uses statement in the job
uses:
repositories: # List of referenced repositories
- FabrikamTools # Repository reference to FabrikamTools
steps:
- script: # Do something with that repo like clone it然而,如果我在蔚蓝中尝试,我会得到一个错误:

我遗漏了什么?“使用”语句的正确用法是什么?
发布于 2022-09-22 09:23:08
“使用”语句的正确用法是什么?
要使用 use:语句,需要在作业级别定义它。
例如:
jobs:
- job: test
uses:
repositories:
- test
steps:
- script:xxx有关更详细的信息,请参阅下面的doc:jobs.job定义
https://stackoverflow.com/questions/73799584
复制相似问题