diff options
| author | 魏曹先生 <1992414357@qq.com> | 2025-12-15 10:05:21 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2025-12-15 10:05:21 +0800 |
| commit | 1e43def95472d9c906cff50534b38be2864690f4 (patch) | |
| tree | e7296275d74efb4e1545d657bc936759291b48fe /scripts/completions/powershell/completion_jv.ps1 | |
| parent | b8ac6982f9b81bd686c2c8deb34669e13efd5ba7 (diff) | |
Update help documentation and move command functionality
- Redesign move command to modify upstream mappings with support for
erase operations
- Add erased items support to align command and status display
- Update help text to reflect new move mapping semantics and add erased
item instructions
- Add auto-update timeout configuration via JV_OUTDATED_MINUTES
environment variable
- Improve status display with separate structural and content change
modes
- Add force flag to hold/throw commands to skip pre-checks
- Update completion scripts to include erased items in align command
Diffstat (limited to 'scripts/completions/powershell/completion_jv.ps1')
| -rw-r--r-- | scripts/completions/powershell/completion_jv.ps1 | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/scripts/completions/powershell/completion_jv.ps1 b/scripts/completions/powershell/completion_jv.ps1 index 48ab3ec..b756fbd 100644 --- a/scripts/completions/powershell/completion_jv.ps1 +++ b/scripts/completions/powershell/completion_jv.ps1 @@ -89,7 +89,7 @@ Register-ArgumentCompleter -Native -CommandName jv -ScriptBlock { } "align" { if ($currentIndex -eq 3) { - $alignItems = @("lost", "moved") + $alignItems = @("lost", "moved", "erased") $unsolvedItems = & $cmd sheet align --unsolved --raw 2>$null $completions = $alignItems + $unsolvedItems return $completions | Where-Object { $_ -like "$wordToComplete*" } @@ -104,6 +104,8 @@ Register-ArgumentCompleter -Native -CommandName jv -ScriptBlock { $alignOperations = @("confirm") + $createdItems } elseif ($item -eq "moved" -or $item -like "moved:*") { $alignOperations = @("local", "remote") + } elseif ($item -eq "erased" -or $item -like "erased:*") { + $alignOperations = @("confirm") } else { $alignOperations = @("local", "remote", "confirm") + $createdItems } @@ -118,7 +120,7 @@ Register-ArgumentCompleter -Native -CommandName jv -ScriptBlock { # Completion for align command if ($subcmd -eq "align") { if ($currentIndex -eq 2) { - $alignItems = @("lost", "moved") + $alignItems = @("lost", "moved", "erased") $unsolvedItems = & $cmd sheet align --unsolved --raw 2>$null $completions = $alignItems + $unsolvedItems return $completions | Where-Object { $_ -like "$wordToComplete*" } @@ -133,6 +135,8 @@ Register-ArgumentCompleter -Native -CommandName jv -ScriptBlock { $alignOperations = @("confirm") + $createdItems } elseif ($item -eq "moved" -or $item -like "moved:*") { $alignOperations = @("local", "remote") + } elseif ($item -eq "erased" -or $item -like "erased:*") { + $alignOperations = @("confirm") } else { $alignOperations = @("local", "remote", "confirm") + $createdItems } |
