We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Keychain behaves strangely when encountering a null argument.
Here, $noask is null:
$noask
% printf "%q\n" "$noask" '' % printf "%q\n" "$keys" id_4096_jvlk.me$'\n'id_4096rsa_20kdf$'\n'id_android$'\n'id_boxy_rsa %
% keychain --quiet -k all; eval $(keychain --eval --confhost --quick "$noask" "$keys") * keychain 2.8.5 ~ http://www.funtoo.org * Starting ssh-agent... %
The exact command, but with $noask not surrounded by "s:
"
% keychain --quiet -k all; eval $(keychain --eval --confhost --quick $noask "$keys") * keychain 2.8.5 ~ http://www.funtoo.org * Starting ssh-agent... * Adding 4 ssh key(s): /home/ravi/.ssh/id_4096_jvlk.me /home/ravi/.ssh/id_4096rsa_20kdf /home/ravi/.ssh/id_android /home/ravi/.ssh/id_boxy_rsa Enter passphrase for /home/ravi/.ssh/id_4096_jvlk.me: * ssh-add: Identities added: /home/ravi/.ssh/id_4096_jvlk.me /home/ravi/.ssh/id_4096rsa_20kdf /home/ravi/.ssh/id_android /home/ravi/.ssh/id_boxy_rsa %
This is the context for why I want to do this:
function keychain_load { noask=''; [[ ! -t 0 || ! -t 1 ]] && noask='--noask' # Don't ask for password if either STDIN or STDOUT is !isatty eval $(keychain --eval --quiet --agents ssh --inherit local-once --absolute --dir "$XDG_CACHE_HOME"/keychain --confhost --quick $noask "$keys") } export_function keychain_load
The text was updated successfully, but these errors were encountered:
Strangely, it breaks when the null argument given before the keys are listed, so this works fine:
% keychain --quiet -k all; eval $(keychain --eval --confhost --quick "$keys" "$noask" ) * keychain 2.8.5 ~ http://www.funtoo.org * Starting ssh-agent... * Adding 4 ssh key(s): /home/ravi/.ssh/id_4096_jvlk.me /home/ravi/.ssh/id_4096rsa_20kdf /home/ravi/.ssh/id_android /home/ravi/.ssh/id_boxy_rsa Enter passphrase for /home/ravi/.ssh/id_4096_jvlk.me: ^C %
Sorry, something went wrong.
hello @HaleTom - if you'd like to report a bug kindly use https://bugs.funtoo.org/
you can also reach us on Discord - for more info check https://www.funtoo.org/Welcome
No branches or pull requests
Keychain behaves strangely when encountering a null argument.
Here,
$noask
is null:The exact command, but with
$noask
not surrounded by"
s:This is the context for why I want to do this:
The text was updated successfully, but these errors were encountered: