Migração para CLI 3.0
Instalação
Instale o Command Line Tools:
xcode-select --installAtualize o shopify com Homebrew:
brew upgrade shopify-cli
Caso não esteja em macos ou sua versão atual não tenha sido instalado pelo brew, verificar aqui.Verifique a versão do Shopify:
shopify versionFaça o login na loja com o comando atualizado:
shopify theme dev --store=sallvestore.myshopify.com
Atualizações
| CLI 2.0 | CLI 3.0 | |
|---|---|---|
| Authentication | Authenticate with Shopify CLI using shopify login | You don't need to log in explicitly. If you aren't logged in, then you're prompted to log in when you run a command that requires authentication. |
View the organization you're currently logged into using shopify whoami | No longer supported | |
| Store selection | Select a store using shopify login --store | Pass a --store flag the first time you run a command that requires connection to a store. This store is used in subsequent commands. |
Switch between stores using shopify switch | Pass a --store flag with a new value when you want to run a command against a new store | |
Run shopify store to view which store you're currently using. | Run shopify theme info to view which store you're currently using | |
| General | Preview your theme in a store using shopify theme serve | Command is renamed to shopify theme dev |
Populate stores using shopify populate [ products \| draftorders \| customers ] | No longer supported | |
Specify the directory that you want to use using the [root] positional argument | Specify the directory that you want to use using the –-path flag |
Testes
- Rodar ambiente de desenvolvimento
npm run dev:sallveounpm run dev:contem - Fazer deploy de tema homolog
npm run deploy:homolog "teste - deploy" - Trocar de loja sallve-contem - basta rodar qualquer comando que precise de autenticação (vide item 1)