mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-28 17:20:22 +00:00
Add pwsh PowerShell interpreter (#4073)
* Register pwsh as interpreter for PowerShell * Add pwsh sample * Remove pwsh from Shell section
This commit is contained in:
@@ -3526,6 +3526,8 @@ PowerShell:
|
||||
- ".ps1"
|
||||
- ".psd1"
|
||||
- ".psm1"
|
||||
interpreters:
|
||||
- pwsh
|
||||
language_id: 293
|
||||
Processing:
|
||||
type: programming
|
||||
|
||||
21
samples/PowerShell/pwsh-shebang.ps1
Normal file
21
samples/PowerShell/pwsh-shebang.ps1
Normal file
@@ -0,0 +1,21 @@
|
||||
#!/usr/bin/env pwsh
|
||||
|
||||
# source: https://github.com/PowerShell/PowerShellStandard/blob/3436bfc162d6804dd11d1d76c4faff486b4b405d/build.ps1
|
||||
|
||||
param (
|
||||
[Parameter(ParameterSetName="Clean")][switch]$Clean,
|
||||
[Parameter(ParameterSetName="Test")][switch]$Test
|
||||
)
|
||||
|
||||
import-module $PSScriptRoot/PowerShellStandard.psm1 -force
|
||||
|
||||
if ( $Clean ) {
|
||||
Start-Clean
|
||||
return
|
||||
}
|
||||
|
||||
Start-Build
|
||||
|
||||
if ( $Test ) {
|
||||
Invoke-Test
|
||||
}
|
||||
Reference in New Issue
Block a user