jscad cli does not work via clean install on fresh linux machine
Expected Behavior
Jscad CLI to be able to run from command line after installation on linux
Actual Behavior
Jscad cli interface does not work with modeling
Steps to Reproduce the Problem
- install jscad cli as per documented instructions on a fresh ubuntu installation ie, sudo npm install -g @jscad/cli
- save a jscad example from off openjscad.xyz to a disk file
- run 'jscad
-o , an error is shown and the executable will not work.
Specifications
- Version: 2.12
- Platform: linux ubuntu
- Environment: (browser, local server, node.js etc) bash
@DavidLyon66 Yeah. You're correct. The 'global' installation does not work, and the documentation needs to be corrected.
The proper way to use the CLI is via a local project. There are many reasons for this but here's a really good discussion about the general issue of installing and maintaining global NPM packages. It's not a good idea.
https://www.sitepoint.com/solve-global-npm-module-dependency-problem/
I suggest creating a new local NPM package, and install the CLI as a dependency. You can then maintain that local package (and dependencies), and run the CLI in scripts, etc.
And if you really really need a global CLI then use NPM link.