Docs: Add data loss warning for init-db in tutorial
This commit is contained in:
parent
627a0e20bd
commit
7ab0e99886
1 changed files with 9 additions and 1 deletions
|
|
@ -206,6 +206,14 @@ previous page.
|
|||
you use a new terminal, remember to change to your project directory
|
||||
and activate the env as described in :doc:`/installation`.
|
||||
|
||||
.. warning::
|
||||
|
||||
The ``init-db`` command will run the ``schema.sql`` file, which starts by
|
||||
dropping the existing ``user`` and ``post`` tables. **Running this command
|
||||
will permanently delete any existing data in your database.** Only run it
|
||||
when you are setting up the project for the first time or if you intentionally
|
||||
want to start over with an empty database.
|
||||
|
||||
Run the ``init-db`` command:
|
||||
|
||||
.. code-block:: none
|
||||
|
|
@ -216,4 +224,4 @@ Run the ``init-db`` command:
|
|||
There will now be a ``flaskr.sqlite`` file in the ``instance`` folder in
|
||||
your project.
|
||||
|
||||
Continue to :doc:`views`.
|
||||
Continue to :doc:`views`.
|
||||
Loading…
Add table
Add a link
Reference in a new issue