theme-destroyer
v1.0.1
Published
A CLI tool to manage and delete Shopify themes
Readme
theme-destroyer (previously theme-destroyer-3000)
A CLI tool to manage and delete Shopify themes
Overview
Theme Destroyer is a powerful CLI tool that helps you manage Shopify stores and safely delete unwanted themes. It provides an interactive interface for selecting and removing themes from your Shopify stores.
Features
- 🔐 Secure Store Management - Add and manage multiple Shopify stores with encrypted API token storage
- 🎯 Interactive Theme Selection - Use checkboxes to select which themes to delete
- 🔍 Theme Search & Delete - Search for themes by keyword and optionally delete them
- 🛡️ Safe Deletion - Confirmation prompts before deleting themes
- 📋 Store Listing - View all your stores with masked API tokens for security
- ⚡ Fast & Reliable - Direct Shopify API integration for quick operations
Installation
npm install -g theme-destroyerUsage
Adding a Store
Add a new Shopify store to manage:
# Add store with interactive token prompt
themedestroyer store add store-name
# Add store with token flag
themedestroyer store add store-name -t shpat_your_token_hereListing Stores
View all your stored stores:
themedestroyer store listRemoving a Store
Remove a store from your configuration:
# Remove specific store
themedestroyer store remove store-name
# Interactive store selection
themedestroyer store removeSearching and Deleting Themes
Search for themes by keyword and optionally delete them:
# Search themes with keyword and choose to delete
themedestroyer store search "dark"
# Search in specific store
themedestroyer store search "theme" --store store-nameDeleting Themes
Run the main command to fetch and delete themes:
# Run theme deletion (interactive)
themedestroyer run
# Or just run without the command name
themedestroyerCommands
themedestroyer run- Fetch themes from Shopify and delete selected onesthemedestroyer store add STORE- Add a new Shopify store and API tokenthemedestroyer store list- List all stored Shopify stores and their API tokens (masked)themedestroyer store remove [STORE]- Remove a Shopify store from storagethemedestroyer store search KEYWORD- Search for themes by keyword and optionally delete them
themedestroyer run
Fetch themes from Shopify and delete selected ones
USAGE
$ themedestroyer run [-s <value>]
FLAGS
-s, --store=<value> Store name to use (if not provided, will show selection)
DESCRIPTION
Fetch themes from Shopify and delete selected ones
EXAMPLES
$ themedestroyer run
$ themedestroyer run --store store-namethemedestroyer store add STORE
Add a new Shopify store and API token
USAGE
$ themedestroyer store add STORE [-t <value>]
ARGUMENTS
STORE Store name (e.g., store-name)
FLAGS
-t, --token=<value> API token (if not provided, will be prompted)
DESCRIPTION
Add a new Shopify store and API token
EXAMPLES
$ themedestroyer store add store-name
$ themedestroyer store add store-name --token shpat_abc123...themedestroyer store list
List all stored Shopify stores and their API tokens (masked)
USAGE
$ themedestroyer store list
DESCRIPTION
List all stored Shopify stores and their API tokens (masked)
EXAMPLES
$ themedestroyer store listthemedestroyer store remove [STORE]
Remove a Shopify store from storage
USAGE
$ themedestroyer store remove [STORE]
ARGUMENTS
STORE Store name to remove (if not provided, will show selection)
DESCRIPTION
Remove a Shopify store from storage
EXAMPLES
$ themedestroyer store remove store-name
$ themedestroyer store removethemedestroyer store search KEYWORD
Search for themes by keyword and optionally delete them
USAGE
$ themedestroyer store search KEYWORD [-s <value>]
ARGUMENTS
KEYWORD Keyword to search for in theme names
FLAGS
-s, --store=<value> Store name to search themes in
DESCRIPTION
Search for themes by keyword and optionally delete them
EXAMPLES
$ themedestroyer store search "dark"
$ themedestroyer store search "theme" --store store-nameSecurity
- API tokens are stored securely in
~/.themedestroyer/config.json - Tokens are masked when displayed (showing only last 4 characters)
- Interactive confirmation before deleting themes
- No sensitive data is logged or transmitted
Requirements
- Node.js >= 18.0.0
- Valid Shopify API token with theme management permissions
Getting a Shopify API Token
- Go to your Shopify admin panel
- Navigate to Apps > App and sales channel settings
- Click "Develop apps" > "Create an app"
- Configure the app with the following permissions:
read_themeswrite_themes
- Install the app and copy the Admin API access token
License
MIT
