winterthur-app

Web application for the Winterthur project.

https://github.com/chnm/winterthur-app

Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (10.0%) to scientific vocabulary

Keywords

django
Last synced: 6 months ago · JSON representation

Repository

Web application for the Winterthur project.

Basic Info
  • Host: GitHub
  • Owner: chnm
  • License: mit
  • Language: JavaScript
  • Default Branch: main
  • Size: 1.08 GB
Statistics
  • Stars: 1
  • Watchers: 5
  • Forks: 0
  • Open Issues: 1
  • Releases: 0
Topics
django
Created almost 3 years ago · Last pushed 11 months ago
Metadata Files
Readme Changelog License Citation

README.md

Denig Manuscript Project

This repository contains code for the Denig manuscript project, a partnership between RRCHNM and the Winterthur Museum.

Python 3.11.0 / Django 4.1 / Postgresql

Development

The project uses Poetry for dependency and package management. To create your Django environment, navigate to the root (cloned) directory and do the following:

sh % cd winterthur-app % poetry install

We also use pre-commit with black and djhtml to keep things nicely formatted.

% poetry run pre-commit install % poetry run pre-commit autoupdate

Running manage.py will require prepending poetry to the commands, like so:

sh poetry run python manage.py migrate poetry run python manage.py tailwind build poetry run python manage.py runserver

A Makefile exists to make life a little more convenient. The common commands are:

  • make preview: preview the site locally; this runs poetry run python manage.py runserver. You can also use npm run serve.
  • make tailwind: compile the CSS; this runs poetry run python manage.py tailwind start and will reload the browser anytime updates happen.
  • make mm: performs Django's makemigration
  • make migrate: performs Django's migrate

Setting up configuration in environment

For security, we store configurations in a local .env file. To get a local environment file to work with django-environ, we install python-dotenv:

sh % poetry add python-dotenv

Then add relevant files to an .env file:

% echo DEBUG=True >> .env % echo DJANGO_SECRET_KEY=$(poetry run python -c "import secrets; print(secrets.token_urlsafe())") >> .env

Update config/settings.py to read the .env file.

```python import environ from dotenv import load_dotenv

load_dotenv()

env = environ.FileAwareEnv( DEBUG=(bool, False) )

[...]

Update this existing value

DEBUG = env('DEBUG')

Update this existing value

SECRETKEY = env('DJANGOSECRET_KEY') ```

When it comes time to connect to Postgres, we also store the Postgres connection string in .env.

Owner

  • Name: Roy Rosenzweig Center for History and New Media
  • Login: chnm
  • Kind: organization
  • Location: Fairfax, VA, USA

GitHub Events

Total
  • Issues event: 10
  • Delete event: 16
  • Issue comment event: 5
  • Push event: 24
  • Pull request event: 18
  • Create event: 8
Last Year
  • Issues event: 10
  • Delete event: 16
  • Issue comment event: 5
  • Push event: 24
  • Pull request event: 18
  • Create event: 8

Dependencies

Dockerfile docker
  • python 3.11 build
docker-compose.yml docker
  • postgres 16
.github/workflows/cicd.yml actions
package-lock.json npm
  • @hotwired/stimulus 3.2.1
  • @hotwired/stimulus-webpack-helpers 1.0.1
  • @hotwired/turbo 7.3.0
package.json npm
  • @hotwired/stimulus ^3.2.1
  • @hotwired/stimulus-webpack-helpers ^1.0.1
  • @hotwired/turbo ^7.3.0
theme/static_src/package-lock.json npm
  • 104 dependencies
theme/static_src/package.json npm
  • @tailwindcss/aspect-ratio ^0.4.2 development
  • @tailwindcss/forms ^0.5.3 development
  • @tailwindcss/line-clamp ^0.4.2 development
  • @tailwindcss/typography ^0.5.2 development
  • cross-env ^7.0.3 development
  • postcss ^8.4.14 development
  • postcss-import ^15.1.0 development
  • postcss-nested ^6.0.0 development
  • postcss-simple-vars ^7.0.1 development
  • rimraf ^4.1.2 development
  • tailwindcss ^3.2.7 development
poetry.lock pypi
  • 128 dependencies
pyproject.toml pypi
  • python-slugify ^8.0.1 base
  • black ^23.3.0 develop
  • django-coverage-plugin ^3.0.0 develop
  • django-debug-toolbar ^4.0.0 develop
  • django-extensions ^3.2.1 develop
  • djhtml ^3.0.6 develop
  • pre-commit ^3.2.1 develop
  • pylint-django ^2.5.3 develop
  • pytest-django ^4.5.2 develop
  • pytest-sugar ^0.9.7 develop
  • boto3 ^1.34.128
  • daphne ^4.0.0
  • django ^4.1.7
  • django-admin-interface ^0.24.2
  • django-allauth ^0.54.0
  • django-cleanup ^8.1.0
  • django-dbml ^0.6.0
  • django-environ ^0.10.0
  • django-extensions ^3.2.1
  • django-htmx ^1.14.0
  • django-imagekit ^5.0.0
  • django-import-export ^3.2.0
  • django-modelcluster ^6.3
  • django-multiselectfield ^0.1.12
  • django-prose ^1.2.2
  • django-storages ^1.14.3
  • django-taggit ^5.0.1
  • django-tailwind ^3.5.0
  • humanfriendly ^10.0
  • numpy ^1.26.4
  • pandas ^2.2.2
  • pillow ^9.4.0
  • psycopg2 ^2.9.9
  • python ^3.11
  • python-dotenv ^1.0.0
  • taggit-selectize ^2.11.0
  • wagtail ^6.0.1
  • whitenoise ^6.8.2