djx-cli — Django Express
Convention over configuration for Django. Inspired by Ruby on Rails.
3 commands. Full CRUD app. No boilerplate.
pip install djx-cli
djx new myblog && cd myblog
djx scaffold Post title:string content:text published:boolean
python manage.py migrate && python manage.py runserver
# → http://127.0.0.1:8000/posts/ — list, create, edit, delete. Done.
Why DJX?
Django is powerful but verbose. Starting a new feature means manually creating models, views, templates, URLs, and wiring them together. DJX does all of that in one command — the same way Rails has done it for 20 years.
| Task | Django | DJX |
|---|---|---|
| New project | django-admin startproject + manual venv + settings |
djx new myproject |
| New CRUD feature | model + views + urls + templates (manual) | djx scaffold Post title:string |
| See all routes | no built-in command | djx routes |
| Remove a feature | delete files manually | djx destroy scaffold Post |
Installation
pip install djx-cli
Requires Python 3.8+ and works with Django 4.2+.
Quick Start
# 1. Create a new project — venv, Django, git, migrations all automatic
djx new myblog
cd myblog
source venv/bin/activate # Linux/Mac
# venv\Scripts\activate # Windows
# 2. Scaffold a full CRUD feature
djx scaffold Post title:string content:text published:boolean
# 3. Run migrations and start server
python manage.py makemigrations && python manage.py migrate
python manage.py runserver
Visit http://127.0.0.1:8000/posts/ — you have a working list, create, edit, and delete. No code written.
Commands
djx new <project>
Create a new Django project with everything configured.
djx new myproject
Creates: Django project, git repository, README, initial migrations. Asks if you want a virtual environment created automatically.
djx scaffold <Model> <fields>
Generate a complete CRUD feature — model, views, templates, and URLs all wired together.
djx scaffold Post title:string content:text published:boolean
djx scaffold Comment body:text author:string post:references:Post
Generates:
posts/models.py— model with all fieldsposts/views.py— ListView, DetailView, CreateView, UpdateView, DeleteViewposts/templates/posts/— list, detail, form, confirm_delete templatesposts/urls.py— all routes- Wired into project
urls.pyautomatically - Added to
INSTALLED_APPSautomatically
djx model <Model> <fields>
Generate a model only (no views or templates).
djx model Article title:string body:text author:string
djx controller <Model>
Generate views and templates for an existing model.
djx controller Post
djx destroy <type> <Model>
Clean removal of a scaffold, model, or controller.
djx destroy scaffold Post # removes app, URLs, INSTALLED_APPS entry
djx destroy model Post # removes model only
djx destroy controller Post # removes views and templates only
djx routes
Display all registered URL routes in a clean table.
djx routes
📍 Routes
URL Pattern Name View
=====================================================
posts/ post-list ListView
posts/<int:pk>/ post-detail DetailView
posts/new/ post-create CreateView
posts/<int:pk>/edit/ post-update UpdateView
posts/<int:pk>/delete/ post-delete DeleteView
✓ Total routes: 28
djx db
Shortcut for the most common database workflow.
djx db # makemigrations + migrate in one command
djx db reset # flush + migrate (wipe and rebuild)
djx console
Django shell with all your models already imported — no manual imports needed.
djx console
# ✓ Models loaded: Post, Comment, User
# >>> Post.objects.all()
djx add <package>
Install a package and add it to INSTALLED_APPS automatically.
djx add django-crispy-forms
djx add djangorestframework
djx config <KEY> <value>
Set a value in settings.py from the terminal.
djx config DEBUG False
djx config ALLOWED_HOSTS '["*"]'
djx wire <app>
Manually wire an app's URLs into the project urls.py.
djx wire posts
Field Types
| DJX type | Django field |
|---|---|
string |
CharField(max_length=200) |
text |
TextField() |
integer |
IntegerField() |
boolean |
BooleanField() |
date |
DateField() |
datetime |
DateTimeField() |
decimal |
DecimalField() |
email |
EmailField() |
url |
URLField() |
references:Model |
ForeignKey(Model) |
Project Structure
After djx new myblog && djx scaffold Post title:string content:text:
myblog/
├── manage.py
├── README.md
├── myblog/
│ ├── settings.py
│ └── urls.py
└── posts/
├── models.py
├── views.py
├── urls.py
├── migrations/
└── templates/
└── posts/
├── post_list.html
├── post_detail.html
├── post_form.html
└── post_confirm_delete.html
Conventions
DJX follows these conventions so you don't have to think about them:
- App name is the pluralized, lowercased model name (
Post→posts) - Templates follow
app/model_action.htmlpattern - URLs follow RESTful patterns (
/posts/,/posts/new/,/posts/1/edit/) - All models get
created_atandupdated_atautomatically - Apps are auto-added to
INSTALLED_APPS - URLs are auto-wired to the project
urls.py
Contributing
Contributions are welcome! DJX is early-stage and there's a lot to build.
git clone https://github.com/RedsonNgwira/djx-cli.git
cd djx-cli
pip install -e .
djx --help
See CONTRIBUTING.md for guidelines.
Ideas for contributions:
djx console— Django shell with all models auto-importeddjx generate api— DRF REST API scaffolddjx server— runserver with better defaultsdjx db migrate— shortcut for makemigrations + migrate- Windows compatibility improvements
- More field types
License
MIT — see LICENSE.
Built with ❤️ from Malawi 🇲🇼 by Redson Ngwira
Metadata
Release files for djx-cli 0.1.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| djx_cli-0.1.9.tar.gz | 16.8 kB | Without provenance | Details for djx_cli-0.1.9.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| djx_cli-0.1.9-py3-none-any.whl | Python 3 | none | any | Details for djx_cli-0.1.9-py3-none-any.whl |
Total release size: 34.9 kB
Release files / djx_cli-0.1.9.tar.gz
| Download URL | djx_cli-0.1.9.tar.gz |
|---|---|
| Size | 16.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e954ea23fafa856dbdc44cd8b10550eb2af6c5039aa06144d5b52c22693ff900
|
|
BLAKE2b-256 checksum How to use checksums |
5aecee9214a168fa1dda69fc419c88725b3ac817accd925ea9cb00aa3fb89389
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.11
|
Release files / djx_cli-0.1.9-py3-none-any.whl
| Download URL | djx_cli-0.1.9-py3-none-any.whl |
|---|---|
| Size | 18.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
394f70746df856da652366b4c6e15667bc2442375cbdc2e82c892ca99fbcc8a5
|
|
BLAKE2b-256 checksum How to use checksums |
f0b51a1d9226b48e9e86a5ec3dd37b198ee68aa6b081cde2ae1aebd82b012450
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.11
|
Security for djx-cli 0.1.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.