File tree Expand file tree Collapse file tree 1 file changed +61
-0
lines changed
Expand file tree Collapse file tree 1 file changed +61
-0
lines changed Original file line number Diff line number Diff line change @@ -128,3 +128,64 @@ Example:
128128.. code-block :: console
129129
130130 $ gitlab -v -g elsewhere -c /tmp/gl.cfg project list
131+
132+
133+ Examples
134+ ========
135+
136+ List all the projects:
137+
138+ .. code-block :: console
139+
140+ $ gitlab project list
141+
142+ Limit to 5 items per request, display the 1st page only
143+
144+ .. code-block :: console
145+
146+ $ gitlab project list --page 1 --per-page 5
147+
148+ Get a specific project (id 2):
149+
150+ .. code-block :: console
151+
152+ $ gitlab project get --id 2
153+
154+ Get a list of snippets for this project:
155+
156+ .. code-block :: console
157+
158+ $ gitlab project-issue list --project-id 2
159+
160+ Delete a snippet (id 3):
161+
162+ .. code-block :: console
163+
164+ $ gitlab project-snippet delete --id 3 --project-id 2
165+
166+ Update a snippet:
167+
168+ .. code-block :: console
169+
170+ $ gitlab project-snippet update --id 4 --project-id 2 \
171+ --code "My New Code"
172+
173+ Create a snippet:
174+
175+ .. code-block :: console
176+
177+ $ gitlab project-snippet create --project-id=2
178+ Impossible to create object (Missing attribute(s): title, file-name, code)
179+
180+ $ # oops, let's add the attributes:
181+ $ gitlab project-snippet create --project-id=2 --title="the title" \
182+ --file-name="the name" --code="the code"
183+
184+ Define the status of a commit (as would be done from a CI tool for example):
185+
186+ .. code-block :: console
187+
188+ $ gitlab project-commit-status create --project-id 2 \
189+ --commit-id a43290c --state success --name ci/jenkins \
190+ --target-url http://server/build/123 \
191+ --description "Jenkins build succeeded"
You can’t perform that action at this time.
0 commit comments