8000 Merge pull request #929 from SVLay/docs/pipeline-variables · python-gitlab/python-gitlab@4efa6e6 · GitHub
[go: up one dir, main page]

Skip to content

Commit 4efa6e6

Browse files
authored
Merge pull request #929 from SVLay/docs/pipeline-variables
docs(pipelines_and_jobs): add pipeline custom variables usage example
2 parents 1f18230 + b275eb0 commit 4efa6e6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/gl_objects/pipelines_and_jobs.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ Get variables of a pipeline::
3333

3434
variables = pipeline.variables.list()
3535

36 6079 -
Create a pipeline for a particular reference::
36+
Create a pipeline for a particular reference with custom variables::
3737

38-
pipeline = project.pipelines.create({'ref': 'master'})
38+
pipeline = project.pipelines.create({'ref': 'master', 'variables': [{'key': 'MY_VARIABLE', 'value': 'hello'}]})
3939

4040
Retry the failed builds for a pipeline::
4141

0 commit comments

Comments
 (0)
0