🕵️♂️
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[net.httpstatuscode]404 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$top50 = $community ` | |
| Sort-Object { [int]$_.AdditionalMetadata.downloadCount } -Descending ` | |
| Select-Object Name, @{N = "Downloads"; E = { $_.AdditionalMetadata.downloadCount } } -First 50 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Update-FormatData -AppendPath 'C:\ProjectName.Format.ps1xml' | |
# Format files (.ps1xml) to be loaded when importing this module | |
FormatsToProcess = @( | |
'ProjectName.Format.ps1xml' | |
) | |
$item.PSObject.TypeNames.Insert(0, 'The.Name.Here') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get Random Stuff | |
-join (33..126 | %{ [char]$_ } | Get-Random -Count 16) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSAvoidUsingCmdletAliases", "", Justification = "Invoke-Build is alias only")] | |
param () |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Place your key bindings in this file to override the defaults | |
[ | |
{ | |
"key": "ctrl+shift+c", | |
"command": "PowerShell.ShowAdditionalCommands", | |
"when": "editorLangId == 'powershell'" | |
}, | |
{ | |
"key": "ctrl+shift+l", | |
"command": "shellLauncher.launch" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$Host.PrivateData | |
$host.PrivateData.ErrorForegroundColor = [System.ConsoleColor]::Magenta |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
(## EXAMPLE [^`]*)(```\r\n)([^`]*)(```\r\n)(\r\n)([^#]*)(\r\n\r\n)+([^#]+)(#) | |
(## EXAMPLE [^`]+?```\r\n[^`\r\n]+?\r\n)(```\r\n\r\n)([^#]+?\r\n)(\r\n) | |
(## EXAMPLE [^`]+?```\r\n[^`\r\n]+?\r\n)(```\r\n\r\n)([^#]+?\r\n)(\r\n)([^#]+)(#) | |
#> | |
New-MarkdownHelp -Module MyModuleToDocument -OutputFolder $OutputDir -Force | |
$OutputDir | Get-ChildItem -File | ForEach-Object { | |
# fix formatting in multiline examples |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$content = Get-Content 'Get-TelegramStickerPackInfo.Tests.ps1' | |
$Utf8NoBomEncoding = New-Object System.Text.UTF8Encoding $true | |
$path = [System.Environment]::CurrentDirectory = (Get-Location).Path | |
$MyPath = "$path\Get-TelegramStickerPackInfo.Tests.ps1" | |
[System.IO.File]::WriteAllLines($MyPath, $content, $Utf8NoBomEncoding) | |
$content = Get-Content 'Send-TelegramSticker.Tests.ps1' | |
$Utf8NoBomEncoding = New-Object System.Text.UTF8Encoding $true | |
$path = [System.Environment]::CurrentDirectory = (Get-Location).Path |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
// editor | |
"editor.quickSuggestionsDelay": 1, | |
"editor.tabCompletion": "on", | |
"files.defaultLanguage": "powershell", | |
// powershell settings changes | |
// you can specify a custom location for the powershell.exe/pwsh.exe file | |
// not required if you just want to use the default locations |