django-spinproject


Namedjango-spinproject JSON
Version 2.7.0 PyPI version JSON
download
home_pagehttps://github.com/m1kc/django-spinproject
SummaryOpinionated version of `startproject` with some popular third-party packages. Starter pack includes: whitenoise, django-environ, logging, GitHub Scripts to Rule Them All, basic Dockerfile and Makefile.
upload_time2024-03-26 15:22:23
maintainerNone
docs_urlNone
authorm1kc (Max Musatov)
requires_python<4.0,>=3.7
licenseMIT
keywords django django-admin startproject template whitenoise django-environ srta
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # django-spinproject

Opinionated version of `django-admin startproject` that intends to go further and do things that startproject can't do but most people will do anyway. Here's what you can get:

* ⚛️ **Whitenoise**: for serving static files in production (usually you don't want to set up a separate server for this).
* 🔧 **settings.py**: slightly modified to also understand environment variables and `.env` files. This functionality requires the `django-environ` package. Also, app logger is mostly pre-configured for you.
* 🔑 **Minimal login/logout pages** so you can set this up without reading the guide again.
* 🔒 **Support for marking PostgreSQL databases as read-only** to prevent accidental modification of critical data.
* 🧰 `script/bootstrap` and other [scripts to rule them all](https://github.blog/2015-06-30-scripts-to-rule-them-all/) so your fellow developers and maintainers don't ask you how to run this thing. Current versions of these scripts optimized for use with [poetry](https://python-poetry.org/), but you can easily adapt them for any Python package manager.
* 🏗️ **Dockerfile and .dockerignore**: one day your app will go to production, and we've got you covered.
* 🏛️ **Gitlab CI config**.
* ⚕️ **Pre-configured linter** so you can find some common problems automagically.
* 🏃 **Pre-configured pytest** because you are going to need unit tests one day.
* 🗃️ **Auto-checks if you forgot to create migrations** whenever you run tests or CI.
* *️⃣ **.gitignore**: well, you know why.

## Requirements

* \*nix system;
* `django-admin` installed and available from `$PATH`.

Generated files will work fine in Django >= 2.0, not tested in earlier versions.

## How to use

* Install the package: `pip install django-spinproject`
* Create a new project: `django-spinproject --create <path>`
* OR initialize spinproject in your existing project's folder: `django-spinproject --init`

You're all set. Now you can take a look at the list of available modules: `django-spinproject --help`

Use `django-spinproject --enable` to enable a module, `django-spinproject --upgrade` to apply changes.

## CLI commands

* `--create PATH`: create django project in specified path
* `--init`: create spinproject.json file
* `--enable MODULE_TO_ENABLE`: enable specified module; use 'all' to enable most common modules; use 'ALL' to enable all available modules;
* `--disable MODULE_TO_DISABLE`: disable specified module
* `--upgrade [MODULE_TO_UPGRADE]`: upgrade (specified or all) enabled modules

## Available modules

* `gitignore` — Creates `.gitignore` file suitable for most Django projects.
* `srta` — Creates [Scripts to Rule Them All](https://github.blog/2015-06-30-scripts-to-rule-them-all/) (simplifies life a lot, you should check it out).
* `pytest` — Creates `pytest.ini` and `.coveragerc` files.
* `dockerfile` — Creates a Dockerfile.
* `dockerignore` — Creates `.dockerignore` (you should totally do that).
* `docker-scripts` — Creates additional SRTA scripts for building and pushing your Docker image.
* `gitlab-ci` — Creates GitLab CI config, `.gitlab-ci.yml`.
* `pg-readonly` — Creates a DatabaseWrapper class for readonly connection to PostgreSQL.
* `settings` — Improves the default `settings.py`, adding support for envvars and `.env` files. Also enables Whitenoise and CLI logger.
* `login-template` — Creates minimal login/logout pages.

## Planned features

(for requests, create an issue or drop me a line at m1kc@yandex.ru)

## Changelog

See the [Releases](https://github.com/m1kc/django-spinproject/releases) page.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/m1kc/django-spinproject",
    "name": "django-spinproject",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.7",
    "maintainer_email": null,
    "keywords": "django, django-admin, startproject, template, whitenoise, django-environ, SRTA",
    "author": "m1kc (Max Musatov)",
    "author_email": "m1kc@yandex.ru",
    "download_url": "https://files.pythonhosted.org/packages/70/58/19e385e90ac640c4c263fc44ecf6f55b87d70f993f98e132303d8a327b2e/django_spinproject-2.7.0.tar.gz",
    "platform": null,
    "description": "# django-spinproject\n\nOpinionated version of `django-admin startproject` that intends to go further and do things that startproject can't do but most people will do anyway. Here's what you can get:\n\n* \u269b\ufe0f **Whitenoise**: for serving static files in production (usually you don't want to set up a separate server for this).\n* \ud83d\udd27 **settings.py**: slightly modified to also understand environment variables and `.env` files. This functionality requires the `django-environ` package. Also, app logger is mostly pre-configured for you.\n* \ud83d\udd11 **Minimal login/logout pages** so you can set this up without reading the guide again.\n* \ud83d\udd12 **Support for marking PostgreSQL databases as read-only** to prevent accidental modification of critical data.\n* \ud83e\uddf0 `script/bootstrap` and other [scripts to rule them all](https://github.blog/2015-06-30-scripts-to-rule-them-all/) so your fellow developers and maintainers don't ask you how to run this thing. Current versions of these scripts optimized for use with [poetry](https://python-poetry.org/), but you can easily adapt them for any Python package manager.\n* \ud83c\udfd7\ufe0f **Dockerfile and .dockerignore**: one day your app will go to production, and we've got you covered.\n* \ud83c\udfdb\ufe0f **Gitlab CI config**.\n* \u2695\ufe0f **Pre-configured linter** so you can find some common problems automagically.\n* \ud83c\udfc3 **Pre-configured pytest** because you are going to need unit tests one day.\n* \ud83d\uddc3\ufe0f **Auto-checks if you forgot to create migrations** whenever you run tests or CI.\n* *\ufe0f\u20e3 **.gitignore**: well, you know why.\n\n## Requirements\n\n* \\*nix system;\n* `django-admin` installed and available from `$PATH`.\n\nGenerated files will work fine in Django >= 2.0, not tested in earlier versions.\n\n## How to use\n\n* Install the package: `pip install django-spinproject`\n* Create a new project: `django-spinproject --create <path>`\n* OR initialize spinproject in your existing project's folder: `django-spinproject --init`\n\nYou're all set. Now you can take a look at the list of available modules: `django-spinproject --help`\n\nUse `django-spinproject --enable` to enable a module, `django-spinproject --upgrade` to apply changes.\n\n## CLI commands\n\n* `--create PATH`: create django project in specified path\n* `--init`: create spinproject.json file\n* `--enable MODULE_TO_ENABLE`: enable specified module; use 'all' to enable most common modules; use 'ALL' to enable all available modules;\n* `--disable MODULE_TO_DISABLE`: disable specified module\n* `--upgrade [MODULE_TO_UPGRADE]`: upgrade (specified or all) enabled modules\n\n## Available modules\n\n* `gitignore` \u2014 Creates `.gitignore` file suitable for most Django projects.\n* `srta` \u2014 Creates [Scripts to Rule Them All](https://github.blog/2015-06-30-scripts-to-rule-them-all/) (simplifies life a lot, you should check it out).\n* `pytest` \u2014 Creates `pytest.ini` and `.coveragerc` files.\n* `dockerfile` \u2014 Creates a Dockerfile.\n* `dockerignore` \u2014 Creates `.dockerignore` (you should totally do that).\n* `docker-scripts` \u2014 Creates additional SRTA scripts for building and pushing your Docker image.\n* `gitlab-ci` \u2014 Creates GitLab CI config, `.gitlab-ci.yml`.\n* `pg-readonly` \u2014 Creates a DatabaseWrapper class for readonly connection to PostgreSQL.\n* `settings` \u2014 Improves the default `settings.py`, adding support for envvars and `.env` files. Also enables Whitenoise and CLI logger.\n* `login-template` \u2014 Creates minimal login/logout pages.\n\n## Planned features\n\n(for requests, create an issue or drop me a line at m1kc@yandex.ru)\n\n## Changelog\n\nSee the [Releases](https://github.com/m1kc/django-spinproject/releases) page.\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Opinionated version of `startproject` with some popular third-party packages. Starter pack includes: whitenoise, django-environ, logging, GitHub Scripts to Rule Them All, basic Dockerfile and Makefile.",
    "version": "2.7.0",
    "project_urls": {
        "Documentation": "https://github.com/m1kc/django-spinproject",
        "Homepage": "https://github.com/m1kc/django-spinproject",
        "Repository": "https://github.com/m1kc/django-spinproject.git"
    },
    "split_keywords": [
        "django",
        " django-admin",
        " startproject",
        " template",
        " whitenoise",
        " django-environ",
        " srta"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0dde5cacb2a3c97b981165d82ff35c0aa5b037c22c9cc0ad4205d9d13acd2904",
                "md5": "32966ce76004f285f109f4da122d5e83",
                "sha256": "047215c8cf52b58661c38265b2aec3f7a4fd2556a776725c3a083cfbb889bc8d"
            },
            "downloads": -1,
            "filename": "django_spinproject-2.7.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "32966ce76004f285f109f4da122d5e83",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.7",
            "size": 76758,
            "upload_time": "2024-03-26T15:22:21",
            "upload_time_iso_8601": "2024-03-26T15:22:21.246448Z",
            "url": "https://files.pythonhosted.org/packages/0d/de/5cacb2a3c97b981165d82ff35c0aa5b037c22c9cc0ad4205d9d13acd2904/django_spinproject-2.7.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "705819e385e90ac640c4c263fc44ecf6f55b87d70f993f98e132303d8a327b2e",
                "md5": "954c7d263b9a5695ca7fa2c81fe2e5a7",
                "sha256": "927204a1005371060b6d60eabb7b62b32d12c2f2c708264dad757e8760a4e29a"
            },
            "downloads": -1,
            "filename": "django_spinproject-2.7.0.tar.gz",
            "has_sig": false,
            "md5_digest": "954c7d263b9a5695ca7fa2c81fe2e5a7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.7",
            "size": 36989,
            "upload_time": "2024-03-26T15:22:23",
            "upload_time_iso_8601": "2024-03-26T15:22:23.593073Z",
            "url": "https://files.pythonhosted.org/packages/70/58/19e385e90ac640c4c263fc44ecf6f55b87d70f993f98e132303d8a327b2e/django_spinproject-2.7.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-26 15:22:23",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "m1kc",
    "github_project": "django-spinproject",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "django-spinproject"
}
        
Elapsed time: 0.21471s