Skip to content
This repository was archived by the owner on Dec 8, 2021. It is now read-only.

Commit f95aad7

Browse files
TylerLeonhardtTiberriver256
authored andcommitted
Headings and doc updates (#157)
* move around comments * add headers to everything * fix parameters * update docs
1 parent eb48b72 commit f95aad7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+323
-80
lines changed

PSScriptAnalyzerSettings.psd1

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
16
@{
27
Rules = @{
38
PSAvoidUsingCmdletAliases = @{

Polaris.psm1

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
1-
$Script:Polaris = $null
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
6+
$Script:Polaris = $null
27

38
# Handles the removal of the module
49
$ExecutionContext.SessionState.Module.OnRemove =

Private/Create-NewPolarisIfNeeded.ps1

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
16
function CreateNewPolarisIfNeeded () {
27
if ( -not $Script:Polaris ) {
38
$Script:Polaris = [Polaris]::New(

Public/Clear-Polaris.ps1

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,17 @@
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
16
<#
27
.SYNOPSIS
3-
Clears the internal instance of Polaris
8+
Clears the internal instance of Polaris
49
.DESCRIPTION
5-
Clears the internal Polaris .NET Standard object. The instance will be reinstantiated in other module calls.
10+
Clears the internal Polaris .NET Standard object. The instance will be reinstantiated in other module calls.
611
.EXAMPLE
7-
Clear-Polaris
12+
Clear-Polaris
813
.NOTES
9-
Should only be used for testing
14+
Should only be used for testing
1015
#>
1116
function Clear-Polaris {
1217
if ($Script:Polaris) {

Public/Get-Polaris.ps1

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,18 @@
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
16
<#
27
.SYNOPSIS
3-
Returns the internal instance of Polaris
8+
Returns the internal instance of Polaris
49
.DESCRIPTION
5-
Returns the instance of the Polaris .NET Standard object
10+
Returns the instance of the Polaris .NET Standard object
611
.EXAMPLE
7-
Get-Polaris
12+
Get-Polaris
813
.NOTES
9-
Should only be used for testing
14+
Should only be used for testing
1015
#>
1116
function Get-Polaris {
1217
return $Script:Polaris
1318
}
14-

Public/Get-PolarisRoute.ps1

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
16
<#
27
.SYNOPSIS
38
Get web routes.

Public/Get-PolarisRouteMiddleware.ps1

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
16
<#
27
.SYNOPSIS
38
Get route middleware.

Public/New-DirectoryBrowser.ps1

Lines changed: 22 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,26 @@
1-
function New-DirectoryBrowser {
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
25

3-
<#
4-
.SYNOPSIS
5-
Renders a directory browser in HTML
6-
.DESCRIPTION
7-
Creates HTML that can be used as a directory browser
8-
.PARAMETER RequestedItem
9-
The directory you would like to generate HTML for
10-
.PARAMETER HeaderName
11-
The name you would like displayed at the top of the directory browser
12-
.PARAMETER DirectoryBrowserPath
13-
The current path in the directory browser relative to the root of the directory
14-
browser (not the root of the site).
6+
<#
7+
.SYNOPSIS
8+
Renders a directory browser in HTML
9+
.DESCRIPTION
10+
Creates HTML that can be used as a directory browser
11+
.PARAMETER RequestedItem
12+
The directory you would like to generate HTML for
13+
.PARAMETER HeaderName
14+
The name you would like displayed at the top of the directory browser
15+
.PARAMETER DirectoryBrowserPath
16+
The current path in the directory browser relative to the root of the directory
17+
browser (not the root of the site).
18+
.EXAMPLE
19+
New-DirectoryBrowser -RequestedItem $directoryInfo
20+
.EXAMPLE
21+
New-DirectoryBrowser -RequestedItem $directoryInfo -DirectoryBrowserPath ./MyContent
1522
#>
16-
23+
function New-DirectoryBrowser {
1724
param (
1825

1926
[Parameter(
@@ -63,4 +70,4 @@ $(if ($RequestedItem.FullName.TrimEnd([System.IO.Path]::DirectorySeparatorChar)
6370
</body>
6471
</html>
6572
"@
66-
}
73+
}

Public/New-PolarisDeleteRoute.ps1

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
16
<#
27
.SYNOPSIS
38
Add web route with method DELETE

Public/New-PolarisGetRoute.ps1

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright (c) Microsoft. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
16
<#
27
.SYNOPSIS
38
Add web route with method GET
@@ -52,4 +57,3 @@ function New-PolarisGetRoute {
5257
'ScriptPath' { New-PolarisRoute -Path $Path -Method "GET" -ScriptPath $ScriptPath -Force:$Force }
5358
}
5459
}
55-

0 commit comments

Comments
 (0)