You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
1Password released a v2.x of their CLI, and introduced breaking changes in the commands, for instance now the commands are something like:
op item list --categories login --tags SSHKeys
instead of what currently ssh-manager is expecting:
op list items --categories login --tags SSHKeys
Below the error when trying to run ssh-manager list
❯ ssh-manager list --provider op
Error: 'op list': Execution failed: exit status 1: [ERROR] 2022/05/27 17:08:39 unknown command "list" for "op"
Usage: op [command] [flags]
Management Commands:
account Manage your locally configured 1Password accounts
connect Manage Connect instances and Connect tokens in your 1Password account
document Perform CRUD operations on Document items in your vaults
events-api Manage Events API integrations in your 1Password account
group Perform CRUD operations on the groups of users in your 1Password account
item Perform CRUD operations on the 1Password items in your vaults
user Manage users within this 1Password account
vault Manage permissions and perform CRUD operations on your 1Password vaults
Commands:
completion Generate shell completion information
inject Inject secrets into a config file
read Read a secret using the secrets reference syntax
run Pass secrets as environment variables to a process
signin Sign in to a 1Password account
signout Sign out of a 1Password account
update Check for and download updates.
Global Flags:
--account account Select the account to execute the command by account shorthand, sign-in address, account ID, or user ID. For a list
of available accounts, run 'op account list'. Can be set as the OP_ACCOUNT environment variable.
--cache Store and use cached information.
--config directory Use this configuration directory.
--debug Output debug logs. Can also be set using $OP_DEBUG environment variable.
--encoding type Use this character encoding type. Default: UTF-8. Supported: SHIFT_JIS, gbk.
--format string Use this output format. Can be 'human-readable' or 'json'. Can be set as the OP_FORMAT environment variable.
(default "human-readable")
-h, --help Get help for op.
--iso-timestamps Format timestamps according to ISO 8601 / RFC 3339. Can be set as the OP_ISO_TIMESTAMPS environment variable.
--no-color Print output without color.
--session token Authenticate with this session token. 1Password CLI outputs session tokens for successful 'op signin' commands when
biometric unlock is disabled.
Run 'op [command] --help' for more information on the command.
Thanks for the quick response.
I was thinking that probably an approach will be to to have a op2 provider, it seems most of the code will be the same just need to adjust the CLI params order.
I can try to prepare a PR if you are interested
Describe the bug
1Password released a v2.x of their CLI, and introduced breaking changes in the commands, for instance now the commands are something like:
instead of what currently
ssh-manager
is expecting:Below the error when trying to run
ssh-manager list
To Reproduce
Steps to reproduce the behavior:
ssh-manager
Expected behavior
Get/list the SSH Key items stored in 1Password
Environment:
ssh-manager version
):INFO[27-05-2022 17:11:12] ssh-manager v1.0.0
The text was updated successfully, but these errors were encountered: