Open waterkip opened 6 years ago
Same.
Username: foo
USERNAME: foo
Had to remove the extra fields using the GUI. Idk how they got there in the first place.
This is still an issue. Would love to see this fixed.
Hoping for a fix as well
Wow, I forgot that this issue was still open. Since lpass
doesn't let you delete some fields from an existing entry (e.g., foo
in the original comment on this issue), I wrote a Bash function that duplicates the entry of interest while only carrying forward the URL, username, and password fields—effectively stripping away extraneous fields like foo
:
# Usage: lpc <OLD_ID> <NEW_NAME>
lpc () {
lpass show -Gx "$1" | grep -E "^(Username|Password|URL):" | lpass add --non-interactive "$2";
lpass show -Gx "$2"
}
After verifying that the new duplicated entry looks right, you can manually delete the old entry. Here's an example of how this works:
$ lpass show -x github.com
github.com [id: 1234567890]
URL: https://github.com
Username: noperator
Password: notreallymypassword
foo: iwanttoremovethisfield # We'll remove this field.
$ lpc 1234567890 github.com # Copy ID "1234567890" to new entry named "github.com".
github.com [id: 1234567890] # Old entry.
URL: https://github.com
Username: noperator
Password: notreallymypassword
foo: iwanttoremovethisfield
github.com [id: 2345678901] # New entry without "foo" field.
URL: https://github.com
Username: noperator
Password: notreallymypassword
$ lpass rm 1234567890 # New entry looks good, so remove old entry.
It often takes a moment for lpass
to assign an identifier to the new entry, so it'll show up as [id: 0]
right after the lpc
function returns. Just give it a moment and run another lpass show -x <NAME>
until you see an ID on your new entry.
I guess you can use something like that as a workaround.
The function does not seem to copy over notes, which should be trivial to add. Also worth noting is that you will probably lose password history doing that.
Have a site that looks something like this:
Try to delete foo: bar by running
lpass edit $site
and remove the foo: bar line, save and commit Runlpass show $site
You'll see that foo: bar is still available