Update manpages and auto-completion

This commit is contained in:
Alexander Neumann 2024-07-26 11:30:37 +02:00
parent 905da91e61
commit 65748fcd6b
37 changed files with 1555 additions and 103 deletions

View file

@ -10,7 +10,7 @@ filter __restic_escapeStringWithSpecialChars {
$_ -replace '\s|#|@|\$|;|,|''|\{|\}|\(|\)|"|`|\||<|>|&','`$&'
}
[scriptblock]$__resticCompleterBlock = {
[scriptblock]${__resticCompleterBlock} = {
param(
$WordToComplete,
$CommandAst,
@ -85,7 +85,7 @@ filter __restic_escapeStringWithSpecialChars {
__restic_debug "Calling $RequestComp"
# First disable ActiveHelp which is not supported for Powershell
$env:RESTIC_ACTIVE_HELP=0
${env:RESTIC_ACTIVE_HELP}=0
#call the command store the output in $out and redirect stderr and stdout to null
# $Out is an array contains each line per element
@ -242,4 +242,4 @@ filter __restic_escapeStringWithSpecialChars {
}
}
Register-ArgumentCompleter -CommandName 'restic' -ScriptBlock $__resticCompleterBlock
Register-ArgumentCompleter -CommandName 'restic' -ScriptBlock ${__resticCompleterBlock}