A web app for posting flickr images, using a webcrawler.
beautifulsoup4 4.12.3
cloudinary 1.38.0
cryptography 42.0.2
dj-database-url 2.1.0
Django 5.0.1
django-admin-honeypot-updated-2021 1.2.0
django-allauth 0.60.1
django-cleanup 8.1.0
django-cloudinary-storage 0.3.0
django-environ 0.11.2
django-htmx 1.17.2
django-resized 1.0.2
django-storages 1.14.2
gunicorn 21.2.0
pillow 10.2.0
psycopg2-binary 2.9.9
requests 2.31.0
whitenoise 6.6.0
- Create folder and open up with your preferred IDE (eg. VS Code)
- Download Github Desktop and sign in with your Github account
- Clone repository using Github Desktop (choose the correct path to your folder)
- Duplicate staticfiles folder and rename it "static"
- Get the .env file and save it into the a_core folder
- Install Python (python.org, check if installed: python --version)
- Activate Virtual Environment (eg. venv)
- pip install -r requirements.txt
- python manage.py migrate
- python manage.py createsuperuser
- python manage.py runserver
- Create feature branch: feature_nameofthefeature_yourname (change "nameoffeature" and "yourname")
- Add new feature to the Features table in the admin interface
- In the .env file change DEVELOPER=Yourname (change "Yourname")
- Add feature toggle:
from a_features.views import feature_enabled
try:
feature_herobutton = feature_enabled(1, 'Yourname')
except:
feature_herobutton = False- Change "1" with the id of the feature and "Yourname"
This installation is only required if you make css changes on the site.
- Download node (nodejs.org, check if installed: node --version)
- mkdir node && cd node
- npm init -y && npm install tailwindcss && npx tailwindcss init && npm install clean-css-cli
- Modify files:
module.exports = {
content: [
'../templates/**/*.html',
'../**/templates/**/*.html',
'../**/forms.py'
],
"scripts": {
"tailwind": "tailwind build -i ../static/css/tailwind.css -o ../static/css/style.css --watch",
"minify": "cleancss ../static/css/style.css -o ../static/css/style.min.css"
},
- npm run tailwind
- ctrl+c
- npm run minify
- cd .. && python manage.py collectstatic