Starter: https://shopify.github.io/themekit/commands/#using-environments
Create Shopify Private App and config permission correctly by following the starter instruction:
- In the store’s Shopify admin, click Apps.
- Near the bottom of the page, click on Manage private apps.
- If you see a notice that “Private app development is disabled”, then click “Enable private app development”. (Note: Only the store owner can enable private app development)
- Click Create new private app.
- In the App details section, fill out the app name and your email address.
- In the Admin API section, click Show inactive Admin API permissions.
- Scroll to the “Themes” section and select Read and write from the dropdown.
- Click Save.
- Read the private app confirmation dialog, then click Create app.
You’ll return to the app detail page. Your new, unique access credentials are visible in the Admin API section. Copy the password. You’ll use it in the next step.
- MacOS (use homebrew):
brew tap shopify/shopify brew install themekit
- Window (use chocolatey):
choco install themekit
-
Create a new theme
theme new --password=[your-password] --store=[your-store.myshopify.com] --name=[theme name]
-
Or configure an existing theme.
theme get -p=[your-password] -s=[you-store.myshopify.com] -t=[your-theme-id]
To get all theme's Ids:
theme get --list -p=[your-password] -s=[you-store.myshopify.com]
Use the following command to start the development server
theme watch
Add --allow-live
flag to watch directory for changes and update remote theme
theme watch --allow-live
Other commands:
-
Download changes from Shopify
theme download
-
Open live theme (store's preview)
theme open
- Theme files may not be stored in subfolders
Copyright © 2020 - Made by Leo @ https://leohuynh.dev