Skip to main content

CLI tool to install and add packages to Django in INSTALLED_APPS

Project description

django-include-apps

=====================================

PyPI version Downloads License

django-include-apps is a CLI tool to help you manage Django apps in the INSTALLED_APPS list in your Django project's settings.py file. This tool simplifies the process of adding new apps by ensuring they are properly installed and integrated into your Django project.

Features

  • Automatically search for settings.py in the current or specified directory.
  • Check if the package is installed; if not, prompt the user to install it.
  • Verify if the package is related to Django before adding it to INSTALLED_APPS.
  • Only Add the new app to the INSTALLED_APPS list if it's not already present.

Installation.

You can install django-include-apps via pip:

pip install django-include-apps

Usage

Basic Command

To add a new app to INSTALLED_APPS, use the following command:

django-include-apps add_app <new_app>

Replace <new_app> with the name of the Django app you want to add.

Project Link

For more details, visit the PyPI project page

Options:

Use --start-dir or -d to specify the directory to search for settings.py. Defaults to the current directory if not provided.

Examples:

Example 1: settings.py in the Current Directory

Suppose your Django project's settings.py file is in the current working directory. Navigate to your project directory:

cd /path/to/your/django/project

Run the CLI command to add a new app:

django-include-apps add_app my_new_app

Example 2: settings.py in a Different Directory

Suppose your Django project's settings.py file is in a different directory, such as /path/to/your/django/project/config. Navigate to your desired starting directory:

cd /path/to/your/django/project

Run the CLI command with the --start-dir or -d option:

django-include-apps add_app my_new_app --start-dir ./config

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

django_include_apps-0.1.1.tar.gz (4.9 kB view details)

Uploaded Source

Built Distribution

django_include_apps-0.1.1-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: django_include_apps-0.1.1.tar.gz
  • Upload date:
  • Size: 4.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.3

File hashes

Hashes for django_include_apps-0.1.1.tar.gz
Algorithm Hash digest
SHA256 f8ffaa98cddbf4f45b6cf62ca0b4e72e20047614a0b2348e7c267f8909847b07
MD5 8f09b84a79fb0e54ef8bce115f274960
BLAKE2b-256 ebcfb7eb2f804cab604279678bce4bc844c3d526aab711bb7eb1ebdd10e58b47

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for django_include_apps-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8e66ced13541f69f1f53729de8e3c6f1d2361e136b15249ca11a8bd63d5fe23d
MD5 a5265b69fb42384866278818b31bd379
BLAKE2b-256 cdb980255f331e65f023fc130ba5c1eb25b640bbb995389ddda69589eca251a7

See more details on using hashes here.

Supported by

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