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

refactor git-v2#agree with input list (#496)

Co-authored-by: agent <agent@nuc>
This commit is contained in:
fj0r 2023-05-17 10:05:57 +08:00 committed by GitHub
parent b6ecfe3680
commit 08b7ccf84e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,7 +4,7 @@ def agree [prompt] {
} else {
$'($prompt)'
}
(input $prompt | str downcase) in ['y', 'yes', 'ok', 't', 'true', '1']
([yes no] | input list $prompt) in [yes]
}
# git status and stash