Skip to content
This repository was archived by the owner on Sep 11, 2023. It is now read-only.

Commit cca7627

Browse files
authored
Update docs (#6)
1 parent 2f95c62 commit cca7627

9 files changed

Lines changed: 97 additions & 74 deletions

File tree

.azext/changelog-cache.json

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,19 @@
11
{
22
"issues": [],
3-
"pullRequests": []
3+
"pullRequests": [
4+
{
5+
"id": 872397756,
6+
"number": 2,
7+
"submitter": "joachimdalen",
8+
"title": "Open source extension",
9+
"url": "https://github.com/joachimdalen/azdevops-pull-request-utils/pull/2"
10+
},
11+
{
12+
"id": 872402943,
13+
"number": 3,
14+
"submitter": "joachimdalen",
15+
"title": "Add repository to manifest",
16+
"url": "https://github.com/joachimdalen/azdevops-pull-request-utils/pull/3"
17+
}
18+
]
419
}

.azext/changelog.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
"changes": [
66
{
77
"type": "maint",
8-
"description": "Align all task versions to `0.4.0`"
8+
"description": "Align all task versions to `0.4.0`",
9+
"pullRequest": [2, 3]
910
}
1011
],
1112
"modules": [

CHANGELOG.md

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
# Changelog
22

3-
## 1.0.0 (2022-03-XX)
3+
## 1.0.0 (2022-03-12)
44

55
### 🛠️ Maintenance (1)
66

7-
- Align all task versions to `0.3.0`
7+
- Align all task versions to `0.4.0`
8+
- Changed in
9+
- [PR#2 - Open source extension](https://github.com/joachimdalen/azdevops-pull-request-utils/pull/2)
10+
- [PR#3 - Add repository to manifest](https://github.com/joachimdalen/azdevops-pull-request-utils/pull/3)
811

912
### 📦 Module changes
1013

@@ -14,19 +17,19 @@
1417

1518
- Added module with shared code
1619

17-
#### `PullRequestDescription@0.3.0`
20+
#### `PullRequestDescription@0.4.0`
1821

1922
- Update dependencies
2023

21-
#### `PullRequestComments@0.3.0`
24+
#### `PullRequestComments@0.4.0`
2225

2326
- Update dependencies
2427

25-
#### `PullRequestStatus@0.3.0`
28+
#### `PullRequestStatus@0.4.0`
2629

2730
- Update dependencies
2831

29-
#### `PullRequestTags@0.3.0`
32+
#### `PullRequestTags@0.4.0`
3033

3134
- Update dependencies
3235

@@ -36,19 +39,19 @@
3639

3740
- Update docs
3841

39-
#### `PullRequestDescription@0.3.0`
42+
#### `PullRequestDescription@0.4.0`
4043

4144
- Update docs
4245

43-
#### `PullRequestComments@0.3.0`
46+
#### `PullRequestComments@0.4.0`
4447

4548
- Update docs
4649

47-
#### `PullRequestStatus@0.3.0`
50+
#### `PullRequestStatus@0.4.0`
4851

4952
- Update docs
5053

51-
#### `PullRequestTags@0.3.0`
54+
#### `PullRequestTags@0.4.0`
5255

5356
- Update docs
5457

build-doc-site.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,13 @@ azext readme generate --input ./docs/tasks/pull-request-comments.md --output ./d
55
azext readme generate --input ./docs/tasks/pull-request-tags.md --output ./docs/generated/tasks/pull-request-tags.md --profile doc-site
66
azext readme generate --input ./docs/tasks/pull-request-description.md --output ./docs/generated/tasks/pull-request-description.md --profile doc-site
77
azext readme generate --input ./docs/tasks/pull-request-status.md --output ./docs/generated/tasks/pull-request-status.md --profile doc-site
8+
9+
azext readme generate --input ./tasks/pull-request-comments/docs/README.md --output ./tasks/pull-request-comments/README.md --profile github
10+
azext readme generate --input ./tasks/pull-request-tags/docs/README.md --output ./tasks/pull-request-tags/README.md --profile github
11+
azext readme generate --input ./tasks/pull-request-description/docs/README.md --output ./tasks/pull-request-description/README.md --profile github
12+
azext readme generate --input ./tasks/pull-request-status/docs/README.md --output ./tasks/pull-request-status/README.md --profile github
13+
14+
azext changelog generate
15+
16+
echo "---\nsidebar_position: 2\ntitle: 'Changelog'\n---\n$(cat CHANGELOG.md)" > ./docs/generated/changelog.md
17+

docs/tasks/_category_.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"label": "Tasks",
3-
"position": 1
3+
"position": 3
44
}

tasks/pull-request-comments/README.md

Lines changed: 15 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,7 @@
66

77
---
88

9-
## Options
10-
11-
### Example
9+
## YAML Snippet
1210

1311
```yaml
1412
- task: PullRequestComments@0
@@ -24,21 +22,21 @@
2422

2523
```
2624

27-
### All Options
25+
## Arguments
2826

29-
| Option | Default Value | Required | Help | Options |
30-
| :-------------------- | :------------------------------------ | :------: | :------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :------------------------------------------------ |
31-
| `action` | `create` || Action to perform | `create`, `createOrUpdate`, `update` |
32-
| `skipIfCommentExists` | `true` || If the comment exists on the pull request, do not post it again | -- |
33-
| `commentId` | -- || Is used to uniqely identify the comment when using the same task multiple times in the same pipeline | -- |
34-
| `status` | `Active` || Post the comment with a given status | `Active`, `Fixed`, `WontFix`, `Closed`, `Pending` |
35-
| `content` | -- || The content of the comment. For Markdown syntax, see [Syntax guidance for basic Markdown usage](http://go.microsoft.com/fwlink/?LinkId=823918) | -- |
36-
| `useDefined` | `false` || If set, overrides the value from `System.PullRequest.PullRequestId` | -- |
37-
| `pullRequestId` | `$(System.PullRequest.PullRequestId)` | | If no id is given, the value from `System.PullRequest.PullRequestId` is taken. If a value is given, this overrides the value from `System.PullRequest.PullRequestId` | -- |
38-
| `type` | `Text` || The type of comment. `Text` represents a regular user comment while `System` indicates a system message | `Text`, `System` |
27+
| Argument | Description |
28+
| :----------------------------------------------------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
29+
| `action` <br />Action | **(Optional)** Action to perform <br /> Options: `create`, `createOrUpdate`, `update` <br /> Default value: `create` |
30+
| `skipIfCommentExists` <br />Do not post comment if it exists | **(Optional)** If the comment exists on the pull request, do not post it again <br /> Default value: `true` |
31+
| `commentId` <br />Comment Id | **(Optional)** Is used to uniqely identify the comment when using the same task multiple times in the same pipeline <br /> |
32+
| `status` <br />Comment Status | **(Optional)** Post the comment with a given status <br /> Options: `Active`, `Fixed`, `WontFix`, `Closed`, `Pending` <br /> Default value: `Active` |
33+
| `content` <br />Comment Content | **(Required)** The content of the comment. For Markdown syntax, see [Syntax guidance for basic Markdown usage](http://go.microsoft.com/fwlink/?LinkId=823918) <br /> |
34+
| `useDefined` <br />Use defined id | **(Optional)** If set, overrides the value from `System.PullRequest.PullRequestId` <br /> |
35+
| `pullRequestId` <br />Pull Request Id | **(Optional)** If no id is given, the value from `System.PullRequest.PullRequestId` is taken. If a value is given, this overrides the value from `System.PullRequest.PullRequestId` <br /> Default value: `$(System.PullRequest.PullRequestId)` |
36+
| `type` <br />Comment Type | **(Optional)** The type of comment. `Text` represents a regular user comment while `System` indicates a system message <br /> Options: `Text`, `System` <br /> Default value: `Text` |
3937

4038

41-
## Examples
39+
### Examples
4240

4341
## Posting a comment
4442

@@ -56,7 +54,7 @@ steps:
5654
5755
after a run against a pull request it will post the comment:
5856
59-
![simple-comment](../../marketplace/docs/images/simple-pr-comment.png)
57+
![simple-pr-comment.png](../../marketplace/docs/images/simple-pr-comment.png)
6058
6159
6260
## Posting a comment with markdown
@@ -81,7 +79,7 @@ steps:
8179
8280
after a run against a pull request it will post the comment:
8381
84-
![simple-comment](../../marketplace/docs/images/markdown-pr-comment.png)
82+
![markdown-pr-comment.png](../../marketplace/docs/images/markdown-pr-comment.png)
8583
8684
8785
## Posting multiple comments

tasks/pull-request-description/README.md

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,7 @@
66

77
---
88

9-
## Options
10-
11-
### Example
9+
## YAML Snippet
1210

1311
```yaml
1412
- task: PullRequestDescription@0
@@ -23,22 +21,22 @@
2321

2422
```
2523

26-
### All Options
24+
## Arguments
2725

28-
| Option | Default Value | Required | Help | Options |
29-
| :----------------- | :------------------------------------ | :------: | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------- |
30-
| `action` | `append` || The action to perform | `append`, `replace`, `view` |
31-
| `content` | -- || The content to append or replace original description with. Required when action is `append` or `replace`. For Markdown syntax, see [Syntax guidance for basic Markdown usage](http://go.microsoft.com/fwlink/?LinkId=823918) **Supports usage of variables.** | -- |
32-
| `useDefined` | `false` || Use the pre-defined id for the pull request. If set, overrides the value from `System.PullRequest.PullRequestId`. Default: `false` | -- |
33-
| `pullRequestId` | `$(System.PullRequest.PullRequestId)` | | If no id is given, the value from `System.PullRequest.PullRequestId` is taken. If a value is given, this overrides the value from `System.PullRequest.PullRequestId` | -- |
34-
| `outputVariable` | `PullRequest.DescriptionContent` || The name of the output variable to write the description to. Default `PullRequest.DescriptionContent`. Applies to actions `view` | -- |
35-
| `isOutput` | -- || If set, `outputVariable` is set as output and accessible from other jobs. Applies to actions `view` | -- |
36-
| `stripIdentifiers` | `false` || Strip internal modifiers before setting variable. Applies to actions `view` | -- |
26+
| Argument | Description |
27+
| :----------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
28+
| `action` <br />Action | **(Required)** The action to perform <br /> Options: `append`, `replace`, `view` <br /> Default value: `append` |
29+
| `content` <br />Content | **(Required)** The content to append or replace original description with. Required when action is `append` or `replace`. For Markdown syntax, see [Syntax guidance for basic Markdown usage](http://go.microsoft.com/fwlink/?LinkId=823918) **Supports usage of variables.** <br /> |
30+
| `useDefined` <br />Use defined id | **(Optional)** Use the pre-defined id for the pull request. If set, overrides the value from `System.PullRequest.PullRequestId`. Default: `false` <br /> |
31+
| `pullRequestId` <br />Pull Request Id | **(Optional)** If no id is given, the value from `System.PullRequest.PullRequestId` is taken. If a value is given, this overrides the value from `System.PullRequest.PullRequestId` <br /> Default value: `$(System.PullRequest.PullRequestId)` |
32+
| `outputVariable` <br />Output Variable | **(Optional)** The name of the output variable to write the description to. Default `PullRequest.DescriptionContent`. Applies to actions `view` <br /> Default value: `PullRequest.DescriptionContent` |
33+
| `isOutput` <br />Is output | **(Optional)** If set, `outputVariable` is set as output and accessible from other jobs. Applies to actions `view` <br /> |
34+
| `stripIdentifiers` <br />Strip Identifiers | **(Optional)** Strip internal modifiers before setting variable. Applies to actions `view` <br /> |
3735

3836

3937
## Examples
4038

41-
## Append content
39+
### Append content
4240

4341
Append will append content to the end of the PR on the first run. On sequential runs the content will be replaced. A markdown comment will be added to the pull request so the task knows where to replace content from.
4442

@@ -53,7 +51,7 @@ steps:
5351
---
5452
5553
56-
## Replace content
54+
### Replace content
5755
5856
The following configuration will replace the entire pull request description on each run.
5957
@@ -68,7 +66,7 @@ steps:
6866
---
6967
7068
71-
## Set as variable
69+
### Set as variable
7270
7371
Write the content of description to a variable.
7472

0 commit comments

Comments
 (0)