Skip to main content

Generate opinionated starter projects for Flutter, Django and Next.js.

Project description

DevForge

A CLI tool that generates opinionated starter projects for Flutter, Django and Next.js.

Built with Typer (CLI framework) and Rich (terminal UI).

Status: all three generators — Flutter, Django and Next.js — are fully working.

Usage

devforge version                # version + runtime info (also: devforge --version / -V)
devforge doctor                 # check required tooling and templates
devforge flutter my_app         # scaffold a Flutter project
devforge django my_site         # scaffold a Django project
devforge next my-web            # scaffold a Next.js project
devforge --help                 # help for the app or any command (-h works too)
devforge -v <command>           # enable debug logging

Generating into an existing folder is fine as long as it's empty — including a freshly cloned empty GitHub repository (its .git is preserved and DevForge then skips git init, leaving commits to you). All generators accept --no-git to skip repository initialisation explicitly.

devforge flutter

devforge flutter my_app \
  --org com.mycompany \          # Android/iOS bundle-id organisation (reverse-DNS)
  --app-name "My App" \          # display name (default: project name title-cased)
  --description "..." \          # pubspec description
  --api-url https://api.my.dev \ # baked into lib/core/constants/api_routes.dart
  -o ~/projects                  # parent directory (default: current directory)

What it does: checks the Flutter SDK → runs flutter create (correct platform folders for your --org) → replaces lib/, assets/, test/, pubspec.yaml and analysis_options.yaml with the DevForge template and substitutes its tokens → sets the app display name across android/ios/macos/web → adds the INTERNET permission to the main Android manifest (release builds need it for networking) → flutter pub get → regenerates branded launcher icons and splash screens from assets/images/logo.png (flutter_launcher_icons / flutter_native_splash) → git init + initial commit. The generated project is flutter analyze-clean.

The template intentionally has no android//ios/ folders — platform folders always come fresh from flutter create, so they never drift out of date with new Flutter releases. See templates/flutter_starter/TEMPLATE_REPORT.md.

devforge django

devforge django my_site \
  --app-name "My Site" \            # display name (default: project name title-cased)
  --description "..." \             # README + API docs description
  --domain my-site.com \            # production domain (ALLOWED_HOSTS examples)
  --author "Name" --email a@b.com \ # defaults: git config user.name / user.email
  --organization "Acme" \           # copyright holder (default: author)
  -o ~/projects                     # parent directory (default: current directory)

What it does: copies the django_starter template (Django 4.2 + Django Ninja + JWT, Docker/Postgres ready, SQLite fallback for local dev) → renames the {{PROJECT_SLUG}}/ settings package → substitutes all tokens including a freshly generated SECRET_KEY → creates .venv and installs requirements.txt → runs migrations → git init + initial commit. The result passes manage.py check and its own test suite, and serves API docs at /api/v1/docs.

devforge next

devforge next my-web \
  --auth / --no-auth \               # auth module (login/signup, cookie-JWT, axios refresh queue)
  --multi-tenant / --no-multi-tenant # subdomain-per-tenant routing (proxy + [tenant] segment)
  --app-name "My Web" --domain my-web.com \
  --api-url http://127.0.0.1:8000/api/v1 \
  --cookie-prefix mw \               # default: project name initials
  --skip-install \                   # skip npm install
  -o ~/projects

Both features default to no. If the flags are omitted on a terminal, DevForge asks two yes/no questions interactively; in scripts (no TTY) it silently uses the defaults.

What it does: copies the template per its template.json manifest → applies the feature selection (disabled features have files removed and variant overlays applied, so e.g. disabling multi-tenant relocates app/[tenant]/dashboardapp/dashboard) → substitutes tokens → npm installgit init. All four feature combinations produce a project that passes npm run build.

Configuration

Settings resolve in precedence order: environment variables → ./devforge.json~/.config/devforge/config.json → defaults.

Setting Env var Config key Default
Template root DEVFORGE_TEMPLATE_ROOT template_root devforge/templates/ inside the package
Log level DEVFORGE_LOG_LEVEL log_level WARNING

