Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion eng/common/scripts/Verify-Links.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ $ProgressPreference = "SilentlyContinue"; # Disable invoke-webrequest progress d

function ProcessLink([System.Uri]$linkUri) {
# To help improve performance and rate limiting issues with github links we try to resolve them based on a local clone if one exists.
if (($localGithubClonedRoot -or $localBuildRepoName) -and $linkUri -match '^https://github.com/(?<org>Azure)/(?<repo>[^/]+)/(?:blob|tree)/(main|.*_[^/]+|.*/v[^/]+)/(?<path>.*)$') {
if (($localGithubClonedRoot -or $localBuildRepoName) -and $linkUri -match '^https://github.com/(?<org>(Azure|microsoft))/(?<repo>[^/]+)/(?:blob|tree)/(main|.*_[^/]+|.*/v[^/]+)/(?<path>.*)$') {

if ($localBuildRepoName -eq ($matches['org'] + "/" + $matches['repo'])) {
# If the link is to the current repo, use the local build path
Expand Down
27 changes: 14 additions & 13 deletions eng/pipelines/githubio-linkcheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,21 +15,22 @@ jobs:
steps:
- pwsh: |
$reposToClone = @(
"azure-rest-api-specs",
"azure-sdk",
"azure-sdk-for-android",
"azure-sdk-for-c",
"azure-sdk-for-cpp",
"azure-sdk-for-go",
"azure-sdk-for-ios",
"azure-sdk-for-java",
"azure-sdk-for-js",
"azure-sdk-for-net",
"azure-sdk-for-python",
"azure-sdk-for-rust"
"Azure/azure-rest-api-specs",
"Azure/azure-sdk",
"Azure/azure-sdk-for-android",
"Azure/azure-sdk-for-c",
"Azure/azure-sdk-for-cpp",
"Azure/azure-sdk-for-go",
"Azure/azure-sdk-for-ios",
"Azure/azure-sdk-for-java",
"Azure/azure-sdk-for-js",
"Azure/azure-sdk-for-net",
"Azure/azure-sdk-for-python",
"Azure/azure-sdk-for-rust",
"microsoft/mcp"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see you added the repo to clone but you also still need to point it at a file in the repo to verify so the links get cached.

)
foreach ($repo in $reposToClone) {
git clone https://github.com/Azure/${repo}.git --depth 1 --single-branch --branch main
git clone https://github.com/${repo}.git --depth 1 --single-branch --branch main
}
Comment on lines +30 to 34
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@alzimmermsft We might need to add a regex for the org in the above command.


workingDirectory: $(Pipeline.Workspace)
Expand Down