DEFAULT_GROUP for contrib/importers/lastpass2pass.rb

Devin Smith devinrsmith at protonmail.com
Tue Oct 8 16:32:59 CEST 2019


The DEFAULT_GROUP was not working for me in contrib/importers/lastpass2pass.rb - during the import, uncategorized passwords were not being imported with the DEFAULT_GROUP.

This simple change seemed to fix the problem for me:

diff --git a/contrib/importers/lastpass2pass.rb b/contrib/importers/lastpass2pass.rb
index bf46c8c..02e05ac 100755
--- a/contrib/importers/lastpass2pass.rb
+++ b/contrib/importers/lastpass2pass.rb
@@ -99,7 +99,7 @@ entries.each do |e|
   password = args.shift
   fav = args.pop
   grouping = args.pop
-  grouping = DEFAULT_GROUP if grouping == nil
+  grouping = DEFAULT_GROUP if grouping.empty?
   name = args.pop
   extra = args.join(",")[1...-1]

Although - it looks like this line was intentionally changed https://git.zx2c4.com/password-store/commit/contrib/importers/lastpass2pass.rb?id=85757e99bff29d6fa663a6b291c9047ccce8c6d3.

I'm not familiar with ruby, but here is my version:

$ ruby --version
ruby 2.6.3p62 (2019-04-16 revision 67580) [x86_64-linux]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.zx2c4.com/pipermail/password-store/attachments/20191008/802aabc7/attachment.html>


More information about the Password-Store mailing list