Created
June 27, 2022 05:39
-
-
Save charmoniumQ/d0b4c5689956fb3150a6545016d34851 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Sort items by publication venue in Zotero | |
// Highlight a set of items first. | |
const items = Zotero.getActiveZoteroPane().getSelectedItems(); | |
itemsByPub = {}; | |
for (const i in items) { | |
itemInfo = items[i].toJSON(); | |
publication = itemInfo.publicationTitle; | |
if (!(publication in itemsByPub)) { | |
itemsByPub[publication] = []; | |
} | |
itemsByPub[publication].push(itemInfo.title); | |
} | |
itemsByPub |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment