atm

Atomix

v0.4.6

    1. Home
    2. Guides
    3. CLI Tool

Getting Started
  • Introduction
  • Installation
  • Quick Start
  • Migration Guide
  • CLI Reference
Design Tokens
  • Overview
  • All Tokens
  • Colors
  • Spacing
  • Typography
  • Grid
  • Elevation
Styles System
  • Architecture
  • Customization
  • Utilities
  • API Reference
Layouts
  • Grid System
  • Masonry Grid
  • Responsive Patterns
  • Customization
  • Performance
Components
  • Overview
  • Guidelines
  • Accordion
  • AtomixGlass
  • Avatar
  • Badge
  • Breadcrumb
  • Button
  • ButtonGroup
  • Card
  • Checkbox
  • Date Picker
  • Dropdown
  • Form
  • Input
  • Modal
  • Progress
  • Radio
  • Rating
  • Select
  • Slider
  • Spinner
  • Tab
  • Textarea
  • Toggle
  • Tooltip
  • Upload
  • Block
  • Callout
  • Countdown
  • Hero
  • Icon
  • List
  • Messages
  • Navbar
  • Pagination
  • Popover
  • Steps
  • SectionIntro
  • Container
  • Grid
  • GridCol
  • Row
  • River
  • MasonryGrid
  • DataTable
  • EdgePanel
  • SideMenu
  • Nav
  • NavItem
  • NavDropdown
  • VirtualizedGrid
Guides
  • Theming Guide
  • AtomixGlass Performance
  • AtomixGlass Theming
  • Theme Studio
  • Devtools
  • Theme Inspector
  • Theme Preview
  • Theme Comparator
  • Live Editor
  • CLI Tool
  • Try Live Editor
  • Try Inspector
  • Try Preview
  • Try Comparator
  • AtomixGlass Playground
Examples
  • Common Patterns
  • Landing Page
API Reference
  • React API
  • JavaScript API
  • CSS API
CLI
  • Overview
  • User Guide
  • API Reference
  • Migration Guide
  • Security Guide
Resources
  • Roadmap
  • Changelog
  • Contributing

Atomix Design System

A comprehensive design system for building modern, accessible, and performant web applications with React and vanilla JavaScript.
GitHubTwitterDiscordNPM

Getting Started

IntroductionInstallationQuick StartTheming Guide

Documentation

ComponentsDesign TokensStyles SystemLayouts

Resources

GitHub Repository↗NPM Package↗Storybook↗API Reference

Community

ContributingRoadmapChangelogReport Issue↗

© 2026 Atomix Design System. Built with ❤️ by the Shohojdhara.

Command-line tools for theme development

Atomix Theme CLI

Validate, inspect, compare, and export themes from the command line. Integrate theme tools into your build process and CI/CD pipeline.

Command-Line Interface

The Atomix Theme CLI provides powerful command-line tools for theme validation, inspection, comparison, and export. Perfect for automation and CI/CD integration.

Installation

Global Installation

BASH
# Install globally npm install -g @shohojdhara/atomix # Verify installation atomix-theme --version
5 lines99 characters

Project Installation

BASH
# Install as dev dependency npm install --save-dev @shohojdhara/atomix # Use with npx npx atomix-theme --help
5 lines110 characters

Available Commands

CommandDescriptionOptions
validateValidate theme configuration--config, --strict
listList all available themes-
inspectInspect a specific theme--theme, --json
compareCompare two themes--theme1, --theme2
exportExport theme to JSON--theme, --output
helpShow help information-

Command Examples

Validate Theme

Validate a theme configuration file:

BASH
# Validate default config atomix-theme validate # Validate specific config file atomix-theme validate --config ./my-theme.json # Strict mode (fail on warnings) atomix-theme validate --strict
8 lines192 characters

Validation checks for required properties, type correctness, color formats, and accessibility issues.

List Themes

Display all available themes:

BASH
# List all themes atomix-theme list # Output: # Available themes: # - light (Light Theme) # - dark (Dark Theme) # - custom (Custom Theme)
8 lines144 characters

Inspect Theme

Get detailed information about a theme:

BASH
# Inspect theme (human-readable) atomix-theme inspect --theme light # Inspect theme (JSON output) atomix-theme inspect --theme light --json # Pipe to file atomix-theme inspect --theme light --json > theme-info.json
8 lines216 characters

Compare Themes

Compare two themes and show differences:

BASH
# Compare two themes atomix-theme compare --theme1 light --theme2 dark # Compare theme files atomix-theme compare --theme1 ./v1.json --theme2 ./v2.json # Output differences only atomix-theme compare --theme1 light --theme2 dark --diff-only
8 lines241 characters

Export Theme

Export a theme to JSON file:

BASH
# Export to default location atomix-theme export --theme light # Export to specific file atomix-theme export --theme light --output ./themes/light.json # Export with formatting atomix-theme export --theme light --output ./light.json --pretty
8 lines243 characters

CI/CD Integration

GitHub Actions

Validate themes in your CI pipeline:

YAML
1name: Validate Themes 2 3on: [push, pull_request] 4 5jobs: 6 validate: 7 runs-on: ubuntu-latest 8 steps: 9 - uses: actions/checkout@v3 10 11 - name: Setup Node.js 12 uses: actions/setup-node@v3 13 with: 14 node-version: '18' 15 16 - name: Install dependencies 17 run: npm install 18 19 - name: Validate themes 20 run: npx atomix-theme validate --strict 21 22 - name: Compare with main 23 if: github.event_name == 'pull_request' 24 run: | 25 git fetch origin main 26 npx atomix-theme compare \ 27 --theme1 ./themes/current.json \ 28 --theme2 ./themes/new.json
28 lines659 characters

NPM Scripts

Add theme validation to package.json:

JSON
1{ 2 "scripts": { 3 "theme:validate": "atomix-theme validate", 4 "theme:validate:strict": "atomix-theme validate --strict", 5 "theme:list": "atomix-theme list", 6 "theme:export": "atomix-theme export --theme custom --output ./dist/theme.json", 7 "pretest": "npm run theme:validate" 8 } 9}
9 lines296 characters

Pre-commit Hook

Validate themes before committing:

BASH
1# .husky/pre-commit 2#!/bin/sh 3. "$(dirname "$0")/_/husky.sh" 4 5# Validate theme files 6npx atomix-theme validate --strict 7 8# Exit if validation fails 9if [ $? -ne 0 ]; then 10 echo "Theme validation failed. Please fix errors before committing." 11 exit 1 12fi
12 lines252 characters

Configuration

Config File

Create atomix.config.ts in your project root:

TYPESCRIPT
1import { defineConfig } from '@shohojdhara/atomix/config'; 2 3export default defineConfig({ 4 theme: { 5 themes: { 6 'my-theme': { 7 type: 'css', 8 name: 'My Theme', 9 description: 'Custom theme', 10 version: '1.0.0', 11 }, 12 }, 13 }, 14});
14 lines269 characters

Environment Variables

Configure CLI behavior with environment variables:

BASH
# Set config file path export ATOMIX_CONFIG=./config/atomix.config.ts # Set theme directory export ATOMIX_THEME_DIR=./src/themes # Enable debug mode export ATOMIX_DEBUG=true
8 lines175 characters

Troubleshooting

Common Issues

Command Not Found

If atomix-theme command is not found:

BASH
# Use npx instead npx atomix-theme --help # Or install globally npm install -g @shohojdhara/atomix
5 lines99 characters

Config File Not Found

Ensure atomix.config.ts exists in project root:

BASH
# Check if config exists ls atomix.config.ts # Specify config path atomix-theme validate --config ./path/to/config.ts
5 lines118 characters

Validation Errors

Run validation with verbose output:

BASH
# Verbose validation atomix-theme validate --verbose # Debug mode ATOMIX_DEBUG=true atomix-theme validate
5 lines106 characters

Best Practices

Automate Validation

Add theme validation to your CI/CD pipeline and pre-commit hooks to catch issues early.

Use Strict Mode

Enable strict mode in CI to fail builds on warnings, ensuring high theme quality.

Version Control Themes

Export themes to JSON and commit them to version control. Use compare command to review changes in pull requests.

Document Breaking Changes

When comparing theme versions, document any breaking changes (removed or significantly changed properties) in your release notes.

Related Tools

The CLI complements the React devtools components:

→ Theme Inspector - Visual theme inspection→ Theme Comparator - Visual theme comparison→ Live Editor - Interactive theme editing← Back to Devtools Overview