Skip to content

(MAINT) Update URLs for site rebrand #1844

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Sep 24, 2022

Conversation

sdwheeler
Copy link
Collaborator

PR Summary

The docs site has been rebranded. The URL changed from docs.microsoft.com to learn.microsoft.com. URLs pointing to docs.microsoft.com are redirected but the need to be updated to avoid the redirection.

This PR updates the URLs to point to the new hostname.

PR Checklist

@sdwheeler sdwheeler changed the title Update URLs for site rebrand (MAINT) Update URLs for site rebrand Sep 20, 2022
Copy link
Collaborator

@bergmeister bergmeister left a comment

Choose a reason for hiding this comment

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

Can you link to the Microsoft docs PR with the same change in PSSA please or create one, otherwise looks good

@sdwheeler
Copy link
Collaborator Author

See related PR MicrosoftDocs/PowerShell-Docs-Modules#103

Copy link
Contributor

@JamesWTruher JamesWTruher left a comment

Choose a reason for hiding this comment

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

will the old URL eventually be decommissioned?

@bergmeister
Copy link
Collaborator

See related PR MicrosoftDocs/PowerShell-Docs-Modules#103

I do not see the same changes to the markdown files in the Rules folder that are in this PR.

@sdwheeler
Copy link
Collaborator Author

I do not see the same changes to the markdown files in the Rules folder that are in this PR.

That's because the Docs repo uses site-relative links that omit the hostname portion of the URL. We can switch to site-relative links in the source code repo but that means that the URLs don't work when viewed from GitHub. Are there Pester tests for links? If not then it would be safe to switch to site-relative links in the source and make publishing the docs easier at release time.

@sdwheeler
Copy link
Collaborator Author

I just pushed a new commit to restore full URLs in the source files that had been converted to site-relative.

I remember now from discussions with Jim, we want to use full URLs in the source because the source docs for a tagged release need to have working URLs. We need to convert them links to site-relative when the files are copied to the docs repository.

- [Create XML-based help using PlatyPS](https://docs.microsoft.com/powershell/scripting/dev-cross-plat/create-help-using-platyps)
- [Writing Comment-based Help](https://learn.microsoft.com/powershell/scripting/developer/help/writing-comment-based-help-topics)
- [Writing Help for PowerShell Cmdlets](https://learn.microsoft.com/powershell/scripting/developer/help/writing-help-for-windows-powershell-cmdlets)
- [Create XML-based help using PlatyPS](https://learn.microsoft.com/powershell/utility-modules/platyps/create-help-using-platyps)
Copy link
Collaborator

@bergmeister bergmeister Sep 22, 2022

Choose a reason for hiding this comment

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

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The current URL redirects to the correct location. The new URL will come over when 1.21 is released. So the change to docs can wait for the release.

Copy link
Collaborator

Choose a reason for hiding this comment

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

release of platyps? This is getting too complicated! Can we not just have a clean PR in PSSA please that replicates what your other linked PR does, which is just changing the URL to learn.microsoft.com? And anything else that is still needed but has a different timeline in a separate PR?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

As far as I can tell this PR is clean. Sorry, you misunderstood which release I am talking about. I was talking about the 1.21 of PSSA. The link to the PlatyPS article in the docs repo will redirect so it doesn't need to change right now. But I can change it if you feel strongly. My point is that the change in this PR will get copied to the docs repo when PSSA 1.21 releases.

Copy link
Collaborator

@bergmeister bergmeister Sep 22, 2022

Choose a reason for hiding this comment

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

ok, gotcha, that means we have to copy this file, the shouldprocess doc and the cmdlet docs: MicrosoftDocs/PowerShell-Docs-Modules#99

@bergmeister bergmeister merged commit e923e16 into PowerShell:master Sep 24, 2022
@bergmeister
Copy link
Collaborator

bergmeister commented Sep 24, 2022

@sdwheeler When I updated my other MSDocs PR with this, I found that the below change was not synced back to PSSA repo: MicrosoftDocs/PowerShell-Docs-Modules@747cff5#diff-7f36cb7cb779ee3d32ec0749bba06c5a5fbd5398106c748acf80fee400ce7115

bergmeister added a commit to bergmeister/PowerShell-Docs-Modules that referenced this pull request Sep 24, 2022
michaeltlombardi pushed a commit to MicrosoftDocs/PowerShell-Docs-Modules that referenced this pull request Sep 30, 2022
* PSSA 1.21.0 docs changes from PSSA repo

* Revert changes with absolute to relative link as those links are different between PSSA vs MicrosoftDocs

* Update reference/docs-conceptual/PSScriptAnalyzer/Rules/AvoidSemicolonsAsLineTerminators.md

* Update version in TOC

* Update with changes from PowerShell/PSScriptAnalyzer#1844

* Update AvoidUsingPositionalParameters docs from last PR

Co-authored-by: Sean Wheeler <[email protected]>
@sdwheeler sdwheeler deleted the sdw-6855-rebrand branch December 7, 2022 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants