Skip to content

Commit 94a3b05

Browse files
authored
Rename to Learn Validation
1 parent c6f20e8 commit 94a3b05

File tree

1 file changed

+65
-38
lines changed

1 file changed

+65
-38
lines changed

Diff for: README.md

+65-38
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,46 @@
1-
# Docs Validation
1+
# Learn Validation
22

3-
This extension enables you to run build validation on a Docs conceptual or Learn repo at author time in VS Code. This means you can make sure your repo is free of validation issues before making a pull request.
3+
This extension enables you to run build validation on a Learn conceptual or reference repository at author time in VS Code. This means you can make sure your repo is free of validation issues before making a pull request.
44

5-
[!IMPORTANT]
6-
> The source codes of the repo have been moved into Azure DevOps to follow security and compliance requirements. We will revisit the open source strategy in the future and may open the repo as open source again. Stay tuned!
7-
> You are still welcomed to submit your issues or feature requests via [Issues](#issue).
5+
## Prerequisites
86

9-
## How to use the Docs Validation extension
7+
- Install [git](https://git-scm.com/downloads).
8+
- Clone your Learn repo locally in VS Code.
9+
- All files in the repo must be saved when you are using the manually triggered validation.
10+
11+
## How to use the Learn Validation extension
1012

1113
### Manually triggered validation
1214

13-
1. Open the root folder or any sub-folder of a Docs conceptual or Learn repo in VS Code with the extension installed.
15+
1. Open the root folder or any sub-folder of a Learn repository in VS Code with the extension installed.
1416
1. For the first time you use the extension, you will be asked to choose your user type between **Microsoft employee** and **Public contributor** before you can use full-repository validation.
15-
1. For **Microsoft employee**, you are required to sign in before using full-repository validation. You can click **Docs Validation** on the status bar then click **Sign in** from the drop-down menu to sign in.
17+
1. For **Microsoft employee**, you are required to sign in before using full-repository validation. You can click **Learn Validation** on the status bar then click **Sign in** from the drop-down menu to sign in.
1618
1. There are three ways to trigger the manual validation:
1719
1. After signing in, you can trigger a validation by clicking **Validate** when prompted. This will trigger the validation on the current opening workspace, so the files outside the current workspace will not be validated if you are on the sub-folder of a repository.
18-
2. You can click **Docs Validation** on the status bar then click **Validate the current workspace** from the drop-down menu to trigger the validation on the current workspace.
20+
2. You can click **Learn Validation** on the status bar then click **Validate the current workspace** from the drop-down menu to trigger the validation on the current workspace.
1921
3. You can right-click any file/folder inside the **Explorer** and select **Validate this folder**, if you click on the file, the validation will be applied to the folder contains the selected file, otherwise, the validation will be applied to the selected folder.
2022
1. Build validation will run locally and all results will be output to the Problems pane.
2123

22-
![OAuth](./resources/vscode-docs-build.gif?raw=true)
24+
![OAuth](https://github.com/docascode/vscode-docs-build/blob/main/resources/vscode-docs-build.gif?raw=true)
2325

24-
> **Note:** The first time you validate a repo, all the Docs build dependencies will be fetched and cached locally. Subsequent validation runs will be faster.
26+
> **Note:** The first time you validate a repo, all the Learn build dependencies will be fetched and cached locally. Subsequent validation runs will be faster.
2527
2628
### Real-time validation
2729

28-
1. Open the root folder or any sub-folder of a Docs conceptual or Learn repo in VS Code with the extension installed.
30+
1. Open the root folder or any sub-folder of a or Learn repository in VS Code with the extension installed.
2931
2. For the first time you use the extension, you will be asked to choose your user type between **Microsoft employee** and **Public contributor** before you can use real-time validation.
30-
3. The real-time validation is enabled by default, you can disable it in the extension settings (Go to Settings -> Docs Validation -> Uncheck **Real-time Validation: Automatically Enable**). You will be asked to reload the extension after you disable real-time validation.
32+
3. The real-time validation is enabled by default, you can disable it in the extension settings (Go to Settings -> Learn Validation -> Uncheck **Real-time Validation: Automatically Enable**). You will be asked to reload the extension after you disable real-time validation.
3133

32-
![OAuth](./resources/enable-real-time-validation.gif?raw=true)
34+
![OAuth](https://github.com/docascode/vscode-docs-build/blob/main/resources/enable-real-time-validation.gif?raw=true)
3335

3436
4. For **Microsoft employee**, the extension will check your sign-in status before real-time validation starts to work. If you haven't signed in or your credential expired, you will be asked to sign in. After sign-in succeeds, real-time validation will start automatically.
3537
5. With real-time validation enabled, you will see validation issues (if any) while you are working on the repository (eg. modifying files, creating files and deleting files etc.).
3638

37-
![OAuth](./resources/real-time-validation-exp.gif?raw=true)
39+
![OAuth](https://github.com/docascode/vscode-docs-build/blob/main/resources/real-time-validation-exp.gif?raw=true)
3840

3941
## Known issues
4042

41-
### Inconsistent results between Docs Build validation and full-repository validation.
43+
### Inconsistent results between Learn Build validation and full-repository validation.
4244

4345
- bookmark-not-found: The rendering information required to validate bookmarks in schema-based content isn't available publicly, so if you aren't signed in as a Microsoft employee you might not get all broken bookmark results.
4446
- author-not-found and ms-author-invalid: These validations require external API calls that aren't supported locally at this time, so no results will be returned for them.
@@ -52,13 +54,13 @@ Inconsistent results caused by the currently edited file needs validation result
5254
- publish-url-conflict
5355
- output-path-conflict
5456
- Content or Metadata uniqueness
55-
- duplicate-uid
56-
- xref-property-conflict
57-
- moniker-overlapping
58-
- duplicate-title
59-
- altText-duplicate
60-
- duplicate-h1
61-
- ...
57+
- duplicate-uid
58+
- xref-property-conflict
59+
- moniker-overlapping
60+
- duplicate-title
61+
- altText-duplicate
62+
- duplicate-h1
63+
- ...
6264
- bookmark-not-found
6365
- Validation on hierarchy (for example `unit-no-module-parent`)
6466

@@ -71,6 +73,7 @@ Inconsistent results caused by the currently edited file affects other files' va
7173
- file-not-found
7274

7375
Other situations:
76+
7477
- Pull-request-only suggestions will be ignored by full-repository validation but will be reported by real-time validation.
7578
- Include files will not be validated before you open any file includes them.
7679
- .openpublishing.redirection.json will not be validated before you open any content file (.md or .yml).
@@ -87,7 +90,7 @@ When your validation fails with some error message like:
8790

8891
```bash
8992
fatal: unable to access 'https://github.com/Microsoft/templates.docs.msft/': The requested URL returned error: 403
90-
git-clone-failed Failure to clone the repository `https://github.com/Microsoft/templates.docs.msft#master`. This could be caused by an incorrect repository URL, please verify the URL on the Docs Portal (https://ops.microsoft.com). This could also be caused by not having the proper permission the repository, please confirm that the GitHub group/team that triggered the build has access to the repository.
93+
git-clone-failed Failure to clone the repository `https://github.com/Microsoft/templates.docs.msft#master`. This could be caused by an incorrect repository URL, please verify the URL on the Microsoft Learn Portal (https://ops.microsoft.com). This could also be caused by not having the proper permission the repository, please confirm that the GitHub group/team that triggered the build has access to the repository.
9194
Restore done in 11.77s
9295

9396
1 Error(s), 0 Warning(s), 0 Suggestion(s)
@@ -114,13 +117,15 @@ Please try the following solutions:
114117
```
115118
116119
1. GitHub has recently enabled SSO on Microsoft-owned organizations. If you see the below errors, please follow the instructions there to enable SSO on your token so that local validation can pass through.
120+
117121
```bash
118122
fatal: unable to access 'https://github.com/Microsoft/templates.docs.msft/': The requested URL returned error: 403
119123
remote: The `microsoft' organization has enabled or enforced SAML SSO. To access
120124
remote: this repository, visit https://github.com/enterprises/microsoftopensource/sso?authorization_request=AEJANEWOPPW6YTNW5TYNW2K7OBDR3A5PN5ZGOYLONF5GC5DJN5XF62LEZYAF32PCVVRXEZLEMVXHI2LBNRPWSZGODVDHWBVPMNZGKZDFNZ2GSYLML52HS4DFVNHWC5LUNBAWGY3FONZQ
121125
```
122126

123127
1. If you see the below errors while cloning the template repository, this is caused by that you used the `Git Credential Manager Core` before GitHub enabled the SSO, and you need to re-authorize the application.
128+
124129
```bash
125130
$ git clone https://github.com/microsoft/templates.docs.msft.git
126131
Cloning into 'templates.docs.msft'...
@@ -130,39 +135,61 @@ Please try the following solutions:
130135
```
131136
132137
Please follow the steps below to re-authorize, you can either:
138+
133139
- Sign in with your browser.
134140
135-
a. Go to [Github application setting page](https://github.com/settings/applications).
136-
137-
b. Go inside `Git Credential Manager` and click `Revoke access`.
141+
a. Go to [Github application setting page](https://github.com/settings/applications).
142+
143+
b. Go inside `Git Credential Manager` and click `Revoke access`.
138144
139-
c. Retry to clone the repository in commander/ terminal.
145+
c. Retry to clone the repository in commander/ terminal.
146+
147+
d. Select `Sign in with your browser` in the pop-up window.
140148
141-
d. Select `Sign in with your browser` in the pop-up window.
142149
- Sign in with `Personal Access Token`.
143150
144-
a. Go to [Github token setting page](https://github.com/settings/tokens).
145-
146-
b. Generate a new token if you don't have one. Enter the note of the token, check `repo` in `Select scopes` section, and click `Generate token`.
151+
a. Go to [Github token setting page](https://github.com/settings/tokens).
147152
148-
c. Enable the SSO for the token used in `Git Credential Manager Core`.
153+
b. Generate a new token if you don't have one. Enter the note of the token, check `repo` in `Select scopes` section, and click `Generate token`.
149154
150-
![OAuth](./resources/enable-sso.png?raw=true)
155+
c. Enable the SSO for the token used in `Git Credential Manager Core`.
151156
152-
d. Retry to clone the repository in commander/ terminal.
157+
![OAuth](https://github.com/docascode/vscode-docs-build/blob/main/resources/enable-sso.png?raw=true)
153158
154-
e. Enter `Personal Access Token` in the pop-up window.
159+
d. Retry to clone the repository in commander/ terminal.
155160
161+
e. Enter `Personal Access Token` in the pop-up window.
156162
157163
## License
158164
159-
[MIT](https://raw.githubusercontent.com/docascode/vscode-docs-build/master/LICENSE)
165+
[MIT](https://raw.githubusercontent.com/docascode/vscode-docs-build/main/LICENSE)
160166
161167
## Privacy statements
162168
163169
For Microsoft employee: https://privacy.microsoft.com/en-US/data-privacy-notice
164170
For Public contributor: https://privacy.microsoft.com/en-us/privacystatement
165171
172+
## Key
173+
166174
## Issue
167175
168-
[File a issue](./docs/file-issue.md)
176+
[File a issue](https://github.com/docascode/vscode-docs-build/blob/main/docs/file-issue.md)
177+
178+
## How to Contribute
179+
180+
[Contribution guideline](https://github.com/docascode/vscode-docs-build/blob/main/docs/contribution-guide.md)
181+
182+
## Pipelines
183+
184+
| Pipeline | Description | Trigger condition | Status |
185+
|--|--|--|--|
186+
| **vscode-docs-build-CodeCheck** | SDL related code check built on OneBranch | PR created to main branch <br /> `or` Code Merged into main branch | [![Build Status](https://ceapex.visualstudio.com/Engineering/_apis/build/status/OneBranch/vscode-docs-build/vscode-docs-build-CodeCheck?repoName=vscode-docs-build&branchName=main)](https://ceapex.visualstudio.com/Engineering/_build/latest?definitionId=4230&repoName=vscode-docs-build&branchName=main) |
187+
| **vscode-docs-build-CodeTest** | Run Test and collect the test coverage on two platforms: Windows and MacOS | PR created to main branch <br /> `or` Code Merged into main branch | [![Build Status](https://ceapex.visualstudio.com/Engineering/_apis/build/status/vscode-docs-build/vscode-docs-build-CodeTest?branchName=main)](https://ceapex.visualstudio.com/Engineering/_build/latest?definitionId=4350&branchName=main) |
188+
| **vscode-docs-build-LGTM** | LGTM related check | Code Merged into main branch | [![Build Status](https://ceapex.visualstudio.com/Engineering/_apis/build/status/vscode-docs-build/vscode-docs-build-LGTM?branchName=main)](https://ceapex.visualstudio.com/Engineering/_build/latest?definitionId=4327&branchName=main) |
189+
| **vscode-docs-build-Official** | Official release pipeline | Manual trigger | [![Build Status](https://ceapex.visualstudio.com/Engineering/_apis/build/status/OneBranch/vscode-docs-build/vscode-docs-build-Official?repoName=vscode-docs-build&branchName=main)](https://ceapex.visualstudio.com/Engineering/_build/latest?definitionId=4333&repoName=vscode-docs-build&branchName=main) |
190+
191+
## Secrets management
192+
193+
Please reference the document [Secrets managements](https://microsoft.sharepoint.com/teams/docsmicrosoftcom/_layouts/OneNote.aspx?id=%2Fteams%2Fdocsmicrosoftcom%2FShared%20Documents%2FOPS%20Build%2FOPS%20Build%20Channel%20OneNote&wd=target%28Docs%20Validation%20VSCode%20Extension.one%7C885B4924-63D4-4A36-9FF8-045844298BA0%2FSecrets%20managements%7C6BE16B1A-058E-486C-8563-6D340DEF0187%2F%29) for the detail
194+
195+
**All contributions are welcome!**

0 commit comments

Comments
 (0)