Giter Club home page Giter Club logo

pur-beurre-django's Introduction

Build Status codecov

Pur Beurre

The goal of this project is to help customers who wants to change their diet but were unsure where to start. Replace the Nutella with a hazelnut paste, yes, but which one? In which shop to buy it?

The idea of this application is to provide a handy tool for customers to search, compare foodstuffs or even suggest (healthier) substituts for any.

Installation

Copy the .env.example file located in the nested purbeurre directory and rename it .env. You must fill the SECRET_KEY, DATABASE_URL and variables prefixed by ALGOLIA_ otherwise the application will not properly work.

Fill the SECRET_KEY with a long, random string.

Then, in order to be able to run the app, you must install its dependencies which are listed in the requirements.txt file with pip:

$ pip install -r requirements.txt

Finally, you need to create the database which you specify in the .env file and migrate the tables:

$ python manage.py migrate

Virtual Environments

Sometimes you want to keep libraries from polluting system installs or use a different version of libraries than the ones installed on the system.
For this purpose, the standard library as of Python 3.3 comes with the "venv" module in order to help maintain these separate versions. These are others libraries which do the same but here we'll keep with the standard.

For a more in-depth tutorial, check the Virtual Environments and Packages documentation.

So, lets create our virtual environment:

  1. Go to the purbeurre project directory:
    $ cd path/to/purbeurre
  2. Create your virtual environment:
    $ python3 -m venv my_venv
  3. Activate your virtual environment:
    $ source my_venv/bin/activate
    On Windows it will be a little different:
    $ my_venv\Scripts\activate.bat

    If you use Powershell, the file to use is activate.ps1 instead.

You now have finished setting up your virtual environment.

To exit the virtual environment, simply type the command deactivate in your terminal

Run on localhost

After the installation step, you can run the application through the manage.py file in a terminal:

$ python manage.py runserver

The runserver command is only for development purpose

pur-beurre-django's People

Contributors

dylamn avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.