fnogatz / xsd2json

Translate XML Schema into equivalent JSON Schema
MIT License
150 stars 28 forks source link

Error installing on Ubuntu via npm #47

Closed fearzendron closed 7 years ago

fearzendron commented 8 years ago

When I tried to run on Ubuntu 14.04 this happen:

/usr/local/bin/xsd2json -> /usr/local/lib/node_modules/xsd2json/lib-pl/cli

xsd2json@1.7.10 postinstall /usr/local/lib/node_modules/xsd2json npm run create-qlf

/usr/local/lib/node_modules/.bin/npm: 2: exec: /usr/local/lib/node_modules/.bin/node: not found npm ERR! Linux 3.13.0-92-generic npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "xsd2json" npm ERR! node v4.2.2 npm ERR! npm v2.14.7 npm ERR! file sh npm ERR! code ELIFECYCLE npm ERR! errno ENOENT npm ERR! syscall spawn

npm ERR! xsd2json@1.7.10 postinstall: npm run create-qlf npm ERR! spawn ENOENT npm ERR! npm ERR! Failed at the xsd2json@1.7.10 postinstall script 'npm run create-qlf'. npm ERR! This is most likely a problem with the xsd2json package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! npm run create-qlf npm ERR! You can get their info via: npm ERR! npm owner ls xsd2json npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /home/sciensa/npm-debug.log

fnogatz commented 8 years ago

Hi @fearzendron, I am not sure this is an error of xsd2json. Your printed error message /usr/local/lib/node_modules/.bin/npm: 2: exec: /usr/local/lib/node_modules/.bin/node: not found suggests that your node/npm installation is broken. The ENOENT indicates that some file is missing.

You could do a manual install of xsd2json by calling:

git clone https://github.com/fnogatz/xsd2json.git
cd xsd2json
npm install
./lib-pl/cli --help
fnogatz commented 7 years ago

Is this problem still there? Feel free to comment or open again if this is a problem with xsd2json and not your node installation.