forked from orbit-oss/flask
update docs and examples for pyproject
setup.py -> pyproject.toml venv -> .venv
This commit is contained in:
parent
6d6d986fc5
commit
8f13f5b6d6
24 changed files with 153 additions and 195 deletions
2
examples/tutorial/.gitignore
vendored
2
examples/tutorial/.gitignore
vendored
|
|
@ -1,4 +1,4 @@
|
|||
venv/
|
||||
.venv/
|
||||
*.pyc
|
||||
__pycache__/
|
||||
instance/
|
||||
|
|
|
|||
|
|
@ -23,13 +23,13 @@ default Git version is the main branch. ::
|
|||
|
||||
Create a virtualenv and activate it::
|
||||
|
||||
$ python3 -m venv venv
|
||||
$ . venv/bin/activate
|
||||
$ python3 -m venv .venv
|
||||
$ . .venv/bin/activate
|
||||
|
||||
Or on Windows cmd::
|
||||
|
||||
$ py -3 -m venv venv
|
||||
$ venv\Scripts\activate.bat
|
||||
$ py -3 -m venv .venv
|
||||
$ .venv\Scripts\activate.bat
|
||||
|
||||
Install Flaskr::
|
||||
|
||||
|
|
|
|||
28
examples/tutorial/pyproject.toml
Normal file
28
examples/tutorial/pyproject.toml
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
[project]
|
||||
name = "flaskr"
|
||||
version = "1.0.0"
|
||||
description = "The basic blog app built in the Flask tutorial."
|
||||
readme = "README.rst"
|
||||
license = {text = "BSD-3-Clause"}
|
||||
maintainers = [{name = "Pallets", email = "contact@palletsprojects.com"}]
|
||||
dependencies = [
|
||||
"flask",
|
||||
]
|
||||
|
||||
[project.urls]
|
||||
Documentation = "https://flask.palletsprojects.com/tutorial/"
|
||||
|
||||
[project.optional-dependencies]
|
||||
test = ["pytest"]
|
||||
|
||||
[build-system]
|
||||
requires = ["setuptools"]
|
||||
build-backend = "setuptools.build_meta"
|
||||
|
||||
[tool.pytest.ini_options]
|
||||
testpaths = ["tests"]
|
||||
filterwarnings = ["error"]
|
||||
|
||||
[tool.coverage.run]
|
||||
branch = true
|
||||
source = ["flaskr", "tests"]
|
||||
|
|
@ -1,28 +0,0 @@
|
|||
[metadata]
|
||||
name = flaskr
|
||||
version = 1.0.0
|
||||
url = https://flask.palletsprojects.com/tutorial/
|
||||
license = BSD-3-Clause
|
||||
maintainer = Pallets
|
||||
maintainer_email = contact@palletsprojects.com
|
||||
description = The basic blog app built in the Flask tutorial.
|
||||
long_description = file: README.rst
|
||||
long_description_content_type = text/x-rst
|
||||
|
||||
[options]
|
||||
packages = find:
|
||||
include_package_data = true
|
||||
install_requires =
|
||||
Flask
|
||||
|
||||
[options.extras_require]
|
||||
test =
|
||||
pytest
|
||||
|
||||
[tool:pytest]
|
||||
testpaths = tests
|
||||
|
||||
[coverage:run]
|
||||
branch = True
|
||||
source =
|
||||
flaskr
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
from setuptools import setup
|
||||
|
||||
setup()
|
||||
Loading…
Add table
Add a link
Reference in a new issue