AI-powered Git CLI for commit messages, PRs, and issues
npm install @koushik_xd/dashAI-powered Git CLI for commit messages, PRs, and GitHub workflows.
``bash`
npm install -g @koushik_xd/dash
Then run:
`bash`
dash setup
> Note: If you have the system shell dash installed (common on Debian/Ubuntu), use dash-cli instead of dash for all commands.
- Node.js 18+
- Git
- Groq API Key from console.groq.com/keys
- GitHub CLI (optional) - for PR/issue commands. Get it at cli.github.com
`bash
dash config set GROQ_API_KEY=gsk_your_key_here
dash setup
git add .
dash commit
dash pr
`
`bash`
dash commit [-g
| Flag | Description |
| ----------------------- | ---------------------------- |
| -g, --generate | Generate n messages (max: 5) |-x, --exclude
| | Exclude files |-a, --all
| | Stage all tracked files |-t, --type
| | Use conventional format |
Examples:
`bash`
dash commit
dash commit --all
dash commit --exclude dist/ --generate 3
dash commit --type conventional
`bash`
dash pr [create|list|view|merge] [flags]
| Subcommand | Description |
| ---------- | ---------------- |
| create | Create/edit PR |list
| | List open PRs |view
| | View current PR |merge
| | Merge current PR |
Create flags:
| Flag | Description |
| --------------------- | --------------- |
| -b, --base | Base branch |-d, --draft
| | Create as draft |
Merge flags:
| Flag | Description |
| -------------- | ------------ |
| -s, --squash | Squash merge |-m, --merge
| | Merge commit |-r, --rebase
| | Rebase merge |
Examples:
`bash`
dash pr
dash pr --draft --base develop
dash pr list
dash pr merge --squash
`bash`
dash issue list [-s
| Flag | Description |
| --------------------- | ------------------------ |
| -s, --state | open, closed, all |-l, --limit
| | Max issues (default: 20) |
Examples:
`bash`
dash issue list
dash issue list --state all --limit 10
`bash`
dash config
Examples:
`bash`
dash config set GROQ_API_KEY=gsk_xxx
dash config set model=llama-3.3-70b-versatile
dash config get GROQ_API_KEY model
`bash`
dash hook
Installs git hook for auto-message generation.
`bash`
dash setup
Checks dependencies and configures GitHub CLI integration.
Config stored in ~/.dash:
| Option | Default | Description |
| -------------- | ------------------ | ------------------ |
| GROQ_API_KEY | - | API key (required) |model
| | openai/gpt-oss-20b | AI model |generate
| | 1 | Commit suggestions |type
| | - | Use conventional |max-length
| | 100 | Max message length |locale
| | en | Message language |timeout
| | 10000 | API timeout (ms) |gh_enabled
| | true | Enable gh features |
Create a .dash folder in your repository:
- .dash/commit.md - Overrides commit prompt.dash/pr.md
- - Overrides PR prompt
When these files exist, dash uses them instead of the built-in prompts.
Monorepo support: Dash searches up the directory tree, so you can have:
``
monorepo/
├── .dash/commit.md # Root rules
└── packages/
├── api/.dash/commit.md # API rules
└── web/.dash/commit.md # Web rules
Each package can have its own prompts.
| Variable | Description |
| -------------- | ----------- |
| GROQ_API_KEY | API key |HTTPS_PROXY
| | HTTP proxy |
Requires gh:
- dash prdash issue
-
Works without gh:
- dash commitdash hook
- dash config
- dash setup
-
Many Linux systems (Debian, Ubuntu, etc.) have /usr/bin/dash (the Debian Almquist Shell) installed. If your npm bin directory is lower in PATH priority, the system shell runs instead.
Solution: Use dash-cli instead of dash:
`bash`
dash-cli setup
dash-cli commit
dash-cli pr
Both dash and dash-cli are provided as binary names. Use whichever works on your system.
Alternative: Fix your PATH to prioritize npm globals:
`bashCheck where dash resolves to
which dash
Development
`bash
git clone https://github.com/koushikxd/dash-cli.git
cd dash/packages/clipnpm install
pnpm build
pnpm dev
pnpm test
`Structure
`
packages/cli/
├── src/
│ ├── commands/ # Command implementations
│ ├── utils/ # Git, config, API helpers
│ ├── errors.ts
│ └── index.ts
├── tests/
└── dist/
`Contributing
1. Fork it
2. Create a feature branch
3. Make changes
4. Run tests:
pnpm test
5. Use dash to commit: dash commit
6. Use dash for PR: dash pr`Inspired by noto by Sithija Nelusha Silva.
MIT