A blog application for Django sites, inspired by classic WordPress.
Project description
DJ Press
A blog application for Django sites, inspired by classic WordPress, available on PyPI.
Warning - very alpha.
Goals
Why build another blog engine? These are my goals...
- Simple to get started with sensible defaults: install plugin, configure
urls.py
, and migrate. - Follows Django patterns: configuration in
settings.py
, content management in the Django admin. - Configurable to suit a wide variety of use-cases: lots of configuration available, but not required.
- Customisable with themes: themes can be written using only template tags, no knowledge of models required.
- Customisable with plugins: simple plugins are easy to write, but complex plugins are possible.
- Powerful but lightweight: provide core functionality, allow plugins to fill gaps and enhance.
Versioning
This package uses semantic versioning, but until we reach version 1.x.x, the following rules will apply:
- MAJOR version will remain on 0 until the base functionality is complete.
- MINOR version indicates that an incompatible or breaking change has been introduced.
- PATCH version indicates a bug fix or a backward compatible change.
If you choose to use this package prior to version 1.x being release, please pin your requirements to a specific minor version, e.g. djpress~=0.16.0
Installation
- Install
djpress
by adding it to your requirements file, e.g.djpress~=0.16.0
(see versioning note, above). - Add it to your
INSTALLED_APPS
in Django:
INSTALLED_APPS = [
# ...
"djpress.apps.DjpressConfig",
# ...
]
- Add the URLs to your project's main
urls.py
file.
The following will set DJ Press to be available at the root of your site, e.g. https://example.com/
from django.urls import path, include
urlpatterns = [
# ...
path("", include("djpress.urls")),
# ...
]
If you want your blog to be in a subdirectory, use something like the following:
from django.urls import path, include
urlpatterns = [
# ...
path("blog/", include("djpress.urls")),
# ...
]
- Run migrations:
python3 manage.py migrate
Note that this relies on the Django Admin for content management, so ensure that you have a user with at least
staff
status to manage content.
Configuration
In your settings.py file, create a DJPRESS_SETTINGS
dictionary. Here are some common settings:
# DJPress settings
DJPRESS_SETTINGS = {
"SITE_TITLE": "My Awesome Blog",
"POST_PREFIX": "{{ year }}/{{ month }}", # blog post URLs are prefixed with "year/month": /2024/10/blog-post-slug/
}
There are lots more settings available. Please check the docs or look at the source code: src/djpress/app_settings.py
Documentation
Documentation is a work-in-progress, but is available on GitHub Pages: https://stuartmaxwell.github.io/djpress
Badges
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file djpress-0.20.2.tar.gz
.
File metadata
- Download URL: djpress-0.20.2.tar.gz
- Upload date:
- Size: 169.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
54a8cfd4fb2ff606e33c4ed6dad7b061185a93759b0f4a904592f0d70d6fb8b3
|
|
MD5 |
ff05328cf6f913e9b5fce9636ed99501
|
|
BLAKE2b-256 |
f49856c8bd0cf66c8f8ba973569c2a736c540f8da2a68a5a0a3d305d6986086d
|
Provenance
The following attestation bundles were made for djpress-0.20.2.tar.gz
:
Publisher:
publish.yml
on stuartmaxwell/djpress
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1
-
Predicate type:
https://docs.pypi.org/attestations/publish/v1
-
Subject name:
djpress-0.20.2.tar.gz
-
Subject digest:
54a8cfd4fb2ff606e33c4ed6dad7b061185a93759b0f4a904592f0d70d6fb8b3
- Sigstore transparency entry: 237131910
- Sigstore integration time:
-
Permalink:
stuartmaxwell/djpress@eb5da4be8bd71751ca02959b095ebfc46b032dda
-
Branch / Tag:
refs/tags/v0.20.2
- Owner: https://github.com/stuartmaxwell
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com
-
Runner Environment:
github-hosted
-
Publication workflow:
publish.yml@eb5da4be8bd71751ca02959b095ebfc46b032dda
-
Trigger Event:
release
-
Statement type:
File details
Details for the file djpress-0.20.2-py3-none-any.whl
.
File metadata
- Download URL: djpress-0.20.2-py3-none-any.whl
- Upload date:
- Size: 74.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
5afbbb842fc8aa9883cd12d251dfd33a02237ebd1ec182801d5d27f8fd729180
|
|
MD5 |
5fd7188a0dac35bcf1727e4a67635d1a
|
|
BLAKE2b-256 |
7997f8acde400f5ae45e6da5eaf2fc938c744277329356081b3e5300624fd1f2
|
Provenance
The following attestation bundles were made for djpress-0.20.2-py3-none-any.whl
:
Publisher:
publish.yml
on stuartmaxwell/djpress
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1
-
Predicate type:
https://docs.pypi.org/attestations/publish/v1
-
Subject name:
djpress-0.20.2-py3-none-any.whl
-
Subject digest:
5afbbb842fc8aa9883cd12d251dfd33a02237ebd1ec182801d5d27f8fd729180
- Sigstore transparency entry: 237131911
- Sigstore integration time:
-
Permalink:
stuartmaxwell/djpress@eb5da4be8bd71751ca02959b095ebfc46b032dda
-
Branch / Tag:
refs/tags/v0.20.2
- Owner: https://github.com/stuartmaxwell
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com
-
Runner Environment:
github-hosted
-
Publication workflow:
publish.yml@eb5da4be8bd71751ca02959b095ebfc46b032dda
-
Trigger Event:
release
-
Statement type: