summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Wittig <max.wittig95@gmail.com>2019-10-24 15:21:40 +0200
committerGitHub <noreply@github.com>2019-10-24 15:21:40 +0200
commitc6004e724e6fd73105cc091001de79b88ce4f3d9 (patch)
treecbe3b3c7af09ab6b763fc1a77b3fe9a42799337d
parentdad68050c1269519f35dcdb29dc94a03f47532c5 (diff)
downloadgitlab-feat/python-gitlab-agent.tar.gz
feat: send python-gitlab version as user-agentfeat/python-gitlab-agent
-rw-r--r--gitlab/__init__.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/gitlab/__init__.py b/gitlab/__init__.py
index c73e697..6b2ea6a 100644
--- a/gitlab/__init__.py
+++ b/gitlab/__init__.py
@@ -94,7 +94,9 @@ class Gitlab(object):
#: Timeout to use for requests to gitlab server
self.timeout = timeout
#: Headers that will be used in request to GitLab
- self.headers = {}
+ self.headers = {
+ "User-Agent": "%s/%s" % (__title__, __version__)
+ }
#: Whether SSL certificates should be validated
self.ssl_verify = ssl_verify