maxlath / wikibase-cli

read and edit a Wikibase instance from the command line
MIT License
223 stars 24 forks source link

Add symmetric property/edit multiple items #144

Closed haansn08 closed 3 years ago

haansn08 commented 3 years ago

I have prepared a list of items I want to connect with different from (P1889):

Q395330 Q28230734
Q85864592 Q20827132
Q15616625 Q97310450
...

I have this template in mind:

module.exports = function(a, b) {
    return [
        {id: a, claims: {P1889: b}},
        {id: b, claims: {P1889: a}}
    ];
}

However wd ee --batch template.js < list.txt does not seem to like it. How can I use wikidata-cli to quickly add statements which require editing multiple items?

maxlath commented 3 years ago

That should now be possible in v15.10.0 (implemented in 4b66ee7): can you update and retry?

maxlath commented 3 years ago

I added a generalized version of that template to the template collection

haansn08 commented 3 years ago

Works perfectly. Thank you very much!