在我在 bitbucket 托管的项目中,我有这样的bitbucket-pipelines.yml
文件:
pipelines:
default:
- step:
name: "Test and build"
...do something
- step:
name: "Deploy to test"
...do something
tags:
release-*:
- step:
name: "Test and build"
...do something
- step:
name: "Deploy to test"
...do something
- step:
name: "Deploy to prod"
...do something else
我想release-*
使用atlassian-python-api
. 但是,每次我尝试这样做时,我都会得到requests.exceptions.HTTPError: 400 Client Error: Bad Request for url
. 我的代码如下所示:
bitbucket = Cloud(url=URL, username=USERNAME, password=PASSWORD, cloud=True)
r = bitbucket.workspaces.get(WORKSPACE).projects.get(PROJECT).repositories.get(REPOSITORY)
t = r.pipelines.trigger(
branch="master",
commit="<COMMIT HASH>",
pattern="release-*"
)
如何更改模式以便我能够运行release-*
管道?