Fundraising in PDF.
[wolnelektury.git] / doc / basic-setup.rst
1 ===========
2 Basic setup
3 ===========
4
5 Wolne Lektury is a `Django <https://www.djangoproject.com/>`_ project.
6
7 If you're new to Django, we strongly recommend you complete
8 the `Django Girls Tutorial <https://tutorial.djangogirls.org/en/>`_ and/or
9 the official :django:`Django Tutorial <getting-started>`
10 to learn about setting up a Python virtual environment and general structure
11 of a Django project.
12
13 Getting started
14 ---------------
15
16 Once you have your Python (version at least 3.5) installed, virtualenv created,
17 and the source code of Wolne Lektury checked out to a directory, then the most
18 basic setup is as easy as:
19
20     $ pip install -r requirements/requirements.txt
21
22 After that, you should be able to run tests:
23
24     $ src/manage.py test
25
26 And migrate the database and run the development server:
27
28     $ src/manage.py migrate
29     $ src/manage.py runserver
30
31
32 Publishing books
33 ----------------
34
35 Books are represented as XML files.
36 You can download some books as source XML files and import them
37 into your instance either by using the admin interface,
38 or by running::
39
40     src/manage.py importbooks your-directory-with-xml-files
41
42
43 What's next?
44 ------------
45
46 This basic setup:
47
48 * uses a SQLite file as a database,
49 * has search disabled,
50 * does not generate PDF, EPUB or MOBI files from books,
51 * will generate TXT, HTML, FB2 and cover image files, but will not use a task queue.
52
53 In the next section, you'll see what additional setup is needed to solve these issues.