wikibase-cli 15.16.1 → 15.16.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -0
- package/bin/wd +9 -3
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -5,6 +5,8 @@ This tool is mostly a CLI interface to the JS modules [wikibase-edit](https://ww
|
|
|
5
5
|
|
|
6
6
|
It was primarily developed to target [Wikidata](https://wikidata.org), but as then been decoupled to support any Wikibase instance.
|
|
7
7
|
|
|
8
|
+
Supported systems: any system that can run [NodeJS](https://nodejs.org/en/download/) (Linux, Mac OS, Windows, and more)
|
|
9
|
+
|
|
8
10
|
This project received [a Wikimedia Project Grant](https://meta.wikimedia.org/wiki/Grants:Project/WikidataJS).
|
|
9
11
|
|
|
10
12
|
<div align="center">
|
package/bin/wd
CHANGED
|
@@ -6,10 +6,16 @@
|
|
|
6
6
|
|
|
7
7
|
const { spawn } = require('child_process')
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
const escapeDollars = arg => arg.replace(/\$/g, '\\$')
|
|
10
|
+
const args = process.argv.slice(2).map(escapeDollars)
|
|
11
|
+
|
|
12
|
+
spawn('wb', args, {
|
|
11
13
|
env: Object.assign({
|
|
12
14
|
WB_INSTANCE: 'https://www.wikidata.org',
|
|
13
15
|
WB_SPARQL_ENDPOINT: 'https://query.wikidata.org/sparql',
|
|
14
|
-
}, process.env)
|
|
16
|
+
}, process.env),
|
|
17
|
+
stdio: 'inherit',
|
|
18
|
+
// Required to not get a ENOENT on Windows
|
|
19
|
+
// See https://stackoverflow.com/a/54515183/3324977
|
|
20
|
+
shell: true,
|
|
15
21
|
})
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wikibase-cli",
|
|
3
|
-
"version": "15.16.
|
|
3
|
+
"version": "15.16.2",
|
|
4
4
|
"description": "A command-line interface to Wikibase",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"lint-staged": "./scripts/lint_staged",
|
|
14
14
|
"prepublishOnly": "npm run lint && npm test",
|
|
15
15
|
"postpublish": "npm run docker:publish && git push --tags",
|
|
16
|
-
"test": "mocha --exit --timeout 20000",
|
|
16
|
+
"test": "mocha --exit --timeout 20000 $MOCHA_OPTIONS",
|
|
17
17
|
"update-toc": "./scripts/update_toc"
|
|
18
18
|
},
|
|
19
19
|
"repository": {
|