JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 6
  • Score
    100M100P100Q30735F
  • License MIT

A CLI tool to help projects setup development tools (husky, eslint, prettier, commitlint)

Package Exports

    This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (agircc) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

    Readme

    Agir

    A professional CLI tool to help projects quickly set up and configure essential development tools including Husky, ESLint, Prettier, and Commitlint.

    Features

    • 🚀 One-command setup - Install and configure all development tools with a single command
    • 🛠️ Professional configuration - Pre-configured with industry best practices
    • 🎯 Zero configuration - Works out of the box with sensible defaults
    • 📦 Modern tooling - Built with Vite and ES modules
    • 🔧 Git hooks - Automatically sets up pre-commit and commit-msg hooks

    Installation & Usage

    You can use agir directly with npx without installing it globally:

    npx agir@latest init

    Or install it globally:

    npm install -g agir
    agir init

    What it does

    When you run agir init, it will:

    1. Install development dependencies:

      • husky - Git hooks made easy
      • eslint - JavaScript/TypeScript linting
      • prettier - Code formatting
      • @commitlint/cli - Commit message linting
      • @commitlint/config-conventional - Conventional commit rules
      • @typescript-eslint/eslint-plugin - TypeScript ESLint rules
      • @typescript-eslint/parser - TypeScript parser for ESLint
      • lint-staged - Run linters on staged files
    2. Create configuration files:

      • .eslintrc.json - ESLint configuration
      • .prettierrc.json - Prettier configuration
      • .prettierignore - Files to ignore for Prettier
      • commitlint.config.js - Commitlint configuration
    3. Set up Git hooks:

      • pre-commit - Runs linting and formatting before commits
      • commit-msg - Validates commit message format
    4. Add npm scripts to package.json:

      • lint - Run ESLint
      • lint:fix - Fix ESLint issues automatically
      • format - Format code with Prettier
      • format:check - Check if code is properly formatted
      • prepare - Initialize Husky (runs on npm install)

    Requirements

    • Node.js >= 18.0.0
    • npm or yarn
    • Git repository (must be run in a project with package.json)

    Commit Message Format

    After setup, your commit messages should follow the conventional commit format:

    type(scope): description
    
    Examples:
    feat: add new feature
    fix: resolve bug in authentication
    docs: update README
    style: fix formatting
    refactor: improve code structure
    test: add unit tests
    chore: update dependencies

    Development

    To contribute to this project:

    # Clone the repository
    git clone <repository-url>
    cd agir-js
    
    # Install dependencies
    npm install
    
    # Build the project
    npm run build
    
    # Test the CLI locally
    node dist/cli.js --help

    License

    MIT