The basic app.
Project description
The basic app.
Install
Be sure to use the same version of the code as the version of the docs you’re reading. You probably want the latest tagged version, but the default Git version is the main branch.
# clone the repository $ git clone https://github.com/pallets/flask $ cd flask # checkout the correct version $ git tag # shows the tagged versions $ git checkout latest-tag-found-above $ cd examples/tutorial
Create a virtualenv and activate it:
$ python3 -m venv venv $ . venv/bin/activate
Or on Windows cmd:
$ py -3 -m venv venv $ venv\Scripts\activate.bat
Install Flasktut:
$ pip install -e .
Or if you are using the main branch, install Flask from source before installing Flasktut:
$ pip install -e ../.. $ pip install -e .
Run
$ export FLASK_APP=flasktut $ export FLASK_ENV=development $ flask init-db $ flask run
Or on Windows cmd:
> set FLASK_APP=flasktut > set FLASK_ENV=development > flask init-db > flask run
Open http://127.0.0.1:5000 in a browser.
Test
$ pip install '.[test]' $ pytest
Run with coverage report:
$ coverage run -m pytest $ coverage report $ coverage html # open htmlcov/index.html in a browser
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
flasktut-0.0.1.tar.gz
(3.1 kB
view details)
Built Distribution
File details
Details for the file flasktut-0.0.1.tar.gz
.
File metadata
- Download URL: flasktut-0.0.1.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 27059c4a5fcac77352663e9864b799b9c83d703b2b9f3c34ccdeef782731eb73 |
|
MD5 | 23bc9f21e11dd6dcaaaf0ce3ca36f136 |
|
BLAKE2b-256 | a9ce7a11ece994cd8e167ccfd2e45f036d91526e39ce3dd3307eb87cb0d26185 |
File details
Details for the file flasktut-0.0.1-py3-none-any.whl
.
File metadata
- Download URL: flasktut-0.0.1-py3-none-any.whl
- Upload date:
- Size: 3.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bdfde30e17fe35004781320eb121ba1b85abfdb30c3acdecfdde00fcfa56f80d |
|
MD5 | ef20ffb94ac1a8c74badd3f76228a5e9 |
|
BLAKE2b-256 | 28a897af5864cbd6818247a6d6237e98e495064a7859aff23f126911b96b352a |