-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Added support for version 4 of the Gitlab API #100
Added support for version 4 of the Gitlab API #100
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
docs/prerequisites.md
still mentions setting up python-gitlab3.
It should be noted that the correct version of this project works with the latest version of gitlab. The api v4 has not yet been removed. Regarding sams comment, I hope to find some time this weekend to update the documentation so this can be merged. |
@zyronix thanks if you don't get to it I can merge it and update the docs myself. @timofonic it's not dead per day. Mostly in maintenance mode if you were to classify it at all. I haven't developed any new features but do wish to keep the project working and compatible with GitLab. I still use gitlab-mirrors myself to mirror projects to different places. I still see value in keeping this project around simply by the activity from people using it. |
config.sh.SAMPLE
Outdated
@@ -42,6 +42,8 @@ gitlab_url="https://gitlab.example.com" | |||
gitlab_user="gitmirror" | |||
#Generate a token for your $gitlab_user and set it here. | |||
gitlab_user_token_secret="$(head -n1 "${user_home}/private_token" 2> /dev/null || echo "")" | |||
#Sets the Gitlab API version, either 3 or 4 | |||
gitlab_api_version=3 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Default to 4. Version 4 was supported in Gitlab 9.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am OK with defaulting to v4.
I have updated the documentation and felt so free to predict that you are going to create a 0.6 release :). Any more changes required? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. I'll test this in the development branch before releasing to master.
* Added support for version 4 of the Gitlab API * Defaulting to APIv4 * Updated documentation
Hi,
As already discussed, I managed to get this project to run with gitlab API version 4. A new parameter has been added to the config, gitlab_api_version, which defaults to version 3 for backward compatibility (even when it is not set).
I tested it with Gitlab 8, 9 & 10 all seem to be working fine.
The only thing that is still left to do is update the documentation. I could add it to this PR as well, but I saw that it was part of the release process and thus left it out.
The main difference here is that the python requirements are different. The basic requirement is to install python-gitlab (and its dependencies).