1
Fork 0
mirror of https://github.com/RGBCube/nu_scripts synced 2025-08-01 22:57:46 +00:00

nu-complete docker containers: show all containers (#778)

- use `!` tag failed containers
- if there are duplicate names, the id comes first.

---------

Co-authored-by: nash <nash@iffy.me>
This commit is contained in:
fj0r 2024-03-08 20:10:46 +08:00 committed by GitHub
parent 8a2dcf6cf8
commit 6d98fee3ba
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 33 additions and 11 deletions

View file

@ -9,7 +9,7 @@ def agree [
} else {
$'($prompt)'
}
( if $default_not { [no yes] } else { [yes no] } | input list $prompt) in [yes]
(if $default_not { [no yes] } else { [yes no] } | input list $prompt) == 'yes'
}
def tips [ msg ] {
@ -117,7 +117,7 @@ export def gb [
}
}
} else if ($branch | is-empty) {
let merged = git branch --merged
let merged = git branch --merged
| lines
| each { $in | parse -r '\s*\*?\s*(?P<b>[^\s]+)' | get 0.b }
{