django-tailwind-cli 4.4.2__tar.gz → 4.5.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/.github/workflows/release.yml +6 -6
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/.github/workflows/test.yml +2 -2
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/.pre-commit-config.yaml +3 -2
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/.readthedocs.yml +3 -3
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/CHANGELOG.md +16 -1
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/CLAUDE.md +1 -1
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/PKG-INFO +21 -26
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/README.md +19 -20
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/docs/base_template.md +0 -5
- django_tailwind_cli-4.5.0/docs/changelog.md +2 -0
- django_tailwind_cli-4.5.0/docs/conf.py +51 -0
- django_tailwind_cli-4.5.0/docs/development.md +177 -0
- django_tailwind_cli-4.5.0/docs/index.md +15 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/docs/installation.md +0 -5
- django_tailwind_cli-4.5.0/docs/requirements.txt +5 -0
- django_tailwind_cli-4.5.0/docs/settings.md +301 -0
- django_tailwind_cli-4.5.0/docs/template_tags.md +62 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/docs/usage.md +9 -36
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/justfile +18 -1
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/pyproject.toml +1 -5
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/config.py +173 -34
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/management/commands/tailwind.py +165 -56
- django_tailwind_cli-4.5.0/src/django_tailwind_cli/templates/tailwind_cli/tailwind_css.html +9 -0
- django_tailwind_cli-4.5.0/src/django_tailwind_cli/templatetags/tailwind_cli.py +112 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/test_additional_commands.py +3 -2
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/test_config.py +119 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/test_integration.py +125 -0
- django_tailwind_cli-4.5.0/tests/test_tailwind_css_tag.py +95 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tox.ini +0 -9
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/uv.lock +87 -20
- django_tailwind_cli-4.4.2/CONFIGURATION.md +0 -414
- django_tailwind_cli-4.4.2/DEVELOPMENT.md +0 -478
- django_tailwind_cli-4.4.2/docs/changelog.md +0 -6
- django_tailwind_cli-4.4.2/docs/index.md +0 -6
- django_tailwind_cli-4.4.2/docs/requirements.txt +0 -2
- django_tailwind_cli-4.4.2/docs/settings.md +0 -99
- django_tailwind_cli-4.4.2/docs/template_tags.md +0 -35
- django_tailwind_cli-4.4.2/mkdocs.yml +0 -58
- django_tailwind_cli-4.4.2/src/django_tailwind_cli/templates/tailwind_cli/tailwind_css.html +0 -8
- django_tailwind_cli-4.4.2/src/django_tailwind_cli/templatetags/tailwind_cli.py +0 -73
- django_tailwind_cli-4.4.2/tests/test_tailwind_css_tag.py +0 -23
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/.github/dependabot.yml +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/.gitignore +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/CODE_OF_CONDUCT.md +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/LICENSE +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/__init__.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/apps.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/management/__init__.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/management/commands/__init__.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/py.typed +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/templates/tailwind_cli/base.html +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/templatetags/__init__.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/utils/__init__.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/src/django_tailwind_cli/utils/http.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/.gitignore +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/__init__.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/assets/css/.gitkeep +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/assets/css/tailwind.css +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/conftest.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/settings.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/templates/tests/base.html +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/templates/tests/dummy.email +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/test_error_scenarios.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/test_get_runserver_options.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/test_http.py +0 -0
- {django_tailwind_cli-4.4.2 → django_tailwind_cli-4.5.0}/tests/test_management_commands.py +0 -0
|
@@ -14,7 +14,7 @@ jobs:
|
|
|
14
14
|
runs-on: ubuntu-latest
|
|
15
15
|
|
|
16
16
|
steps:
|
|
17
|
-
- uses: actions/checkout@
|
|
17
|
+
- uses: actions/checkout@v6
|
|
18
18
|
- name: Set up Python
|
|
19
19
|
uses: actions/setup-python@v6
|
|
20
20
|
with:
|
|
@@ -25,7 +25,7 @@ jobs:
|
|
|
25
25
|
- name: Build a binary wheel and a source tarball
|
|
26
26
|
run: python3 -m build
|
|
27
27
|
- name: Store the distribution packages
|
|
28
|
-
uses: actions/upload-artifact@
|
|
28
|
+
uses: actions/upload-artifact@v6
|
|
29
29
|
with:
|
|
30
30
|
name: python-package-distributions
|
|
31
31
|
path: dist/
|
|
@@ -44,7 +44,7 @@ jobs:
|
|
|
44
44
|
id-token: write # IMPORTANT: mandatory for trusted publishing
|
|
45
45
|
steps:
|
|
46
46
|
- name: Download all the dists
|
|
47
|
-
uses: actions/download-artifact@
|
|
47
|
+
uses: actions/download-artifact@v7
|
|
48
48
|
with:
|
|
49
49
|
name: python-package-distributions
|
|
50
50
|
path: dist/
|
|
@@ -65,12 +65,12 @@ jobs:
|
|
|
65
65
|
|
|
66
66
|
steps:
|
|
67
67
|
- name: Download all the dists
|
|
68
|
-
uses: actions/download-artifact@
|
|
68
|
+
uses: actions/download-artifact@v7
|
|
69
69
|
with:
|
|
70
70
|
name: python-package-distributions
|
|
71
71
|
path: dist/
|
|
72
72
|
- name: Sign the dists with Sigstore
|
|
73
|
-
uses: sigstore/gh-action-sigstore-python@v3.0
|
|
73
|
+
uses: sigstore/gh-action-sigstore-python@v3.2.0
|
|
74
74
|
with:
|
|
75
75
|
inputs: >-
|
|
76
76
|
./dist/*.tar.gz
|
|
@@ -110,7 +110,7 @@ jobs:
|
|
|
110
110
|
|
|
111
111
|
steps:
|
|
112
112
|
- name: Download all the dists
|
|
113
|
-
uses: actions/download-artifact@
|
|
113
|
+
uses: actions/download-artifact@v7
|
|
114
114
|
with:
|
|
115
115
|
name: python-package-distributions
|
|
116
116
|
path: dist/
|
|
@@ -14,7 +14,7 @@ jobs:
|
|
|
14
14
|
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
|
|
15
15
|
|
|
16
16
|
steps:
|
|
17
|
-
- uses: actions/checkout@
|
|
17
|
+
- uses: actions/checkout@v6
|
|
18
18
|
|
|
19
19
|
- name: Set up Python ${{ matrix.python-version }}
|
|
20
20
|
uses: actions/setup-python@v6
|
|
@@ -23,7 +23,7 @@ jobs:
|
|
|
23
23
|
allow-prereleases: true
|
|
24
24
|
|
|
25
25
|
- name: Install uv
|
|
26
|
-
uses: astral-sh/setup-uv@
|
|
26
|
+
uses: astral-sh/setup-uv@v7
|
|
27
27
|
|
|
28
28
|
- name: Test with tox
|
|
29
29
|
run: uvx --with tox-uv --with tox-gh-actions tox
|
|
@@ -40,11 +40,12 @@ repos:
|
|
|
40
40
|
args: [--target-version, "4.2"]
|
|
41
41
|
|
|
42
42
|
- repo: https://github.com/owenlamont/uv-secure
|
|
43
|
-
rev: 0.
|
|
43
|
+
rev: 0.15.4
|
|
44
44
|
hooks:
|
|
45
45
|
- id: uv-secure
|
|
46
|
+
exclude: ^docs/
|
|
46
47
|
|
|
47
48
|
- repo: https://github.com/RobertCraigie/pyright-python
|
|
48
|
-
rev: v1.1.
|
|
49
|
+
rev: v1.1.407
|
|
49
50
|
hooks:
|
|
50
51
|
- id: pyright
|
|
@@ -7,10 +7,10 @@ build:
|
|
|
7
7
|
tools:
|
|
8
8
|
python: "3.12"
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
configuration:
|
|
10
|
+
sphinx:
|
|
11
|
+
configuration: docs/conf.py
|
|
12
12
|
|
|
13
13
|
# Optionally declare the Python requirements required to build your docs
|
|
14
14
|
python:
|
|
15
15
|
install:
|
|
16
|
-
|
|
16
|
+
- requirements: docs/requirements.txt
|
|
@@ -1,6 +1,21 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
##
|
|
3
|
+
## 4.5.0 (2025-12-29)
|
|
4
|
+
|
|
5
|
+
### 🎯 New Features
|
|
6
|
+
- **Multiple CSS entry points**: Added `TAILWIND_CLI_CSS_MAP` setting for compiling multiple CSS files in a single project (e.g., separate admin and frontend styles)
|
|
7
|
+
- **Template tag enhancement**: `{% tailwind_css %}` now supports optional name parameter for multi-file mode: `{% tailwind_css "admin" %}`
|
|
8
|
+
|
|
9
|
+
### 🔧 Technical Improvements
|
|
10
|
+
- **Django support**: Dropped support for Django 5.1 (now supporting Django 4.2 LTS, 5.2, and 6.0 only)
|
|
11
|
+
- **Pre-commit hooks**: Updated uv-secure (0.15.4) and pyright (1.1.407)
|
|
12
|
+
- **Security**: Updated Django and Werkzeug to fix security vulnerabilities
|
|
13
|
+
- **Documentation**: Migrated from MkDocs to Sphinx with myst-parser and Furo theme
|
|
14
|
+
- **Template tag consistency**: Template tag now uses Config class for consistent validation
|
|
15
|
+
- **Test coverage**: Added integration tests for multi-file build and watch commands
|
|
16
|
+
|
|
17
|
+
### 🛠️ Developer Experience
|
|
18
|
+
- **Cleanup command**: Added `just clean` target to remove temporary files and build artifacts
|
|
4
19
|
|
|
5
20
|
## 4.4.2 (2025-09-23)
|
|
6
21
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: django-tailwind-cli
|
|
3
|
-
Version: 4.
|
|
3
|
+
Version: 4.5.0
|
|
4
4
|
Summary: Django and Tailwind integration based on the prebuilt Tailwind CSS CLI.
|
|
5
5
|
Project-URL: Home, https://django-tailwind-cli.rtfd.io/
|
|
6
6
|
Project-URL: Documentation, https://django-tailwind-cli.rtfd.io/
|
|
@@ -28,11 +28,7 @@ License-File: LICENSE
|
|
|
28
28
|
Keywords: css,django,tailwind
|
|
29
29
|
Classifier: Development Status :: 5 - Production/Stable
|
|
30
30
|
Classifier: Environment :: Web Environment
|
|
31
|
-
Classifier: Framework :: Django :: 4.0
|
|
32
|
-
Classifier: Framework :: Django :: 4.1
|
|
33
31
|
Classifier: Framework :: Django :: 4.2
|
|
34
|
-
Classifier: Framework :: Django :: 5.0
|
|
35
|
-
Classifier: Framework :: Django :: 5.1
|
|
36
32
|
Classifier: Framework :: Django :: 5.2
|
|
37
33
|
Classifier: Framework :: Django :: 6.0
|
|
38
34
|
Classifier: Intended Audience :: Developers
|
|
@@ -46,8 +42,8 @@ Classifier: Programming Language :: Python :: 3.14
|
|
|
46
42
|
Classifier: Topic :: Software Development :: Libraries
|
|
47
43
|
Classifier: Topic :: Utilities
|
|
48
44
|
Requires-Python: >=3.10
|
|
45
|
+
Requires-Dist: django!=5.0.*,!=5.1.*,>=4.2
|
|
49
46
|
Requires-Dist: django-typer>=2.1.2
|
|
50
|
-
Requires-Dist: django>=4.0
|
|
51
47
|
Requires-Dist: semver>=3.0.4
|
|
52
48
|
Provides-Extra: django-extensions
|
|
53
49
|
Requires-Dist: django-extensions>=3.2; extra == 'django-extensions'
|
|
@@ -56,23 +52,22 @@ Description-Content-Type: text/markdown
|
|
|
56
52
|
|
|
57
53
|
# django-tailwind-cli
|
|
58
54
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
55
|
+
<p style="display: flex; gap: 4px; flex-wrap: wrap; align-items: flex-start; line-height: 1;">
|
|
56
|
+
<img style="height: auto;" alt="GitHub Workflow Status" src="https://img.shields.io/github/actions/workflow/status/django-commons/django-tailwind-cli/test.yml">
|
|
57
|
+
<a style="display: inline-block;" href="https://pypi.org/project/django-tailwind-cli/"><img style="height: auto;" alt="PyPI" src="https://img.shields.io/pypi/v/django-tailwind-cli.svg"></a>
|
|
58
|
+
<a style="display: inline-block;" href="https://github.com/astral-sh/ruff"><img style="height: auto;" alt="Ruff" src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json"></a>
|
|
59
|
+
<a style="display: inline-block;" href="https://github.com/astral-sh/uv"><img style="height: auto;" alt="uv" src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/uv/main/assets/badge/v0.json"></a>
|
|
60
|
+
<img style="height: auto;" alt="GitHub" src="https://img.shields.io/github/license/django-commons/django-tailwind-cli">
|
|
61
|
+
<img style="height: auto;" alt="Django Versions" src="https://img.shields.io/pypi/frameworkversions/django/django-tailwind-cli">
|
|
62
|
+
<img style="height: auto;" alt="Python Versions" src="https://img.shields.io/pypi/pyversions/django-tailwind-cli">
|
|
63
|
+
<a style="display: inline-block;" href="https://pepy.tech/project/django-tailwind-cli"><img style="height: auto;" alt="Downloads" src="https://static.pepy.tech/badge/django-tailwind-cli"></a>
|
|
64
|
+
<a style="display: inline-block;" href="https://pepy.tech/project/django-tailwind-cli"><img style="height: auto;" alt="Downloads / Month" src="https://pepy.tech/badge/django-tailwind-cli/month"></a>
|
|
65
|
+
</p>
|
|
68
66
|
|
|
69
67
|
**The simplest way to integrate Tailwind CSS with Django** ⚡
|
|
70
68
|
|
|
71
69
|
No Node.js required! This library provides seamless [Tailwind CSS](https://tailwindcss.com) integration for Django using the standalone [Tailwind CSS CLI](https://tailwindcss.com/blog/standalone-cli). Inspired by the [Tailwind integration for Phoenix](https://github.com/phoenixframework/tailwind), it eliminates the need for Node.js in your Django development workflow.
|
|
72
70
|
|
|
73
|
-
> [!WARNING]
|
|
74
|
-
> **Version Compatibility:** 4.2.x+ supports Tailwind CSS 4.x only. For Tailwind CSS 3.x, use version 2.21.1.
|
|
75
|
-
|
|
76
71
|
## ✨ Why django-tailwind-cli?
|
|
77
72
|
|
|
78
73
|
- **🚀 Zero Node.js dependency** - No npm, webpack, or build tools required
|
|
@@ -204,14 +199,14 @@ Start adding Tailwind classes to your templates:
|
|
|
204
199
|
|
|
205
200
|
### 🛠️ Management Commands
|
|
206
201
|
|
|
207
|
-
| Command
|
|
208
|
-
|
|
209
|
-
| `setup`
|
|
210
|
-
| `build`
|
|
211
|
-
| `watch`
|
|
212
|
-
| `runserver`
|
|
213
|
-
| `config`
|
|
214
|
-
| `troubleshoot` | Debug common issues
|
|
202
|
+
| Command | Purpose | Example |
|
|
203
|
+
| -------------- | -------------------------- | ---------------------------------------- |
|
|
204
|
+
| `setup` | Interactive setup guide | `python manage.py tailwind setup` |
|
|
205
|
+
| `build` | Production CSS build | `python manage.py tailwind build` |
|
|
206
|
+
| `watch` | Development file watcher | `python manage.py tailwind watch` |
|
|
207
|
+
| `runserver` | Combined server + watcher | `python manage.py tailwind runserver` |
|
|
208
|
+
| `config` | Show current configuration | `python manage.py tailwind config` |
|
|
209
|
+
| `troubleshoot` | Debug common issues | `python manage.py tailwind troubleshoot` |
|
|
215
210
|
|
|
216
211
|
## 📋 Requirements
|
|
217
212
|
|
|
@@ -1,22 +1,21 @@
|
|
|
1
1
|
# django-tailwind-cli
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
3
|
+
<p style="display: flex; gap: 4px; flex-wrap: wrap; align-items: flex-start; line-height: 1;">
|
|
4
|
+
<img style="height: auto;" alt="GitHub Workflow Status" src="https://img.shields.io/github/actions/workflow/status/django-commons/django-tailwind-cli/test.yml">
|
|
5
|
+
<a style="display: inline-block;" href="https://pypi.org/project/django-tailwind-cli/"><img style="height: auto;" alt="PyPI" src="https://img.shields.io/pypi/v/django-tailwind-cli.svg"></a>
|
|
6
|
+
<a style="display: inline-block;" href="https://github.com/astral-sh/ruff"><img style="height: auto;" alt="Ruff" src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json"></a>
|
|
7
|
+
<a style="display: inline-block;" href="https://github.com/astral-sh/uv"><img style="height: auto;" alt="uv" src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/uv/main/assets/badge/v0.json"></a>
|
|
8
|
+
<img style="height: auto;" alt="GitHub" src="https://img.shields.io/github/license/django-commons/django-tailwind-cli">
|
|
9
|
+
<img style="height: auto;" alt="Django Versions" src="https://img.shields.io/pypi/frameworkversions/django/django-tailwind-cli">
|
|
10
|
+
<img style="height: auto;" alt="Python Versions" src="https://img.shields.io/pypi/pyversions/django-tailwind-cli">
|
|
11
|
+
<a style="display: inline-block;" href="https://pepy.tech/project/django-tailwind-cli"><img style="height: auto;" alt="Downloads" src="https://static.pepy.tech/badge/django-tailwind-cli"></a>
|
|
12
|
+
<a style="display: inline-block;" href="https://pepy.tech/project/django-tailwind-cli"><img style="height: auto;" alt="Downloads / Month" src="https://pepy.tech/badge/django-tailwind-cli/month"></a>
|
|
13
|
+
</p>
|
|
12
14
|
|
|
13
15
|
**The simplest way to integrate Tailwind CSS with Django** ⚡
|
|
14
16
|
|
|
15
17
|
No Node.js required! This library provides seamless [Tailwind CSS](https://tailwindcss.com) integration for Django using the standalone [Tailwind CSS CLI](https://tailwindcss.com/blog/standalone-cli). Inspired by the [Tailwind integration for Phoenix](https://github.com/phoenixframework/tailwind), it eliminates the need for Node.js in your Django development workflow.
|
|
16
18
|
|
|
17
|
-
> [!WARNING]
|
|
18
|
-
> **Version Compatibility:** 4.2.x+ supports Tailwind CSS 4.x only. For Tailwind CSS 3.x, use version 2.21.1.
|
|
19
|
-
|
|
20
19
|
## ✨ Why django-tailwind-cli?
|
|
21
20
|
|
|
22
21
|
- **🚀 Zero Node.js dependency** - No npm, webpack, or build tools required
|
|
@@ -148,14 +147,14 @@ Start adding Tailwind classes to your templates:
|
|
|
148
147
|
|
|
149
148
|
### 🛠️ Management Commands
|
|
150
149
|
|
|
151
|
-
| Command
|
|
152
|
-
|
|
153
|
-
| `setup`
|
|
154
|
-
| `build`
|
|
155
|
-
| `watch`
|
|
156
|
-
| `runserver`
|
|
157
|
-
| `config`
|
|
158
|
-
| `troubleshoot` | Debug common issues
|
|
150
|
+
| Command | Purpose | Example |
|
|
151
|
+
| -------------- | -------------------------- | ---------------------------------------- |
|
|
152
|
+
| `setup` | Interactive setup guide | `python manage.py tailwind setup` |
|
|
153
|
+
| `build` | Production CSS build | `python manage.py tailwind build` |
|
|
154
|
+
| `watch` | Development file watcher | `python manage.py tailwind watch` |
|
|
155
|
+
| `runserver` | Combined server + watcher | `python manage.py tailwind runserver` |
|
|
156
|
+
| `config` | Show current configuration | `python manage.py tailwind config` |
|
|
157
|
+
| `troubleshoot` | Debug common issues | `python manage.py tailwind troubleshoot` |
|
|
159
158
|
|
|
160
159
|
## 📋 Requirements
|
|
161
160
|
|
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
---
|
|
2
|
-
hide:
|
|
3
|
-
- navigation
|
|
4
|
-
---
|
|
5
|
-
|
|
6
1
|
# Base Template
|
|
7
2
|
|
|
8
3
|
The package also includes a minimal base template, which you can use as a starting point for your own project. It is a very simple template, which only includes the CSS stylesheets and the `tailwind_css` template tag. You can use by putting `{% extends "tailwind_cli/base.html" %}` into your template files.
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
# Configuration file for the Sphinx documentation builder.
|
|
2
|
+
#
|
|
3
|
+
# For the full list of built-in configuration values, see the documentation:
|
|
4
|
+
# https://www.sphinx-doc.org/en/master/usage/configuration.html
|
|
5
|
+
|
|
6
|
+
# -- Project information -----------------------------------------------------
|
|
7
|
+
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
|
|
8
|
+
|
|
9
|
+
project = "django-tailwind-cli"
|
|
10
|
+
copyright = "2023, Oliver Andrich" # noqa: A001
|
|
11
|
+
author = "Oliver Andrich"
|
|
12
|
+
|
|
13
|
+
# -- General configuration ---------------------------------------------------
|
|
14
|
+
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
|
|
15
|
+
|
|
16
|
+
extensions = [
|
|
17
|
+
"myst_parser",
|
|
18
|
+
"sphinx_copybutton",
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
templates_path = ["_templates"]
|
|
22
|
+
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
|
|
23
|
+
|
|
24
|
+
# -- Options for HTML output -------------------------------------------------
|
|
25
|
+
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output
|
|
26
|
+
|
|
27
|
+
html_theme = "furo"
|
|
28
|
+
html_title = "django-tailwind-cli"
|
|
29
|
+
html_static_path = []
|
|
30
|
+
|
|
31
|
+
html_theme_options = {
|
|
32
|
+
"source_repository": "https://github.com/django-commons/django-tailwind-cli",
|
|
33
|
+
"source_branch": "main",
|
|
34
|
+
"source_directory": "docs/",
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
# -- MyST configuration ------------------------------------------------------
|
|
38
|
+
# https://myst-parser.readthedocs.io/en/latest/configuration.html
|
|
39
|
+
|
|
40
|
+
myst_enable_extensions = [
|
|
41
|
+
"colon_fence",
|
|
42
|
+
"deflist",
|
|
43
|
+
"fieldlist",
|
|
44
|
+
"substitution",
|
|
45
|
+
]
|
|
46
|
+
|
|
47
|
+
# Allow .md files to be parsed
|
|
48
|
+
source_suffix = {
|
|
49
|
+
".rst": "restructuredtext",
|
|
50
|
+
".md": "markdown",
|
|
51
|
+
}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
# Development Workflow
|
|
2
|
+
|
|
3
|
+
This guide covers development workflows for django-tailwind-cli.
|
|
4
|
+
|
|
5
|
+
## Initial Setup
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
# Step 1: Install and configure
|
|
9
|
+
pip install django-tailwind-cli
|
|
10
|
+
python manage.py tailwind setup # Interactive setup
|
|
11
|
+
|
|
12
|
+
# Step 2: Verify configuration
|
|
13
|
+
python manage.py tailwind config
|
|
14
|
+
|
|
15
|
+
# Step 3: Start development
|
|
16
|
+
python manage.py tailwind runserver
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## Daily Development
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
# Morning startup
|
|
23
|
+
python manage.py tailwind runserver # Starts both Django and Tailwind
|
|
24
|
+
|
|
25
|
+
# Alternative: Separate terminals
|
|
26
|
+
python manage.py tailwind watch # Terminal 1: CSS watching
|
|
27
|
+
python manage.py runserver # Terminal 2: Django server
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Template Development
|
|
31
|
+
|
|
32
|
+
1. **Create/Edit Template**
|
|
33
|
+
|
|
34
|
+
```htmldjango
|
|
35
|
+
<!-- templates/myapp/page.html -->
|
|
36
|
+
{% extends "base.html" %}
|
|
37
|
+
|
|
38
|
+
{% block content %}
|
|
39
|
+
<div class="max-w-4xl mx-auto p-6">
|
|
40
|
+
<h1 class="text-3xl font-bold text-gray-900">New Page</h1>
|
|
41
|
+
</div>
|
|
42
|
+
{% endblock %}
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
2. **Verify Template Scanning**
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
python manage.py tailwind list_templates --verbose
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
3. **Build and Test**
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
# CSS rebuilds automatically with watch mode
|
|
55
|
+
# Or manually: python manage.py tailwind build
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
## IDE Integration
|
|
59
|
+
|
|
60
|
+
### VS Code Setup
|
|
61
|
+
|
|
62
|
+
1. **Install Extensions:**
|
|
63
|
+
- Tailwind CSS IntelliSense
|
|
64
|
+
- Django Template
|
|
65
|
+
- Python
|
|
66
|
+
|
|
67
|
+
2. **Workspace Settings:**
|
|
68
|
+
|
|
69
|
+
```json
|
|
70
|
+
// .vscode/settings.json
|
|
71
|
+
{
|
|
72
|
+
"tailwindCSS.includeLanguages": {
|
|
73
|
+
"django-html": "html"
|
|
74
|
+
},
|
|
75
|
+
"tailwindCSS.files.exclude": [
|
|
76
|
+
"**/.git/**",
|
|
77
|
+
"**/node_modules/**"
|
|
78
|
+
],
|
|
79
|
+
"files.associations": {
|
|
80
|
+
"*.html": "django-html"
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
3. **Tasks Configuration:**
|
|
86
|
+
|
|
87
|
+
```json
|
|
88
|
+
// .vscode/tasks.json
|
|
89
|
+
{
|
|
90
|
+
"version": "2.0.0",
|
|
91
|
+
"tasks": [
|
|
92
|
+
{
|
|
93
|
+
"label": "Tailwind Runserver",
|
|
94
|
+
"type": "shell",
|
|
95
|
+
"command": "python",
|
|
96
|
+
"args": ["manage.py", "tailwind", "runserver"],
|
|
97
|
+
"group": "build",
|
|
98
|
+
"isBackground": true
|
|
99
|
+
}
|
|
100
|
+
]
|
|
101
|
+
}
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
### PyCharm Setup
|
|
105
|
+
|
|
106
|
+
1. **Run Configurations:**
|
|
107
|
+
- Name: Tailwind Watch
|
|
108
|
+
- Script: manage.py
|
|
109
|
+
- Parameters: tailwind watch
|
|
110
|
+
- Environment: Development
|
|
111
|
+
|
|
112
|
+
2. **File Watchers:**
|
|
113
|
+
- File type: Django Template
|
|
114
|
+
- Scope: Project Files
|
|
115
|
+
- Program: python
|
|
116
|
+
- Arguments: manage.py tailwind build
|
|
117
|
+
|
|
118
|
+
## Troubleshooting Checklist
|
|
119
|
+
|
|
120
|
+
### Before Asking for Help
|
|
121
|
+
|
|
122
|
+
1. **Check Configuration:**
|
|
123
|
+
|
|
124
|
+
```bash
|
|
125
|
+
python manage.py tailwind config
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
2. **Verify Template Scanning:**
|
|
129
|
+
|
|
130
|
+
```bash
|
|
131
|
+
python manage.py tailwind list_templates --verbose
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
3. **Test CLI Functionality:**
|
|
135
|
+
|
|
136
|
+
```bash
|
|
137
|
+
python manage.py tailwind download_cli
|
|
138
|
+
python manage.py tailwind build --verbose
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
4. **Run Diagnostics:**
|
|
142
|
+
|
|
143
|
+
```bash
|
|
144
|
+
python manage.py tailwind troubleshoot
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
5. **Check System Requirements:**
|
|
148
|
+
- Python 3.10+
|
|
149
|
+
- Django 4.2+
|
|
150
|
+
- Sufficient disk space
|
|
151
|
+
- Network access for CLI download
|
|
152
|
+
|
|
153
|
+
### Information to Include in Bug Reports
|
|
154
|
+
|
|
155
|
+
```text
|
|
156
|
+
Environment:
|
|
157
|
+
- OS: [macOS/Linux/Windows version]
|
|
158
|
+
- Python: [version]
|
|
159
|
+
- Django: [version]
|
|
160
|
+
- django-tailwind-cli: [version]
|
|
161
|
+
|
|
162
|
+
Configuration:
|
|
163
|
+
- STATICFILES_DIRS: [value]
|
|
164
|
+
- TAILWIND_CLI_VERSION: [value]
|
|
165
|
+
- Custom settings: [list any custom Tailwind settings]
|
|
166
|
+
|
|
167
|
+
Command Output:
|
|
168
|
+
[Paste output from python manage.py tailwind config]
|
|
169
|
+
|
|
170
|
+
Error Message:
|
|
171
|
+
[Full error message and traceback]
|
|
172
|
+
|
|
173
|
+
Steps to Reproduce:
|
|
174
|
+
1. [First step]
|
|
175
|
+
2. [Second step]
|
|
176
|
+
3. [etc.]
|
|
177
|
+
```
|