This tool makes it easy to duplicate a store's content onto another, either to spin up a staging env or to simply test stuff out without risking anything in production.
With this tool, you can sync/duplicate the following resources:
- Products (and their variants, including images, alt tags and images being tied to specific variants as well as metafields)
- Smart Collections (Along with its image, filters and metafields)
- Custom Collections (Along with its image, products (mapped using their handle) and metafields)
- Shop-level metafields
- Blogs (along with their metafields)
- Articles (mapped to a blog of the same handle. Comes along with their metafields)
- Pages (along with their metafields)
You'll first need to create 2 private apps. One needs read access on the source store, the other needs read/write on the destination store.
Here are the access copes that will be required:
- Store content like articles, blogs, comments, pages, and redirects
- Products, variants and collections
Then, you will need to create a .env file (copy it from .env.example) and fill it out with the right api information you will have gathered from the private apps process.
By default, simply running yarn start will validate that each store is able to be read from. It will not do anything unless specifically told to using flags.
--productscopies over products (and variants, images & metafields)--delete-productswill override pre-existing products.--collectionscopies over collections--delete-collectionswill override pre-existing collections.--pagescopies over pages (along with metafields)--delete-pageswill override pre-existing pages.--blogscopies over blogs--delete-blogswill override pre-existing articles.--articlescopies over articles--delete-articleswill override pre-existing articles.--metafieldscopies over shop metafields--delete-metafieldswill override pre-existing shop metafields.--allwill sync everything.
- Copying only product: run
yarn start --products - Copying only pages: run
yarn start --pages - Copying only articles: run
yarn start --articles - Copying products & articles: run
yarn start --products --articles - Copying products, pages & articles: run
yarn start --products --articles --pages - Just copy everything you can: run
yarn start --all
Create a new issue, or issue a new PR on this repo if you've found an issue and would like it fixed.
MIT. Do whatever you like with this stuff ✌️.