Questions and discussions about using the Shopify CLI and Shopify-built libraries.
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
To upgrade the CLI shopify app using npm, this shopify page tells me to enter on my windows console the following:
npm run shopify upgrade
Unlike previous times I have done this, I get the (repeatable) error message:
npm ERR! Missing script: "shopify"
npm ERR!
npm ERR! To see a list of scripts, run:
npm ERR! npm run
Incidentally, the info command also fails (referenced on the page https://shopify.dev/apps/tools/cli/commands) with the error:
npm run info
npm ERR! Missing script: "info"
npm ERR!
npm ERR! To see a list of scripts, run:
npm ERR! npm run
The problem appears to be with npm. Note that my (current) CLI version 2.18.0 continues to function. Rebooting the computer has no effect.
Suggestions? Thanks! jb
Solved! Go to the solution
This is an accepted solution.
Hi!
Those commands you mention belong to the new CLI 3.0. You can find a migration guide here: https://shopify.dev/apps/tools/cli/migrate
If you want to get the latest CLI 2.0 version, you can run "gem update shopify-cli" if you installed it as a Ruby gem, or "brew upgrade shopify-cli" if it was installed via Homebrew.
Sorry for the confusion.
To learn more visit the Shopify Help Center or the Community Blog.
This is an accepted solution.
Hi!
Those commands you mention belong to the new CLI 3.0. You can find a migration guide here: https://shopify.dev/apps/tools/cli/migrate
If you want to get the latest CLI 2.0 version, you can run "gem update shopify-cli" if you installed it as a Ruby gem, or "brew upgrade shopify-cli" if it was installed via Homebrew.
Sorry for the confusion.
To learn more visit the Shopify Help Center or the Community Blog.
Brilliant! Worked like a charm, silly me.
So ... I have a question. My app has a top level component, which references a function, which in turn calls more functions (all the way down).
That first function (and only that one) has a CLI issue. When I perform the windows console command "shopify app serve", I start running a server (via ngrok). For ALL other function files, changes via VScode to the content of the files causes an immediate recompile and changes the running code. Just fine.
For THAT first function, the recompile is initiated, with varying results.
5% of the time the recompile completes and the new code executes. Just fine.
10% of the time the recompile hangs. I have to Ctrl-C and restart "shopify app serve".
85% of the time the recompile completes (or so I am told), BUT the code is not changed, I continue to run the obsolete code, so I have to Ctrl-C and restart "shopify app serve".
Note that the third option never affects any other function file.
Any idea what is happening? It has been going on for a month or two now. It's quite a pain. Do you think CLI 3.0 would fix this?
Thanks and happy 4th to you, jb
@den232 about this other question, I'm not sure about what could happen, but we would need more details to investigate. You can open an issue here: https://github.com/Shopify/shopify-cli/issues
But I'd recommend you to to upgrade to CLI 3.0, as it might work as expected there. Also, we will keep maintaining the old CLI 2.0 for now, but new features will only be added to CLI 3.0.
To learn more visit the Shopify Help Center or the Community Blog.