Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-06-16 21:25:58 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-06-16 21:25:58 +0300
commita5f4bba440d7f9ea47046a0a561d49adf0a1e6d4 (patch)
treefb69158581673816a8cd895f9d352dcb3c678b1e /doc/user/project/badges.md
parentd16b2e8639e99961de6ddc93909f3bb5c1445ba1 (diff)
Add latest changes from gitlab-org/gitlab@14-0-stable-eev14.0.0-rc42
Diffstat (limited to 'doc/user/project/badges.md')
-rw-r--r--doc/user/project/badges.md31
1 files changed, 30 insertions, 1 deletions
diff --git a/doc/user/project/badges.md b/doc/user/project/badges.md
index 1834bc20aee..64a375c6a1d 100644
--- a/doc/user/project/badges.md
+++ b/doc/user/project/badges.md
@@ -15,7 +15,7 @@ points to. Examples for badges can be the [pipeline status](../../ci/pipelines/s
[test coverage](../../ci/pipelines/settings.md#test-coverage-report-badge), or ways to contact the
project maintainers.
-![Badges on Project overview page](img/project_overview_badges_v13_10.png)
+![Badges on Project information page](img/project_overview_badges_v13_10.png)
## Project badges
@@ -90,6 +90,35 @@ default branch or commit SHA when the project is configured to have a private
repository. This is by design, as badges are intended to be used publicly. Avoid
using these placeholders if the information is sensitive.
+## Use custom badge images
+
+Use custom badge images in a project or a group if you want to use badges other than the default
+ones.
+
+Prerequisites:
+
+- A valid URL that points directly to the desired image for the badge.
+ If the image is located in a GitLab repository, use the raw link to the image.
+
+Using placeholders, here is an example badge image URL referring to a raw image at the root of a repository:
+
+```plaintext
+https://gitlab.example.com/<project_path>/-/raw/<default_branch>/my-image.svg
+```
+
+To add a new badge to a group or project with a custom image:
+
+1. Go to your group or project and select **Settings > General**.
+1. Expand **Badges**.
+1. Under **Name**, enter the name for the badge.
+1. Under **Link**, enter the URL that the badge should point to.
+1. Under **Badge image URL**, enter the URL that points directly to the custom image that should be
+ displayed.
+1. Select **Add badge**.
+
+To learn how to use custom images generated via a pipeline, see our documentation on
+[accessing the latest job artifacts by URL](../../ci/pipelines/job_artifacts.md#access-the-latest-job-artifacts-by-url).
+
## API
You can also configure badges via the GitLab API. As in the settings, there is