Installation

Full step-by-step guide (all platforms, updating, troubleshooting): docs/installation.md. The short version:

With Python 3.9+ (Windows / macOS / Linux):

pipx install devforge-scaffold   # recommended (isolated); or: pip install devforge-scaffold
devforge --version

Without Python — download the standalone binary for your OS from GitHub Releases (devforge-macos-arm64, devforge-windows-x86_64.exe), put it on your PATH and run it. macOS will quarantine an unsigned download: xattr -d com.apple.quarantine devforge-macos-arm64.

The PyPI distribution is named devforge-scaffold (plain devforge was taken), but the installed command is devforge either way.

For development:

python -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"

Releasing

  1. Bump version in pyproject.toml (and src/devforge/__init__.py).
  2. git tag v0.x.y && git push origin v0.x.y
  3. GitHub Actions (.github/workflows/release.yml) runs the tests, builds the macOS/Windows binaries with PyInstaller (packaging/build_binary.py), attaches them to a GitHub Release, and publishes the wheel to PyPI.

One-time setup for PyPI publishing: create the devforge-scaffold project as a trusted publisher on pypi.org pointing at this repo's release.yml workflow (environment pypi) — no token secrets required.

Project layout

DevForge/
├── pyproject.toml          # packaging, dependencies, `devforge` entry point
├── src/devforge/           # the CLI package (src layout)
│   ├── templates/          # starter templates, shipped as package data
│   │   ├── flutter_starter/  # complete — see its TEMPLATE_REPORT.md
│   │   ├── django_starter/   # complete
│   │   └── nextjs_starter/   # placeholder, to be added
│   ├── cli.py              # Typer app assembly — registers commands, no logic
│   ├── commands/           # one module per CLI command (new, list, doctor)
│   ├── core/               # config, constants, exception hierarchy
│   ├── generators/         # one generator per framework + base interface + registry
│   ├── services/           # shared engines: template substitution, file ops, validation
│   ├── ui/                 # Rich rendering — the only package that imports rich
│   └── utils/              # small dependency-free helpers
├── tests/
│   ├── unit/               # per-module tests mirroring src/devforge
│   └── integration/        # end-to-end `devforge new` runs against real templates
└── docs/
    └── architecture.md     # detailed folder purposes and SOLID mapping

See docs/architecture.md for what each folder is for and why.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

devforge_scaffold-0.1.1.tar.gz (396.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

devforge_scaffold-0.1.1-py3-none-any.whl (440.1 kB view details)

Uploaded Python 3

File details

Details for the file devforge_scaffold-0.1.1.tar.gz.

File metadata

  • Download URL: devforge_scaffold-0.1.1.tar.gz
  • Upload date:
  • Size: 396.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for devforge_scaffold-0.1.1.tar.gz
Algorithm Hash digest
SHA256 2de678c527b4ef3892bc6b83dd2fc309a130e5b2dfbb15f4772d7aa8ddf63ded
MD5 9b5cacb68cd5ba1e24ff772c2e0b0365
BLAKE2b-256 6acbc4eae743c14a85bec9473932cf5f23cc7238fdc4475b13910c771d6cdfe3

See more details on using hashes here.

Provenance

The following attestation bundles were made for devforge_scaffold-0.1.1.tar.gz:

Publisher: release.yml on dhineshio/DevForge

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file devforge_scaffold-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for devforge_scaffold-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 62d0ef13b4801697db66f213be1c08ddddc0aa4abf654aa848f58ecb770b4ec4
MD5 58b4e8deb5e3ae58e3272986cbddb7d0
BLAKE2b-256 1d822001d74ea516c2d8353056dd22b138e59e2b762d11a5db9b7541c7d8f3cf

See more details on using hashes here.

Provenance

The following attestation bundles were made for devforge_scaffold-0.1.1-py3-none-any.whl:

Publisher: release.yml on dhineshio/DevForge

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page