
+ Get-GitRepo - Clone or update a repo, with tag support + Get-GitHubReleaseTag - Grab tag from latest release page + Refresh-GitRepo - Stage all possible changes, discarding any previously stageds changes = GitHub repo is now git repo - as some code isn't GitHub specific + cat Alias for Get-Content = Get-PossiblArguments improvement = Invoke-WebDownload fix = dcedit fixing bad argument processing
21 lines
569 B
PowerShell
21 lines
569 B
PowerShell
[CmdletBinding()]param(
|
|
[string]$WordToComplete,
|
|
[string[]]$FullValueSet,
|
|
[switch]$Strict
|
|
)
|
|
$local:possibleValues = $fullValueSet
|
|
if( $wordToComplete ) {
|
|
$possibleValues = $possibleValues |
|
|
Where-Object { $_ -match $wordToComplete } |
|
|
ForEach-Object {
|
|
if( $_ -match ' ' ) {
|
|
"'$_'"
|
|
} else {
|
|
$_
|
|
}
|
|
}
|
|
if( -not $strict -and ($wordToComplete -notin $possibleValues) ) {
|
|
$possibleValues = $( $wordToComplete; $possibleValues )
|
|
}
|
|
}
|
|
return $possibleValues
|