Stop importing vault items associated with an organization #34
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I don't have time to test this right now, but I wanted to throw it up as a possible suggestion. Currently, portwarden imports all vault items, including items associated with an organization. During the import, the organization(s) and collection(s) are erased and the item is imported as an orphaned item associated with the personal vault.
However, Bitwarden allows exporting all items associated with a given organization. I followed the following procedure:
This worked very well, but I ended up with duplicate entries because the organization vault items were imported by portwarden as ophaned entries. This PR should allow the process above to work, minus the duplicate orphaned entries.
In a perfect world, portwarden would handle creating the organization(s) and collection(s) - same as folders are already handled - but it looks like these commands aren't available in the Bitwarden CLI.
If given a build, I can test this PR. If it works as expected, I can update the Readme file with details about how Organizations/Collections can be handled with existing Bitwarden export/import tools.