cocktailpeanut / dalai

The simplest way to run LLaMA on your local machine
https://cocktailpeanut.github.io/dalai
13.09k stars 1.42k forks source link

Throw explicit error when there's a typo in the install command #457

Open JQuezada0 opened 1 year ago

JQuezada0 commented 1 year ago

Relevant issue: https://github.com/cocktailpeanut/dalai/issues/371

When running npx dalai llama install [..] if you don't spell "llama" correctly you'll get an error that doesn't indicate what's failing

ERROR TypeError: Cannot read properties of undefined (reading 'home')
    at Dalai.install ($HOME/.npm/_npx/3c737cbb02d79cc9/node_modules/dalai/index.js:337:43)

This will just be a bit more explicit