Skip to content
Merged
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
10 changes: 10 additions & 0 deletions .github/PSModule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,13 @@ Test:
# Build:
# Docs:
# Skip: true

Linter:
env:
VALIDATE_BIOME_FORMAT: false
VALIDATE_BIOME_LINT: false
VALIDATE_GITHUB_ACTIONS_ZIZMOR: false
VALIDATE_JSCPD: false
VALIDATE_JSON_PRETTIER: false
VALIDATE_MARKDOWN_PRETTIER: false
Comment thread
MariusStorhaug marked this conversation as resolved.
VALIDATE_YAML_PRETTIER: false
17 changes: 9 additions & 8 deletions .github/linters/.markdown-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,19 @@
###############
# Rules by id #
###############
MD004: false # Unordered list style
MD004: false # Unordered list style
MD007:
indent: 2 # Unordered list indentation
indent: 2 # Unordered list indentation
MD013:
line_length: 808 # Line length
line_length: 808 # Line length
MD024: false # no-duplicate-heading, INPUTS and OUTPUTS _can_ be the same item
MD026:
punctuation: ".,;:!。,;:" # List of not allowed
MD029: false # Ordered list item prefix
MD033: false # Allow inline HTML
MD036: false # Emphasis used instead of a heading
punctuation: '.,;:!。,;:' # List of not allowed
Comment thread
MariusStorhaug marked this conversation as resolved.
MD029: false # Ordered list item prefix
MD033: false # Allow inline HTML
MD036: false # Emphasis used instead of a heading

#################
# Rules by tags #
#################
blank_lines: false # Error on blank lines
blank_lines: false # Error on blank lines
2 changes: 2 additions & 0 deletions src/functions/public/ConvertTo-UriQueryString.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@
is an array, multiple entries for the same key are generated.

.EXAMPLE
```pwsh
Comment thread
MariusStorhaug marked this conversation as resolved.
ConvertTo-UriQueryString -Query @{ foo = 'bar'; search = 'hello world'; ids = 1,2,3 }
```

Output:
```powershell
Expand Down
6 changes: 6 additions & 0 deletions src/functions/public/Get-Uri.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
format parameters.

Comment thread
MariusStorhaug marked this conversation as resolved.
.EXAMPLE
```pwsh
Get-Uri -Uri 'example.com'
```

Output:
```powershell
Expand Down Expand Up @@ -42,7 +44,9 @@
Converts 'example.com' into a normalized absolute URI string.

.EXAMPLE
```pwsh
Get-Uri -Uri 'https://example.com/path' -AsUriBuilder
```

Output:
```powershell
Expand All @@ -60,7 +64,9 @@
Returns a [System.UriBuilder] object for the specified URI.

.EXAMPLE
```pwsh
'example.com/path' | Get-Uri -AsString
```

Output:
```powershell
Expand Down
9 changes: 6 additions & 3 deletions src/functions/public/New-Uri.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@
fragment identifiers. By default, returns a `[System.Uri]` object.

Comment thread
MariusStorhaug marked this conversation as resolved.
.EXAMPLE
# Simple usage with base and path
```pwsh
New-Uri -BaseUri 'https://example.com' -Path 'products/item'
```

Output:
```powershell
Expand Down Expand Up @@ -42,8 +43,9 @@
Constructs a URI with the given base and path.

.EXAMPLE
# Adding query parameters via hashtable
```pwsh
New-Uri 'https://example.com/api' -Path 'search' -Query @{ q = 'test search'; page = @(2, 4) } -AsUriBuilder
```

Output:
```powershell
Expand All @@ -61,8 +63,9 @@
Adds query parameters to the URI, automatically encoding values.

.EXAMPLE
# Merging with existing query and using -MergeQueryParameter
```pwsh
New-Uri 'https://example.com/data?year=2023' -Query @{ year = 2024; sort = 'asc' } -MergeQueryParameters -AsString
```

Output:
```powershell
Expand Down
6 changes: 6 additions & 0 deletions src/functions/public/Test-Uri.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
If the `-AllowRelative` switch is specified, it allows both absolute and relative URIs.

Comment thread
MariusStorhaug marked this conversation as resolved.
.EXAMPLE
```pwsh
Test-Uri -Uri "https://example.com"
```

Output:
```powershell
Expand All @@ -18,7 +20,9 @@
Checks if `https://example.com` is a valid URI, returning `$true`.

.EXAMPLE
```pwsh
Test-Uri -Uri "invalid-uri"
```

Output:
```powershell
Expand All @@ -28,7 +32,9 @@
Returns `$false` for an invalid URI string.

.EXAMPLE
```pwsh
"https://example.com", "invalid-uri" | Test-Uri
```

Output:
```powershell
Expand Down
Loading