Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jscad cli does not work via clean install on fresh linux machine #1342

Open
DavidLyon66 opened this issue May 2, 2024 · 1 comment
Open

Comments

@DavidLyon66
Copy link

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

  1. install jscad cli as per documented instructions on a fresh ubuntu installation ie, sudo npm install -g @jscad/cli
  2. save a jscad example from off openjscad.xyz to a disk file
  3. 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

2024-04-24-213431
2024-05-03-033421
2024-05-03-035320
2024-05-03-040155

@z3dev
Copy link
Member

z3dev commented Jun 13, 2024

@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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants