Skip to main content

Une simple calculatrice Python/Django

Project description

PyCalculatrice

Une simple application Django qui fournit une calculatrice web basique avec les opérations addition, soustraction, multiplication et division.


Installation

1. Cloner le dépôt (ou télécharger le package)

git clone https://ton-repo-ou-chemin/pycalculatrice.git
cd pycalculatrice

2. Créer et activer un environnement virtuel (optionnel mais recommandé)

python3 -m venv venv
source venv/bin/activate  # Linux/Mac
venv\Scripts\activate     # Windows

3. Installer les dépendances

pip install -r requirements.txt

4. Installer le package localement (mode editable)

pip install -e .

Utilisation dans un projet Django
1. Créer un projet Django (si ce n'est pas déjà fait)

django-admin startproject monprojet
cd monprojet

2. Ajouter pycalculatrice dans INSTALLED_APPS dans monprojet/settings.py

INSTALLED_APPS = [
    # autres apps
    'pycalculatrice',
]

3. Inclure les URLs dans monprojet/urls.py

from django.urls import path, include

urlpatterns = [
    # autres urls
    path('calculatrice/', include('pycalculatrice.urls')),
]

4. Appliquer les migrations Django

python manage.py migrate

5. Lancer le serveur

python manage.py runserver

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pycalculatrice-0.2.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pycalculatrice-0.2-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file pycalculatrice-0.2.tar.gz.

File metadata

  • Download URL: pycalculatrice-0.2.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for pycalculatrice-0.2.tar.gz
Algorithm Hash digest
SHA256 c424c50bb3f87f15c45024854a6d5c7811a98a421746665b1a7920693557bc99
MD5 a41f50015c8fa21ca186f24aeadb0656
BLAKE2b-256 e61487e8df0a2a0577084d271971ff46dca068e4c02430a8b9380942a42131f0

See more details on using hashes here.

File details

Details for the file pycalculatrice-0.2-py3-none-any.whl.

File metadata

  • Download URL: pycalculatrice-0.2-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for pycalculatrice-0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 04c518379f4d9d7c71d5acca87ed3d653a113b35b5c7f05bd8047ba410106ed1
MD5 00febe634a89e63f91127f386ee71b64
BLAKE2b-256 f413f83d490870699dafd87b61b7c08fcb05260b48fb1be12ba121609a0bf441

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page