forked from tk-sls.de/linuxfoo-gitlab
document "releases" feature
This commit is contained in:
parent
520bf8d107
commit
ffd8fd7f30
19
README.md
19
README.md
@ -4,14 +4,20 @@
|
||||
|
||||
Embed a list of the most recent commits to a Gitlab project. Information is retrieved from a specified Gitlab instance's public REST API.
|
||||
|
||||
## Shortcode `gitlab-list-commits`
|
||||
## Shortcode `gitlab-show-project`
|
||||
|
||||
### Example
|
||||
### Examples
|
||||
|
||||
Add the following shortcode to your post for a list of at most 5 commits to that project that were made since at most 3 months ago:
|
||||
Add the following shortcode for a list of at most 5 commits to that project that were made since at most 3 months ago:
|
||||
|
||||
```
|
||||
[gitlab-list-commits url="https://tk-sls.de/gitlab" project_id=42 since="3 months" max=5]
|
||||
[gitlab-show-project url="https://tk-sls.de/gitlab" project_id=42 since="3 months" max=5]
|
||||
```
|
||||
|
||||
Add the following shortcode for a list of at most 3 commits followed by a link to the latest release:
|
||||
|
||||
```
|
||||
[gitlab-show-project url="https://tk-sls.de/gitlab" project_id=42 max=3 release="latest"]
|
||||
```
|
||||
|
||||
### Attributes
|
||||
@ -20,8 +26,9 @@ Add the following shortcode to your post for a list of at most 5 commits to that
|
||||
* `project_id=NUM`: Mandatory; `NUM`: Positive Integer, valid project ID in Gitlab specified by `url` (example: `42`).
|
||||
* `since="NUM UNIT"`: Optional; `NUM`: Positive integer; `UNIT`: `days`, `months`, `years`; exclude commits older than specified time interval (example: `3 months`).
|
||||
* `max=NUM`: Optional; `NUM`: Positive integer; list not more than `NUM` commits (example: `5`).
|
||||
* `ref_name=STRING`: List only commit from branch or reference name `STRING` (examples: `main`, `v1.1`).
|
||||
* `default_branch`: If set, list only commits from the project's default branch.
|
||||
* `ref_name=STRING`: Optional: list only commit from branch or reference name `STRING` (examples: `main`, `v1.1`).
|
||||
* `default_branch`: Optional; if set, list only commits from the project's default branch.
|
||||
* `release=STRING`: Optional; if set, `STRING` can be either `all` (show a list of all releases of this project) or `latest` (show a link to the latest release of this project, if any).
|
||||
|
||||
## Author and License
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user