> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Scripts & Automation

> Developer scripts for building, testing, and releasing PraisonAI

The `src/praisonai/scripts/` folder contains automation scripts for development, testing, and release workflows.

## Script Overview

| Script                  | Purpose                                                                                 |
| ----------------------- | --------------------------------------------------------------------------------------- |
| `install.sh`            | Frictionless, environment-isolated one-liner installer (uv tool → pipx → venv fallback) |
| `install.ps1`           | One-liner installer for Windows                                                         |
| `bump_and_release.py`   | Automated version bump and release                                                      |
| `bump_version.py`       | Version management utility                                                              |
| `check_version_sync.py` | Verify version consistency across packages                                              |
| `release.py`            | PyPI release automation                                                                 |
| `test-install-smoke.sh` | Smoke test the installer                                                                |

***

## One-Liner Installer

The installer scripts provide a frictionless installation experience:

**macOS/Linux:**

```bash theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
curl -fsSL https://praison.ai/install.sh | bash
```

**Windows PowerShell:**

```powershell theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
iwr -useb https://praison.ai/install.ps1 | iex
```

### Features

* **OS Detection** - Automatically detects macOS, Linux (various distros), Windows, WSL
* **Isolation Backend** - Auto-selects `uv tool` → `pipx` → venv fallback; override with `--backend`
* **Python Management** - Installs Python 3.10+ if not available (venv path only)
* **Package Manager Support** - brew, apt, dnf, pacman, winget, chocolatey
* **PATH Shim** - Drops `~/.local/bin/praisonai` so the CLI is available without activating a venv
* **Idempotent PATH Block** - Appends a clearly-marked `# >>> PraisonAI PATH >>>` block to shell rc; skip with `--no-modify-path`
* **Shell Completions** - Offers to install bash/zsh/fish completions via `praisonai completion <shell>`
* **Interactive Onboarding** - Prompts for LLM setup and bot configuration after installation
* **Dry Run Mode** - Preview changes before applying

### Environment Variables

| Variable                   | Default        | Description                                               |
| -------------------------- | -------------- | --------------------------------------------------------- |
| `PRAISONAI_VERSION`        | `latest`       | Specific version to install                               |
| `PRAISONAI_EXTRAS`         | `""`           | Comma-separated extras (defaults to `all`)                |
| `PRAISONAI_BACKEND`        | `auto`         | Force backend: `uv` / `pipx` / `venv` / `system` / `auto` |
| `PRAISONAI_INSTALL_DIR`    | `~/.praisonai` | Base dir for the venv fallback                            |
| `PRAISONAI_NO_MODIFY_PATH` | `0`            | Skip shell rc PATH modification (`1` to enable)           |
| `PRAISONAI_SKIP_VENV`      | `0`            | Skip isolation entirely (`1` to enable)                   |
| `PRAISONAI_DRY_RUN`        | `0`            | Preview mode                                              |
| `PRAISONAI_NO_ONBOARD`     | `0`            | Skip interactive onboarding entirely                      |

### Examples

```bash theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
# Basic install (isolated: uv tool -> pipx -> venv)
curl -fsSL https://praison.ai/install.sh | bash

# Force pipx backend
curl -fsSL https://praison.ai/install.sh | bash -s -- --backend pipx

# Install with extras
PRAISONAI_EXTRAS=ui,chat curl -fsSL https://praison.ai/install.sh | bash

# Don't touch shell rc
curl -fsSL https://praison.ai/install.sh | bash -s -- --no-modify-path

# Dry run (preview only)
PRAISONAI_DRY_RUN=1 curl -fsSL https://praison.ai/install.sh | bash

# Non-interactive for CI/CD
curl -fsSL https://praison.ai/install.sh | bash -s -- --no-prompt
```

***

## Version Management

### bump\_version.py

Updates version across all package files:

```bash theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
cd src/praisonai
python scripts/bump_version.py 2.3.0
```

Updates:

* `praisonai/version.py`
* `pyproject.toml`

### check\_version\_sync.py

Verifies all packages have consistent versions:

```bash theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
python src/praisonai/scripts/check_version_sync.py
```

***

## Release Workflow

### bump\_and\_release.py

Automated release pipeline:

```bash theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
python src/praisonai/scripts/bump_and_release.py
```

1. Bumps version
2. Updates changelog
3. Creates git tag
4. Pushes to GitHub
5. Triggers PyPI release

### release.py

Manual PyPI release:

```bash theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
python src/praisonai/scripts/release.py
```

***

## Smoke Testing

### test-install-smoke.sh

Tests the installer in isolated Docker containers:

```bash theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
cd src/praisonai/scripts
./test-install-smoke.sh
```

Tests across:

* Ubuntu 22.04
* Debian 12
* Alpine Linux

### Docker Test Files

Located in `scripts/docker/install-smoke/`:

| File         | Purpose                  |
| ------------ | ------------------------ |
| `Dockerfile` | Test container image     |
| `run.sh`     | Installation test script |

***

## Adding New Scripts

When adding new scripts:

1. **Location**: Place in `src/praisonai/scripts/`
2. **Permissions**: Make executable with `chmod +x script.sh`
3. **Documentation**: Update this page
4. **Testing**: Add to CI/CD if applicable

```bash theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
# Make script executable
chmod +x src/praisonai/scripts/my-script.sh

# Test locally
./src/praisonai/scripts/my-script.sh
```

***

## Related

<CardGroup cols={2}>
  <Card title="Local Development" icon="code" href="/docs/developers/local-development">
    Setting up dev environment
  </Card>

  <Card title="Testing" icon="flask" href="/docs/developers/testing">
    Running tests
  </Card>
</CardGroup>
