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

Error when running sudo ai config set OPENAI_KEY=<my openi key goes here> #97

Open
mightywomble opened this issue Sep 19, 2023 · 2 comments

Comments

@mightywomble
Copy link

Getting the following error

file:///usr/local/lib/node_modules/@builder.io/ai-shell/dist/cli.mjs:1079
const value = cliConfig?.[key] ?? config[key];
^

SyntaxError: Unexpected token '.'
at Loader.moduleStrategy (internal/modules/esm/translators.js:133:18)
at async link (internal/modules/esm/module_job.js:42:21)

@DmitriiCM
Copy link

I had the same issue on Ubuntu, the default nodejs version installed by apt is ancient old.

Install version 20 LTS, then everything works

curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash
nvm install v20.13.0

@jeon3029
Copy link

@DmitriiCM Thanks. It works for me!

$ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash
$ source ~/.nvm/nvm.sh
$ nvm install v20.13.0

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

No branches or pull requests

3 participants