Package: django-cradmin
Django cradminDjango custom role based admin UI.Django cradmin is in BETA. The system is fairly stable, but:We do not have getting started guides.We should have better tests before release. Some parts have been prototyped
a lot while we tested out different concepts, and they need a complexity
review and better tests.Works with Django 4 and python >=3.8,<3.11DevelopRequires:https://github.com/pyenv/pyenvUse conventional commits for GIT commit messagesSeehttps://www.conventionalcommits.org/en/v1.0.0/.
You can use this git commit message format in many different ways, but the easiest is:Use commitizen:https://commitizen-tools.github.io/commitizen/commit/Use an editor extension, likehttps://marketplace.visualstudio.com/items?itemName=vivaxy.vscode-conventional-commitsfor VScode.Just learn to write the format by hand (can be error prone to begin with, but it is fairly easy to learn).Install hatch and commitizenNOTE: You only need hatch if you need to build releases, and you
only need commitizen for releases OR to make it easy to follow
conventional commits for your commit messages
(seeUse conventional commits for GIT commit messagesabove).First install pipx with:brewinstallpipx
pipxensurepathThen install hatch and commitizen:pipxinstallhatchpipxinstallcommitizenSeehttps://github.com/pypa/pipx,https://hatch.pypa.io/latest/install/andhttps://commitizen-tools.github.io/commitizen/for more install alternatives if
needed, but we really recommend using pipx since that is isolated.Install development dependenciesInstall a local python version with pyenv:pyenvinstall3.10
pyenvlocal3.10Create virtualenv./tools/recreate-virtualenv.shAlternatively, create virtualenv manually (this does the same as recreate-virtualenv.sh):python-mvenv.venvthe ./tools/recreate-virtualenv.sh script is just here to make creating virtualenvs more uniform
across different repos because some repos will require extra setup in the virtualenv
for package authentication etc.Install dependenciessource.venv/bin/activate
pipinstall-e".[dev, test]"# install dependencies in virtualenv without "activate".venv/bin/pipinstall-e".[dev,test]"Run dev serversource.venv/bin/activate# enable virtualenvievvdevrunRun testssource.venv/bin/activate# enable virtualenvpytestdjango_cradminBuild css/javascript:source.venv/bin/activate# enable virtualenvnvmuse14# May need to run "nvm install 14" firstievvbuildstatic# ... or if you want to watch for changes ...:ievvbuildstatic--watchDocshttp://django-cradmin.readthedocs.orgLicense3-clause BSD license. See the LICENSE file in the same directory as this readme file.How to release django_cradminFirst make sure you have NO UNCOMITTED CHANGES!BuildstaticRemove the previous built static files:gitrm-rdjango_cradmin/apps/django_cradmin_js/static/django_cradmin_js/django_cradmin/apps/django_cradmin_styles/static/django_cradmin_styles/Bump version and add changelogczbump--files-only--changelogBuild static filesCreate new production static files$nvmuse14# May need to run "nvm install 14" firstievvbuildstatic--productionCommit thNB: Make sure yougitaddpyproject.tomldjango_cradmin/__init__.pydjango_cradmin/apps/django_cradmin_js/static/django_cradmin_js/django_cradmin/apps/django_cradmin_styles/static/django_cradmin_styles/
gitstatus# ... make sure there are no more files that need to be added ...gitcommit-m"bump:$(czversion--project)"Commit with the messagerefactor(buildstatic): new versionMake tag and pushCreate tag with the current versiongittag$(czversion--project)gitpush&&gitpush--tagsWhat if the release fails?SeeHow to revert a bumpin thecommitizen FAQ.Release to pypi:hatchbuild-tsdist
hatchpublish
rmdist/*# optional cleanup