Skip to content

Commit

Permalink
[#53411] 13.4 Documentation: GitLab integration - review (#15026)
Browse files Browse the repository at this point in the history
* [#53411] 13.4 Documentation: GitLab integration - review

https://community.openproject.org/work_packages/53411

* update GitLab docs

* Delete README.md

---------

Co-authored-by: Maya Berdygylyjova <[email protected]>
  • Loading branch information
dominic-braeunlein and MayaBerd authored Mar 19, 2024
1 parent 13920df commit 3c879d8
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ First you will need to create a user in OpenProject that has the permission to m

![GitLab role with required permissions in OpenProject](openproject-system-guide-gitlab-integration-role.png)

This user will then have to be **added to each project** with a role that allows them to see work packages and comment on them.
This user will then have to be **added to each project** with a role that allows them to see work packages and comment on them.

![GitLab user added as member to project with respective role](openproject-system-guide-gitlab-integration-project-member.png)

Expand All @@ -48,11 +48,11 @@ Once the user is created you need to generate an OpenProject API token for this
3. Go to [*Access Tokens*](../../../getting-started/my-account/#access-tokens)
4. Click on **+ API token**

> Make sure you copy the generated key an securely save it, as you will not be able to retrieve it later.
> Make sure you copy the generated key and securely save it, as you will not be able to retrieve it later.
You can then configure the necessary webhook in [GitLab](#gitlab).

Finally you will need to activate the GitLabmodule under [Project settings](../../../user-guide/projects/project-settings/modules/) so that all information pulling through from GitLab will be shown in the work packages.
Finally you will need to activate the GitLab module under [Project settings](../../../user-guide/projects/project-settings/modules/) so that all information pulling through from GitLab will be shown in the work packages.

![Activate a GitLab module in OpenProject](openproject-system-guide-gitlab-integration-project-modules.png)

Expand Down Expand Up @@ -106,7 +106,7 @@ Once you are satisfied with the changes you can create a commit. Within the 'Git

![Copy a Git commit message in OpenProject](openproject-system-guide-gitlab-integration-git-snippets-commit-message.png)

A URL pointing to a work package in the merge request description or a comment will link the two. The link needs to be in the MR and not in a commit, but GitLab will use the first commit message as the proposed branch description (as long as there is only one commit).
A URL pointing to a work package in the merge request description or a comment will link the two. The link needs to be in the MR and not in a commit, but GitLab will use the first commit message as the proposed branch description (as long as there is only one commit). Alternatively you can also use 'OP#' as a work package reference in an issue or a MR title, in this case "OP#388", where 388 is the ID of the work package.

![Commit message in a Git client](openproject-system-guide-gitlab-integration-commit-message-in-client.png)

Expand All @@ -116,7 +116,7 @@ Once the changes are made, you can create your merge request. Title and comment

The branch description can be amended before a MR is created giving the opportunity to further describe the changes. To help with that, it is also possible to copy parts of the work package description since the description can be displayed in the markdown format. Links to additional work packages can also be included in the MR description.

Rather than inserting a link to the work package you can also reference it just by adding "OP#388" to the pull request's description where 388 is the ID of the work package
If you use OP# as a reference in an Issue or MR title, all comments will be replicated in OpenProject. However, sometimes you may only want to keep information about the status of an Issue/MR in OpenProject without your comments being published. In this case, you can use "PP#" as a reference. For example "PR#388". This way the comments will not be published in OpenProject. If you only want to publish one of the comments from a private Issue/MR, you can use "OP#" directly in that comment. This way only that specific comment will be published in OpenProject, but the rest of the comments will remain private. [Read more](https://github.com/btey/openproject-gitlab-integration?tab=readme-ov-file#difference-between-op-and-pp).

![Open a GitLab merge request](openproject-system-guide-gitlab-integration-create-mr-detail.png)

Expand Down Expand Up @@ -150,4 +150,4 @@ You can either create a new issue in GitLab, or edit an already existing one. En

Once you save your changes or create a GitLab issue, it will become visible under the **GitLab** tab in OpenProject.

![New GitLab issues shown in OpenProject work packages](openproject-system-guide-gitlab-integration-new-issues.png)
![New GitLab issues shown in OpenProject work packages](openproject-system-guide-gitlab-integration-new-issues.png)

0 comments on commit 3c879d8

Please sign in to comment.