chore(root): renameproject to config and update configuration files

Enhancements:
- Rename project name from "." to "config" in .djinit and .env.sample
- Update DJANGO_SETTINGS_MODULE references from core to config
- Adjust Procfile, justfile, manage.py, and pyproject.toml to reference config
- Refactor README to reflect new folder layout under config/
- Remove LICENSE file
This commit is contained in:
sankalp committed 2026-05-27 23:18:17 +05:45
1 parent 7196c4a299
commit eedb1f1ab6
8 files changed
+39 -74

No files matched your search

+3 -3
View File
@@ -1,9 +1,9 @@
{
"project_name": ".",
"project_name": "config",
"structure": {
"standard": false,
"standard": true,
"predefined": false,
"unified": true,
"unified": false,
"single": false
},
"apps": {
+2 -2
View File
@@ -1,10 +1,10 @@
# Django settings
DJANGO_SETTINGS_MODULE=core.settings.development
DJANGO_SETTINGS_MODULE=config.settings.development
SECRET_KEY=your-secret-key
ALLOWED_HOSTS=api.your-domain.com,www.your-domain.com
# Database URL (recommended for production)
DATABASE_URL=postgres://user:password@localhost:5432/core
DATABASE_URL=postgres://user:password@localhost:5432/config
# Frontend URL
FRONTEND_URL=https://frontend.your-domain.com,www.frontend.your-domain.com
-28
View File
@@ -1,28 +0,0 @@
BSD 3-Clause License
Copyright (c) 2026, Sankalp Tharu
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of the copyright holder nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+6 -6
View File
@@ -1,20 +1,20 @@
# Procfile for .
# Procfile for config
# Used for deploying to PaaS platforms like Heroku, Railway, Render, etc.
# Web server process (using Gunicorn)
# Adjust workers based on your needs: (2 x CPU cores) + 1
web: gunicorn core.wsgi:application --bind 0.0.0.0:$PORT --workers 2 --timeout 120 --access-logfile - --error-logfile - --log-level info
web: gunicorn config.wsgi:application --bind 0.0.0.0:$PORT --workers 2 --timeout 120 --access-logfile - --error-logfile - --log-level info
# Alternative web server configurations (uncomment to use):
# web: gunicorn core.wsgi:application --bind 0.0.0.0:$PORT --workers 4 --threads 2 --timeout 120
# web: gunicorn core.wsgi:application --bind 0.0.0.0:$PORT --workers 2 --worker-class gevent --worker-connections 1000 --timeout 120
# web: gunicorn config.wsgi:application --bind 0.0.0.0:$PORT --workers 4 --threads 2 --timeout 120
# web: gunicorn config.wsgi:application --bind 0.0.0.0:$PORT --workers 2 --worker-class gevent --worker-connections 1000 --timeout 120
# Release task (runs migrations before deployment)
release: python manage.py migrate --noinput && python manage.py collectstatic --noinput
# Uncomment below to run scheduled tasks (if using Celery)
# worker: celery -A core worker --loglevel=info
# beat: celery -A core beat --loglevel=info
# worker: celery -A config worker --loglevel=info
# beat: celery -A config beat --loglevel=info
# Development server (for local testing with Foreman/Overmind)
# web: python manage.py runserver 0.0.0.0:$PORT
+22 -29
View File
@@ -1,4 +1,4 @@
# .
# config
A Django project folder structure is generated with [djinitx/djinit/dj](https://github.com/S4NKALP/djinit).
@@ -71,45 +71,38 @@ Run `just` to see all available commands, including:
## Project Structure
```
./
├── apps/
│ ├── admin/
│ │ └── __init__.py
│ ├── api/
│ │ ├── __init__.py
│ │ ├── urls.py
│ │ └── v1/
│ │ ├── __init__.py
│ │ └── urls.py
│ ├── models/
│ │ └── __init__.py
│ ├── serializers/
│ │ └── __init__.py
│ ├── tests/
│ │ └── __init__.py
│ ├── urls/
│ │ └── __init__.py
│ └── views/
│ └── __init__.py
├── core/
│ ├── asgi.py
│ ├── __init__.py
config/
├── config/
│ ├── settings/
│ │ ├── base.py
│ │ ├── development.py
│ │ ├── __init__.py
│ │ └── production.py
│ ├── admin/
│ ├── api/ # API endpoints organized by model
│ │ ├── user/ # Example: if you have a User model
│ │ │ ├── views.py
│ │ │ ├── serializers.py
│ │ │ └── urls.py
│ │ └── urls.py
│ ├── models/ # Django models
│ ├── tests/
│ ├── urls.py
│ └── wsgi.py
│ ├── wsgi.py
│ └── asgi.py
├── manage.py
├── requirements.txt
├── pyproject.toml
├── uv.lock
├── .env.sample
├── justfile
├── Procfile
├── runtime.txt
└── README.md
**Note:** For the single folder layout, organize your API endpoints by model name under the `api/` directory.
For example, if you have a `User` model in `models/user.py`, create:
- `api/user/views.py` - API views for User
- `api/user/serializers.py` - Serializers for User
- `api/user/urls.py` - URL patterns for User endpoints
See the README files in `api/` and `models/` directories for more details.
```
## API Documentation
+4 -4
View File
@@ -1,4 +1,4 @@
# Justfile for .
# Justfile for config
# Task runner for Django development
# Install just: https://github.com/casey/just
@@ -118,15 +118,15 @@ dbshell:
# Start production server with gunicorn
server:
uv run gunicorn core.wsgi:application --bind 0.0.0.0:8000
uv run gunicorn config.wsgi:application --bind 0.0.0.0:8000
# Start production server with gunicorn workers
server-prod WORKERS="4":
uv run gunicorn core.wsgi:application --bind 0.0.0.0:8000 --workers {{ WORKERS }}
uv run gunicorn config.wsgi:application --bind 0.0.0.0:8000 --workers {{ WORKERS }}
# Start production server with gunicorn and reload on file changes
server-watch:
uv run gunicorn core.wsgi:application --bind 0.0.0.0:8000 --reload
uv run gunicorn config.wsgi:application --bind 0.0.0.0:8000 --reload
# Clean Python cache files
clean:
+1 -1
View File
@@ -11,7 +11,7 @@ import environ
def main():
"""Run administrative tasks."""
os.environ.setdefault("DJANGO_SETTINGS_MODULE", os.getenv("DJANGO_SETTINGS_MODULE", "core.settings.production"))
os.environ.setdefault("DJANGO_SETTINGS_MODULE", os.getenv("DJANGO_SETTINGS_MODULE", "config.settings.production"))
try:
from django.core.management import execute_from_command_line
+1 -1
View File
@@ -41,4 +41,4 @@ ignore = [
]
[tool.ruff.lint.isort]
known-first-party = ["core"]
known-first-party = ["config"]