summaryrefslogtreecommitdiff
path: root/docs/gl_objects
diff options
context:
space:
mode:
authorEric Sabouraud <esabouraud@users.noreply.github.com>2018-10-03 21:36:56 +0200
committerGauvain Pocentek <gauvainpocentek@gmail.com>2018-10-03 21:36:56 +0200
commitea71f1d121b723140671e2090182174234f0e2a1 (patch)
tree4b708c8d0910b17f605639e59d92e22c17a7c12e /docs/gl_objects
parent77f4d3af9c1e5f08b8f4e3aa32c7944c9814dab0 (diff)
downloadgitlab-ea71f1d121b723140671e2090182174234f0e2a1.tar.gz
Add project protected tags management (#581)
Diffstat (limited to 'docs/gl_objects')
-rw-r--r--docs/gl_objects/projects.rst33
1 files changed, 33 insertions, 0 deletions
diff --git a/docs/gl_objects/projects.rst b/docs/gl_objects/projects.rst
index 8c2fc3f..dd444bf 100644
--- a/docs/gl_objects/projects.rst
+++ b/docs/gl_objects/projects.rst
@@ -657,3 +657,36 @@ Edit project push rules::
Delete project push rules::
pr.delete()
+
+Project protected tags
+==================
+
+Reference
+---------
+
+* v4 API:
+
+ + :class:`gitlab.v4.objects.ProjectProtectedTag`
+ + :class:`gitlab.v4.objects.ProjectProtectedTagManager`
+ + :attr:`gitlab.v4.objects.Project.protectedtags`
+
+* GitLab API: https://docs.gitlab.com/ce/api/protected_tags.html
+
+Examples
+---------
+
+Get a list of protected tags from a project::
+
+ protected_tags = project.protectedtags.list()
+
+Get a single protected tag or wildcard protected tag::
+
+ protected_tag = project.protectedtags.get('v*')
+
+Protect a single repository tag or several project repository tags using a wildcard protected tag::
+
+ project.protectedtags.create({'name': 'v*', 'create_access_level': '40'})
+
+Unprotect the given protected tag or wildcard protected tag.::
+
+ protected_tag.delete()