From 1bd6af41bd0ff7c94c71b0280fb2ce000c554b59 Mon Sep 17 00:00:00 2001 From: Sean Wheeler Date: Thu, 12 Dec 2024 11:49:54 -0600 Subject: [PATCH] Fix broken links --- .../AIShell/developer/create-ollama-agent.md | 6 ++--- .../Rules/AvoidOverwritingBuiltInCmdlets.md | 23 ++++++++++-------- .../Rules/UseCompatibleCmdlets.md | 17 +++++++------ .../Rules/UseCompatibleCommands.md | 6 ++--- .../Rules/UseCompatibleTypes.md | 6 ++--- .../PlatyPS/create-help-using-platyps.md | 4 ++-- .../Get-ScriptAnalyzerRule.md | 4 ++-- .../ps-modules/PlatyPS/New-ExternalHelp.md | 24 +++++++++---------- 8 files changed, 48 insertions(+), 42 deletions(-) diff --git a/reference/docs-conceptual/AIShell/developer/create-ollama-agent.md b/reference/docs-conceptual/AIShell/developer/create-ollama-agent.md index 8395f73..624676f 100644 --- a/reference/docs-conceptual/AIShell/developer/create-ollama-agent.md +++ b/reference/docs-conceptual/AIShell/developer/create-ollama-agent.md @@ -1,7 +1,7 @@ --- title: How to create an agent for Ollama description: Learn how to create an agent for the Ollama language model in AI Shell. -ms.date: 11/18/2024 +ms.date: 12/12/2024 ms.topic: how-to --- @@ -497,6 +497,6 @@ in the `agents` folder of the base directory of `aish.exe`, the agent will be lo [01]: https://github.com/ollama/ollama [02]: https://github.com/ollama/ollama/blob/main/docs/api.md#request-no-streaming [03]: https://github.com/PowerShell/ProjectMercury/discussions/categories/agent-sharing -[04]: https://github.com/PowerShell/ProjectMercury/shell/agents/AIShell.Ollama.Agent -[05]: https://github.com/PowerShell/ProjectMercury/shell/README.md +[04]: https://github.com/PowerShell/AIShell/tree/main/shell/agents/AIShell.Ollama.Agent +[05]: https://github.com/PowerShell/AIShell/blob/main/shell/README.md [06]: https://www.nuget.org/packages/AIShell.Abstraction/1.0.0-preview.1 diff --git a/reference/docs-conceptual/PSScriptAnalyzer/Rules/AvoidOverwritingBuiltInCmdlets.md b/reference/docs-conceptual/PSScriptAnalyzer/Rules/AvoidOverwritingBuiltInCmdlets.md index 1d94a61..10e1ad3 100644 --- a/reference/docs-conceptual/PSScriptAnalyzer/Rules/AvoidOverwritingBuiltInCmdlets.md +++ b/reference/docs-conceptual/PSScriptAnalyzer/Rules/AvoidOverwritingBuiltInCmdlets.md @@ -1,6 +1,6 @@ --- description: Avoid overwriting built in cmdlets -ms.date: 06/28/2023 +ms.date: 12/12/2024 ms.topic: reference title: AvoidOverwritingBuiltInCmdlets --- @@ -14,7 +14,7 @@ This rule flags cmdlets that are available in a given edition/version of PowerSh operating system which are overwritten by a function declaration. It works by comparing function declarations against a set of allowlists that ship with PSScriptAnalyzer. These allowlist files are used by other PSScriptAnalyzer rules. More information can be found in the documentation for the -[UseCompatibleCmdlets](./UseCompatibleCmdlets.md) rule. +[UseCompatibleCmdlets][01] rule. ## Configuration @@ -37,14 +37,17 @@ following your settings file. The parameter `PowerShellVersion` is a list of allowlists that ship with PSScriptAnalyzer. -**Note**: The default value for `PowerShellVersion` is `core-6.1.0-windows` if PowerShell 6 or -later is installed, and `desktop-5.1.14393.206-windows` if it is not. +> [!NOTE] +> The default value for `PowerShellVersion` is `core-6.1.0-windows` if PowerShell 6 or +> later is installed, and `desktop-5.1.14393.206-windows` if it's not. Usually, patched versions of PowerShell have the same cmdlet data, therefore only settings of major and minor versions of PowerShell are supplied. One can also create a custom settings file as well -with the -[New-CommandDataFile.ps1](https://github.com/PowerShell/PSScriptAnalyzer/blob/development/Utils/New-CommandDataFile.ps1) -script and use it by placing the created `JSON` into the `Settings` folder of the `PSScriptAnalyzer` -module installation folder, then the `PowerShellVersion` parameter is just its file name (that can -also be changed if desired). Note that the `core-6.0.2-*` files were removed in PSScriptAnalyzer -1.18 since PowerShell 6.0 reached end of life. +with the [New-CommandDataFile.ps1][02] script and use it by placing the created `JSON` into the +`Settings` folder of the `PSScriptAnalyzer` module installation folder, then the `PowerShellVersion` +parameter is just its filename (that can also be changed if desired). Note that the `core-6.0.2-*` +files were removed in PSScriptAnalyzer 1.18 since PowerShell 6.0 reached end of life. + + +[01]: ./UseCompatibleCmdlets.md +[02]: https://github.com/PowerShell/PSScriptAnalyzer/blob/main/Utils/New-CommandDataFile.ps1 diff --git a/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleCmdlets.md b/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleCmdlets.md index 1fc9520..4cd5234 100644 --- a/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleCmdlets.md +++ b/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleCmdlets.md @@ -1,6 +1,6 @@ --- description: Use compatible cmdlets -ms.date: 06/28/2023 +ms.date: 12/12/2024 ms.topic: reference title: UseCompatibleCmdlets --- @@ -10,8 +10,8 @@ title: UseCompatibleCmdlets ## Description -This rule flags cmdlets that are not available in a given Edition/Version of PowerShell on a given -Operating System. It works by comparing a cmdlet against a set of allowlists which ship with +This rule flags cmdlets that aren't available in a given Edition and Version of PowerShell on a +given Operating System. It works by comparing a cmdlet against a set of allowlists which ship with PSScriptAnalyzer. They can be found at `/path/to/PSScriptAnalyzerModule/Settings`. These files are of the form, `--.json` where `` can be either `Core` or `Desktop`, `` can be either `Windows`, `Linux` or `MacOS`, and `` is the PowerShell @@ -41,7 +41,10 @@ The parameter `compatibility` is a list that contain any of the following Usually, patched versions of PowerShell have the same cmdlet data, therefore only settings of major and minor versions of PowerShell are supplied. You can also create a custom settings file with the -[New-CommandDataFile.ps1](https://github.com/PowerShell/PSScriptAnalyzer/blob/development/Utils/New-CommandDataFile.ps1) -script. Place the created `.json` file in the `Settings` folder of the `PSScriptAnalyzer` module -folder. Then the `compatibility` parameter values is just the filename. Note that the `core-6.0.2-*` -files were removed in PSScriptAnalyzer 1.18 since PowerShell 6.0 reached it's end of life. +[New-CommandDataFile.ps1][01] script. Place the created `.json` file in the `Settings` folder of the +`PSScriptAnalyzer` module folder. Then the `compatibility` parameter values is just the filename. +Note that the `core-6.0.2-*` files were removed in PSScriptAnalyzer 1.18 since PowerShell 6.0 +reached it's end of life. + + +[01]: https://github.com/PowerShell/PSScriptAnalyzer/blob/main/Utils/New-CommandDataFile.ps1 diff --git a/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleCommands.md b/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleCommands.md index 7857bdf..ae74862 100644 --- a/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleCommands.md +++ b/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleCommands.md @@ -1,6 +1,6 @@ --- description: Use compatible commands -ms.date: 10/10/2024 +ms.date: 12/12/2024 ms.topic: reference title: UseCompatibleCommands --- @@ -141,5 +141,5 @@ And also suppressed only for parameters: ``` -[01]: https://github.com/PowerShell/PSScriptAnalyzer/tree/development/PSCompatibilityCollector -[02]: https://github.com/PowerShell/PSScriptAnalyzer/tree/development/PSCompatibilityCollector/optional_profiles +[01]: https://github.com/PowerShell/PSScriptAnalyzer/tree/main/PSCompatibilityCollector +[02]: https://github.com/PowerShell/PSScriptAnalyzer/tree/main/PSCompatibilityCollector/optional_profiles diff --git a/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleTypes.md b/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleTypes.md index 99243e5..9bff5fa 100644 --- a/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleTypes.md +++ b/reference/docs-conceptual/PSScriptAnalyzer/Rules/UseCompatibleTypes.md @@ -1,6 +1,6 @@ --- description: Use compatible types -ms.date: 10/10/2024 +ms.date: 12/12/2024 ms.topic: reference title: UseCompatibleTypes --- @@ -161,5 +161,5 @@ And also suppressed only for type members: ``` -[01]: https://github.com/PowerShell/PSScriptAnalyzer/tree/development/PSCompatibilityCollector -[02]: https://github.com/PowerShell/PSScriptAnalyzer/tree/development/PSCompatibilityCollector/optional_profiles +[01]: https://github.com/PowerShell/PSScriptAnalyzer/tree/main/PSCompatibilityCollector +[02]: https://github.com/PowerShell/PSScriptAnalyzer/tree/main/PSCompatibilityCollector/optional_profiles diff --git a/reference/docs-conceptual/PlatyPS/create-help-using-platyps.md b/reference/docs-conceptual/PlatyPS/create-help-using-platyps.md index 7ad914e..f60f7e6 100644 --- a/reference/docs-conceptual/PlatyPS/create-help-using-platyps.md +++ b/reference/docs-conceptual/PlatyPS/create-help-using-platyps.md @@ -1,6 +1,6 @@ --- description: Using PlatyPS is the fast and efficient way to create XML-based help. -ms.date: 05/21/2024 +ms.date: 12/12/2024 title: Create XML-based help using PlatyPS --- # Create XML-based help using PlatyPS @@ -306,6 +306,6 @@ the [PowerShell style guide][11] and [Editing reference articles][10]. [14]: #creating-an-updateable-help-package [15]: https://commonmark.org [16]: https://github.com/PowerShell/platyps -[17]: https://github.com/PowerShell/platyPS/blob/master/platyPS.schema.md +[17]: https://github.com/PowerShell/platyPS/blob/master/docs/developer/platyPS/platyPS.schema.md [18]: https://pandoc.org [19]: https://www.powershellgallery.com/packages/platyPS/ diff --git a/reference/ps-modules/PSScriptAnalyzer/Get-ScriptAnalyzerRule.md b/reference/ps-modules/PSScriptAnalyzer/Get-ScriptAnalyzerRule.md index a86d7d3..3d815b2 100644 --- a/reference/ps-modules/PSScriptAnalyzer/Get-ScriptAnalyzerRule.md +++ b/reference/ps-modules/PSScriptAnalyzer/Get-ScriptAnalyzerRule.md @@ -1,7 +1,7 @@ --- external help file: Microsoft.Windows.PowerShell.ScriptAnalyzer.dll-Help.xml Module Name: PSScriptAnalyzer -ms.date: 10/07/2021 +ms.date: 12/12/2024 online version: https://learn.microsoft.com/powershell/module/psscriptanalyzer/get-scriptanalyzerrule?view=ps-modules&wt.mc_id=ps-gethelp schema: 2.0.0 --- @@ -92,7 +92,7 @@ one value, but wildcards are supported. To get rules in subdirectories of the pa **RecurseCustomRulePath** parameter. You can create custom rules using a .NET assembly or a PowerShell module, such as the -[Community Analyzer Rules](https://github.com/PowerShell/PSScriptAnalyzer/blob/development/Tests/Engine/CommunityAnalyzerRules/CommunityAnalyzerRules.psm1) +[Community Analyzer Rules](https://github.com/PowerShell/PSScriptAnalyzer/tree/main/Tests/Engine/CommunityAnalyzerRules) in the GitHub repository. ```yaml diff --git a/reference/ps-modules/PlatyPS/New-ExternalHelp.md b/reference/ps-modules/PlatyPS/New-ExternalHelp.md index 002bf88..4e1b10f 100644 --- a/reference/ps-modules/PlatyPS/New-ExternalHelp.md +++ b/reference/ps-modules/PlatyPS/New-ExternalHelp.md @@ -1,7 +1,7 @@ --- external help file: platyPS-help.xml Module Name: platyPS -ms.date: 03/16/2021 +ms.date: 12/12/2024 online version: https://learn.microsoft.com/powershell/module/platyps/new-externalhelp?view=ps-modules&wt.mc_id=ps-gethelp schema: 2.0.0 --- @@ -24,8 +24,8 @@ The `New-ExternalHelp` cmdlet creates an external help file based on markdown he by PlatyPS. You can ship this with a module to provide help using the `Get-Help` cmdlet. If the markdown files that you specify don't follow the PlatyPS -[Schema](https://github.com/PowerShell/platyPS/blob/master/platyPS.schema.md), this cmdlet returns -error messages. +[Schema](https://github.com/PowerShell/platyPS/blob/master/docs/developer/platyPS/platyPS.schema.md), +this cmdlet returns error messages. ## EXAMPLES @@ -42,8 +42,8 @@ Mode LastWriteTime Length Name -a---- 5/19/2016 12:32 PM 46776 platyPS-help.xml ``` -This command creates an external help file in the specified location. -This command uses the best practice that the folder name includes the locale. +This command creates an external help file in the specified location. This command uses the best +practice that the foldername includes the locale. ### Example 2: Create help that uses custom encoding @@ -77,15 +77,15 @@ Mode LastWriteTime Length Name ``` This command creates an external help file in the specified location. This command uses the best -practice that the folder name includes the locale. This command writes the warnings and errors to -the WarningsAndErrors.json file. +practice that the foldername includes the locale. This command writes the warnings and errors to the +`WarningsAndErrors.json` file. ## PARAMETERS ### -OutputPath -Specifies the path of a folder where this cmdlet saves your external help file. -The folder name should end with a locale folder, as in the following example: `.\out\PlatyPS\en-US\`. +Specifies the path of a folder where this cmdlet saves your external help file. The folder name +should end with a locale folder, as in the following example: `.\out\PlatyPS\en-US\`. ```yaml Type: String @@ -192,9 +192,9 @@ Accept wildcard characters: False ### -ErrorLogFile -The path where this cmdlet will save formatted results log file. +The path where this cmdlet saves formatted results log file. -The path must include the location and name of the folder and file name with the json extension. The +The path must include the location and name of the folder and filename with the json extension. The JSON object contains three properties: **Message**, **FilePath**, and **Severity** (Warning or Error). @@ -255,4 +255,4 @@ This cmdlet returns a `FileInfo[]` object for created files. [PowerShell V2 External MAML Help](https://devblogs.microsoft.com/powershell/powershell-v2-external-maml-help/) -[Schema](https://github.com/PowerShell/platyPS/blob/master/platyPS.schema.md) +[Schema](https://github.com/PowerShell/platyPS/blob/master/docs/developer/platyPS/platyPS.schema.md)