Skip to content
Myr

Add command switch tabs for Bash, CMD and Powershell with sphinx-tabs (#3714)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

* Enable Sphinx extension sphinx-tabs * Add command tabs for all export commands * Add command tabs for all venv commands Fix trim spaces

authored by Grey Li · committed by GitHub · parent c5a5d9b · Browse files · 14 files+498 added−126 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

14 files+498 added−126 removed

  • other:+498 added−126 removed

14 files+498 added−126 removed

modified:docs/patterns/appfactories.rst+46 added-6 removed
85 unmodified lines
8687Using Applications88------------------8990To run such an application, you can use the :command:`flask` command::90To run such an application, you can use the :command:`flask` command:9192 $ export FLASK_APP=myapp93 $ flask run92.. tabs::9394 .. group-tab:: Bash9596 .. code-block:: text9798 $ export FLASK_APP=myapp99 $ flask run100101 .. group-tab:: CMD102103 .. code-block:: text104105 > set FLASK_APP=myapp106 > flask run107108 .. group-tab:: Powershell109110 .. code-block:: text111112 > $env:FLASK_APP = "myapp"113 > flask run114115Flask will automatically detect the factory (``create_app`` or ``make_app``)96in ``myapp``. You can also pass arguments to the factory like this::116in ``myapp``. You can also pass arguments to the factory like this:11798 $ export FLASK_APP="myapp:create_app('dev')"99 $ flask run118.. tabs::119120 .. group-tab:: Bash121122 .. code-block:: text123124 $ export FLASK_APP="myapp:create_app('dev')"125 $ flask run126127 .. group-tab:: CMD128129 .. code-block:: text130131 > set FLASK_APP="myapp:create_app('dev')"132 > flask run133134 .. group-tab:: Powershell135136 .. code-block:: text137138 > $env:FLASK_APP = "myapp:create_app('dev')"139 > flask run140141Then the ``create_app`` factory in ``myapp`` is called with the string142``'dev'`` as the argument. See :doc:`/cli` for more detail.143144Factory Improvements
11 unmodified lines
modified:docs/patterns/packages.rst+40 added-4 removed
55 unmodified lines
56 ],57 )5859In order to run the application you need to export an environment variable60that tells Flask where to find the application instance::60that tells Flask where to find the application instance:6162 $ export FLASK_APP=yourapplication62.. tabs::6364 .. group-tab:: Bash6566 .. code-block:: text6768 $ export FLASK_APP=yourapplication6970 .. group-tab:: CMD7172 .. code-block:: text7374 > set FLASK_APP=yourapplication7576 .. group-tab:: Powershell7778 .. code-block:: text7980 > $env:FLASK_APP = "yourapplication"8182If you are outside of the project directory make sure to provide the exact83path to your application directory. Similarly you can turn on the66development features like this::84development features like this:8568 $ export FLASK_ENV=development86.. tabs::8788 .. group-tab:: Bash8990 .. code-block:: text9192 $ export FLASK_ENV=development9394 .. group-tab:: CMD9596 .. code-block:: text9798 > set FLASK_ENV=development99100 .. group-tab:: Powershell101102 .. code-block:: text103104 > $env:FLASK_ENV = "development"105106In order to install and run the application you need to issue the following107commands::108109 $ pip install -e .
66 unmodified lines
modified:docs/tutorial/deploy.rst+21 added-3 removed
46 unmodified lines
4748Since this is a different machine, you need to run ``init-db`` again to49create the database in the instance folder.5051.. code-block:: none51.. tabs::5253 $ export FLASK_APP=flaskr54 $ flask init-db53 .. group-tab:: Bash5455 .. code-block:: text5657 $ export FLASK_APP=flaskr58 $ flask init-db5960 .. group-tab:: CMD6162 .. code-block:: text6364 > set FLASK_APP=flaskr65 > flask init-db6667 .. group-tab:: Powershell6869 .. code-block:: text7071 > $env:FLASK_APP = "flaskr"72 > flask init-db7374When Flask detects that it's installed (not in editable mode), it uses75a different directory for the instance folder. You can find it at76``venv/var/flaskr-instance`` instead.77
62 unmodified lines
modified:docs/tutorial/factory.rst+17 added-15 removed
133 unmodified lines
134exception, and restarts the server whenever you make changes to the135code. You can leave it running and just reload the browser page as you136follow the tutorial.137138For Linux and Mac:138.. tabs::139140.. code-block:: none140 .. group-tab:: Bash141142 $ export FLASK_APP=flaskr143 $ export FLASK_ENV=development144 $ flask run142 .. code-block:: text143146For Windows cmd, use ``set`` instead of ``export``:144 $ export FLASK_APP=flaskr145 $ export FLASK_ENV=development146 $ flask run147148.. code-block:: none148 .. group-tab:: CMD149150 > set FLASK_APP=flaskr151 > set FLASK_ENV=development152 > flask run150 .. code-block:: text151154For Windows PowerShell, use ``$env:`` instead of ``export``:152 > set FLASK_APP=flaskr153 > set FLASK_ENV=development154 > flask run155156.. code-block:: none156 .. group-tab:: Powershell157158 > $env:FLASK_APP = "flaskr"159 > $env:FLASK_ENV = "development"160 > flask run158 .. code-block:: text159160 > $env:FLASK_APP = "flaskr"161 > $env:FLASK_ENV = "development"162 > flask run163164You'll see output similar to this:165166.. code-block:: none167
13 unmodified lines
modified:docs/cli.rst+153 added-36 removed
16 unmodified lines
17The ``flask`` command is installed by Flask, not your application; it must be18told where to find your application in order to use it. The ``FLASK_APP``19environment variable is used to specify how to load the application.2021Unix Bash (Linux, Mac, etc.)::21.. tabs::2223 $ export FLASK_APP=hello24 $ flask run23 .. group-tab:: Bash2426Windows CMD::25 .. code-block:: text2628 > set FLASK_APP=hello29 > flask run27 $ export FLASK_APP=hello28 $ flask run2931Windows PowerShell::30 .. group-tab:: CMD3133 > $env:FLASK_APP = "hello"34 > flask run32 .. code-block:: text3334 > set FLASK_APP=hello35 > flask run3637 .. group-tab:: Powershell3839 .. code-block:: text4041 > $env:FLASK_APP = "hello"42 > flask run4344While ``FLASK_APP`` supports a variety of options for specifying your45application, most use cases should be simple. Here are the typical values:4647(nothing)
87 unmodified lines
135If the env is set to ``development``, the ``flask`` command will enable136debug mode and ``flask run`` will enable the interactive debugger and137reloader.138131::139.. tabs::140133 $ FLASK_ENV=development flask run134 * Serving Flask app "hello"135 * Environment: development136 * Debug mode: on137 * Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)138 * Restarting with inotify reloader139 * Debugger is active!140 * Debugger PIN: 223-456-919141 .. group-tab:: Bash142143 .. code-block:: text144145 $ export FLASK_ENV=development146 $ flask run147 * Serving Flask app "hello"148 * Environment: development149 * Debug mode: on150 * Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)151 * Restarting with inotify reloader152 * Debugger is active!153 * Debugger PIN: 223-456-919154155 .. group-tab:: CMD156157 .. code-block:: text158159 > set FLASK_ENV=development160 > flask run161 * Serving Flask app "hello"162 * Environment: development163 * Debug mode: on164 * Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)165 * Restarting with inotify reloader166 * Debugger is active!167 * Debugger PIN: 223-456-919168169 .. group-tab:: Powershell170171 .. code-block:: text172173 > $env:FLASK_ENV = "development"174 > flask run175 * Serving Flask app "hello"176 * Environment: development177 * Debug mode: on178 * Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)179 * Restarting with inotify reloader180 * Debugger is active!181 * Debugger PIN: 223-456-919182183184Watch Extra Files with the Reloader185~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~186187When using development mode, the reloader will trigger whenever your
1 unmodified line
189additional files with the ``--extra-files`` option, or the190``FLASK_RUN_EXTRA_FILES`` environment variable. Multiple paths are191separated with ``:``, or ``;`` on Windows.192152.. code-block:: none193.. tabs::194154 $ flask run --extra-files file1:dirA/file2:dirB/155 # or156 $ export FLASK_RUN_EXTRA_FILES=file1:dirA/file2:dirB/157 $ flask run158 * Running on http://127.0.0.1:8000/159 * Detected change in '/path/to/file1', reloading195 .. group-tab:: Bash196197 .. code-block:: text198199 $ flask run --extra-files file1:dirA/file2:dirB/200 # or201 $ export FLASK_RUN_EXTRA_FILES=file1:dirA/file2:dirB/202 $ flask run203 * Running on http://127.0.0.1:8000/204 * Detected change in '/path/to/file1', reloading205206 .. group-tab:: CMD207208 .. code-block:: text209210 > flask run --extra-files file1:dirA/file2:dirB/211 # or212 > set FLASK_RUN_EXTRA_FILES=file1:dirA/file2:dirB/213 > flask run214 * Running on http://127.0.0.1:8000/215 * Detected change in '/path/to/file1', reloading216217 .. group-tab:: Powershell218219 .. code-block:: text220221 > flask run --extra-files file1:dirA/file2:dirB/222 # or223 > $env:FLASK_RUN_EXTRA_FILES = "file1:dirA/file2:dirB/"224 > flask run225 * Running on http://127.0.0.1:8000/226 * Detected change in '/path/to/file1', reloading227228229Debug Mode230----------231232Debug mode will be enabled when :envvar:`FLASK_ENV` is ``development``,
39 unmodified lines
272environment variables. The variables use the pattern273``FLASK_COMMAND_OPTION``. For example, to set the port for the run274command, instead of ``flask run --port 8000``:275209.. code-block:: bash276.. tabs::277211 $ export FLASK_RUN_PORT=8000212 $ flask run213 * Running on http://127.0.0.1:8000/278 .. group-tab:: Bash279280 .. code-block:: text281282 $ export FLASK_RUN_PORT=8000283 $ flask run284 * Running on http://127.0.0.1:8000/285286 .. group-tab:: CMD287288 .. code-block:: text289290 > set FLASK_RUN_PORT=8000291 > flask run292 * Running on http://127.0.0.1:8000/293294 .. group-tab:: Powershell295296 .. code-block:: text297298 > $env:FLASK_RUN_PORT = 8000299 > flask run300 * Running on http://127.0.0.1:8000/301302These can be added to the ``.flaskenv`` file just like ``FLASK_APP`` to303control default command options.304305
14 unmodified lines
320a project runner that loads them already. Keep in mind that the321environment variables must be set before the app loads or it won't322configure as expected.323237.. code-block:: bash324.. tabs::325239 $ export FLASK_SKIP_DOTENV=1240 $ flask run326 .. group-tab:: Bash327328 .. code-block:: text329330 $ export FLASK_SKIP_DOTENV=1331 $ flask run332333 .. group-tab:: CMD334335 .. code-block:: text336337 > set FLASK_SKIP_DOTENV=1338 > flask run339340 .. group-tab:: Powershell341342 .. code-block:: text343344 > $env:FLASK_SKIP_DOTENV = 1345 > flask run346347348Environment Variables From virtualenv349-------------------------------------350351If you do not want to install dotenv support, you can still set environment352variables by adding them to the end of the virtualenv's :file:`activate`353script. Activating the virtualenv will set the variables.354250Unix Bash, :file:`venv/bin/activate`::355.. tabs::356252 $ export FLASK_APP=hello357 .. group-tab:: Bash358254Windows CMD, :file:`venv\\Scripts\\activate.bat`::359 Unix Bash, :file:`venv/bin/activate`::360256 > set FLASK_APP=hello361 $ export FLASK_APP=hello362363 .. group-tab:: CMD364365 Windows CMD, :file:`venv\\Scripts\\activate.bat`::366367 > set FLASK_APP=hello368369 .. group-tab:: Powershell370371 Windows Powershell, :file:`venv\\Scripts\\activate.ps1`::372373 > $env:FLASK_APP = "hello"374375It is preferred to use dotenv support over this, since :file:`.flaskenv` can be376committed to the repository so that it works automatically wherever the project377is checked out.378
276 unmodified lines
modified:docs/conf.py+1 added
16 unmodified lines
17 "sphinx.ext.intersphinx",18 "sphinxcontrib.log_cabinet",19 "pallets_sphinx_themes",20 "sphinx_issues",21 "sphinx_tabs.tabs",22]23intersphinx_mapping = {24 "python": ("https://docs.python.org/3/", None),25 "werkzeug": ("https://werkzeug.palletsprojects.com/", None),
70 unmodified lines
modified:docs/config.rst+74 added-21 removed
63 unmodified lines
64 Added :envvar:`FLASK_ENV` to control the environment separately65 from debug mode. The development environment enables debug mode.6667To switch Flask to the development environment and enable debug mode,68set :envvar:`FLASK_ENV`::68set :envvar:`FLASK_ENV`:6970 $ export FLASK_ENV=development71 $ flask run70.. tabs::7173(On Windows, use ``set`` instead of ``export``.)72 .. group-tab:: Bash7374 .. code-block:: text7576 $ export FLASK_ENV=development77 $ flask run7879 .. group-tab:: CMD8081 .. code-block:: text8283 > set FLASK_ENV=development84 > flask run8586 .. group-tab:: Powershell8788 .. code-block:: text8990 > $env:FLASK_ENV = "development"91 > flask run9293Using the environment variables as described above is recommended. While94it is possible to set :data:`ENV` and :data:`DEBUG` in your config or95code, this is strongly discouraged. They can't be read early by the96``flask`` command, and some systems or extensions may have already
329 unmodified lines
426427This first loads the configuration from the428`yourapplication.default_settings` module and then overrides the values429with the contents of the file the :envvar:`YOURAPPLICATION_SETTINGS`412environment variable points to. This environment variable can be set on413Linux or OS X with the export command in the shell before starting the414server::430environment variable points to. This environment variable can be set431in the shell before starting the server:432416 $ export YOURAPPLICATION_SETTINGS=/path/to/settings.cfg417 $ python run-app.py418 * Running on http://127.0.0.1:5000/419 * Restarting with reloader...433.. tabs::434421On Windows systems use the `set` builtin instead::435 .. group-tab:: Bash436423 > set YOURAPPLICATION_SETTINGS=\path\to\settings.cfg437 .. code-block:: text438439 $ export YOURAPPLICATION_SETTINGS=/path/to/settings.cfg440 $ flask run441 * Running on http://127.0.0.1:5000/442443 .. group-tab:: CMD444445 .. code-block:: text446447 > set YOURAPPLICATION_SETTINGS=\path\to\settings.cfg448 > flask run449 * Running on http://127.0.0.1:5000/450451 .. group-tab:: Powershell452453 .. code-block:: text454455 > $env:YOURAPPLICATION_SETTINGS = "\path\to\settings.cfg"456 > flask run457 * Running on http://127.0.0.1:5000/458459The configuration files themselves are actual Python files. Only values460in uppercase are actually stored in the config object later on. So make461sure to use uppercase letters for your config keys.462
35 unmodified lines
498In addition to pointing to configuration files using environment variables, you499may find it useful (or necessary) to control your configuration values directly500from the environment.501468Environment variables can be set on Linux or OS X with the export command in469the shell before starting the server::502Environment variables can be set in the shell before starting the server:503471 $ export SECRET_KEY='5f352379324c22463451387a0aec5d2f'472 $ export MAIL_ENABLED=false473 $ python run-app.py474 * Running on http://127.0.0.1:5000/504.. tabs::505476On Windows systems use the ``set`` builtin instead::506 .. group-tab:: Bash507478 > set SECRET_KEY='5f352379324c22463451387a0aec5d2f'508 .. code-block:: text509510 $ export SECRET_KEY="5f352379324c22463451387a0aec5d2f"511 $ export MAIL_ENABLED=false512 $ flask run513 * Running on http://127.0.0.1:5000/514515 .. group-tab:: CMD516517 .. code-block:: text518519 > set SECRET_KEY="5f352379324c22463451387a0aec5d2f"520 > set MAIL_ENABLED=false521 > flask run522 * Running on http://127.0.0.1:5000/523524 .. group-tab:: Powershell525526 .. code-block:: text527528 > $env:SECRET_KEY = "5f352379324c22463451387a0aec5d2f"529 > $env:MAIL_ENABLED = "false"530 > flask run531 * Running on http://127.0.0.1:5000/532533While this approach is straightforward to use, it is important to remember that534environment variables are strings -- they are not automatically deserialized535into Python types.536
227 unmodified lines
modified:docs/debugging.rst+42 added-6 removed
42 unmodified lines
43``FLASK_ENV`` environment variable set to ``development``. This puts44Flask in debug mode, which changes how it handles some errors, and45enables the debugger and reloader.4647.. code-block:: text47.. tabs::4849 $ export FLASK_ENV=development50 $ flask run49 .. group-tab:: Bash5051 .. code-block:: text5253 $ export FLASK_ENV=development54 $ flask run5556 .. group-tab:: CMD5758 .. code-block:: text5960 > set FLASK_ENV=development61 > flask run6263 .. group-tab:: Powershell6465 .. code-block:: text6667 > $env:FLASK_ENV = "development"68 > flask run6970``FLASK_ENV`` can only be set as an environment variable. When running71from Python code, passing ``debug=True`` enables debug mode, which is72mostly equivalent. Debug mode can be controled separately from73``FLASK_ENV`` with the ``FLASK_DEBUG`` environment variable as well.
22 unmodified lines
96which can interfere.9798When running from the command line:9982.. code-block:: text100.. tabs::10184 $ export FLASK_ENV=development85 $ flask run --no-debugger --no-reload102 .. group-tab:: Bash103104 .. code-block:: text105106 $ export FLASK_ENV=development107 $ flask run --no-debugger --no-reload108109 .. group-tab:: CMD110111 .. code-block:: text112113 > set FLASK_ENV=development114 > flask run --no-debugger --no-reload115116 .. group-tab:: Powershell117118 .. code-block:: text119120 > $env:FLASK_ENV = "development"121 > flask run --no-debugger --no-reload122123When running from Python:124125.. code-block:: python126
7 unmodified lines
modified:docs/installation.rst+22 added-12 removed
73 unmodified lines
74~~~~~~~~~~~~~~~~~~~~~7576Create a project folder and a :file:`venv` folder within:7778.. code-block:: sh78.. tabs::7980 $ mkdir myproject81 $ cd myproject82 $ python3 -m venv venv80 .. group-tab:: macOS/Linux8184On Windows:82 .. code-block:: text8386.. code-block:: bat84 $ mkdir myproject85 $ cd myproject86 $ python3 -m venv venv8788 $ py -3 -m venv venv88 .. group-tab:: Windows8990 .. code-block:: text9192 > mkdir myproject93 > cd myproject94 > py -3 -m venv venv959697.. _install-activate-env:9899Activate the environment100~~~~~~~~~~~~~~~~~~~~~~~~101102Before you work on your project, activate the corresponding environment:10398.. code-block:: sh104.. tabs::105100 $ . venv/bin/activate106 .. group-tab:: macOS/Linux107102On Windows:108 .. code-block:: text109104.. code-block:: bat110 $ . venv/bin/activate111106 > venv\Scripts\activate112 .. group-tab:: Windows113114 .. code-block:: text115116 > venv\Scripts\activate117118Your shell prompt will change to show the name of the activated119environment.120121
12 unmodified lines
modified:docs/quickstart.rst+41 added-12 removed
42 unmodified lines
43:command:`python -m flask`. Before you can do that you need44to tell your terminal the application to work with by exporting the45``FLASK_APP`` environment variable:4647.. code-block:: text47.. tabs::4849 $ export FLASK_APP=hello.py50 $ flask run51 * Running on http://127.0.0.1:5000/49 .. group-tab:: Bash5053If you are on Windows, the environment variable syntax depends on command line54interpreter. On Command Prompt::51 .. code-block:: text5256 C:\path\to\app>set FLASK_APP=hello.py53 $ export FLASK_APP=hello.py54 $ flask run55 * Running on http://127.0.0.1:5000/5658And on PowerShell::57 .. group-tab:: CMD5860 PS C:\path\to\app> $env:FLASK_APP = "hello.py"59 .. code-block:: text6061 > set FLASK_APP=hello.py62 > flask run63 * Running on http://127.0.0.1:5000/6465 .. group-tab:: Powershell6667 .. code-block:: text6869 > $env:FLASK_APP = "hello.py"70 > flask run71 * Running on http://127.0.0.1:5000/7273This launches a very simple builtin server, which is good enough for74testing but probably not what you want to use in production. For75deployment options see :doc:`deploying/index`.76
68 unmodified lines
145146To enable all development features, set the ``FLASK_ENV`` environment147variable to ``development`` before calling ``flask run``.148138.. code-block:: text149.. tabs::150140 $ export FLASK_ENV=development141 $ flask run151 .. group-tab:: Bash152153 .. code-block:: text154155 $ export FLASK_ENV=development156 $ flask run157158 .. group-tab:: CMD159160 .. code-block:: text161162 > set FLASK_ENV=development163 > flask run164165 .. group-tab:: Powershell166167 .. code-block:: text168169 > $env:FLASK_ENV = "development"170 > flask run171172See also:173174- :doc:`/server` and :doc:`/cli` for information about running in175 development mode.
757 unmodified lines
modified:docs/server.rst+24 added-4 removed
21 unmodified lines
22development server. It requires setting the ``FLASK_APP`` environment23variable to point to your application, and ``FLASK_ENV=development`` to24fully enable development mode.2526.. code-block:: text26.. tabs::2728 $ export FLASK_APP=hello29 $ export FLASK_ENV=development30 $ flask run28 .. group-tab:: Bash2930 .. code-block:: text3132 $ export FLASK_APP=hello33 $ export FLASK_ENV=development34 $ flask run3536 .. group-tab:: CMD3738 .. code-block:: text3940 > set FLASK_APP=hello41 > set FLASK_ENV=development42 > flask run4344 .. group-tab:: Powershell4546 .. code-block:: text4748 > $env:FLASK_APP = "hello"49 > $env:FLASK_ENV = "development"50 > flask run5152This enables the development environment, including the interactive53debugger and reloader, and then starts the server on54http://localhost:5000/. Use ``flask run --help`` to see the available55options, and :doc:`/cli` for detailed instructions about configuring
54 unmodified lines
modified:requirements/docs.in+1 added
1 unmodified line
2packaging3Sphinx4sphinx-issues5sphinxcontrib-log-cabinet6sphinx-tabs
modified:requirements/docs.txt+5 added-1 removed
6 unmodified lines
7alabaster==0.7.12 # via sphinx8babel==2.8.0 # via sphinx9certifi==2020.4.5.1 # via requests10chardet==3.0.4 # via requests11colorama==0.4.3 # via sphinx12docutils==0.16 # via sphinx13idna==2.9 # via requests14imagesize==1.2.0 # via sphinx15importlib-metadata==1.7.0 # via pallets-sphinx-themes16jinja2==2.11.2 # via sphinx17markupsafe==1.1.1 # via jinja218packaging==20.4 # via -r requirements/docs.in, pallets-sphinx-themes, sphinx19pallets-sphinx-themes==1.2.3 # via -r requirements/docs.in
3 unmodified lines
23requests==2.23.0 # via sphinx24six==1.15.0 # via packaging25snowballstemmer==2.0.0 # via sphinx26sphinx-issues==1.2.0 # via -r requirements/docs.in27sphinx-tabs==1.1.13 # via -r requirements/docs.in25sphinx==3.2.1 # via -r requirements/docs.in, pallets-sphinx-themes, sphinx-issues, sphinxcontrib-log-cabinet28sphinx==3.2.1 # via -r requirements/docs.in, pallets-sphinx-themes, sphinx-issues, sphinx-tabs, sphinxcontrib-log-cabinet29sphinxcontrib-applehelp==1.0.2 # via sphinx30sphinxcontrib-devhelp==1.0.2 # via sphinx31sphinxcontrib-htmlhelp==1.0.3 # via sphinx32sphinxcontrib-jsmath==1.0.1 # via sphinx33sphinxcontrib-log-cabinet==1.0.1 # via -r requirements/docs.in34sphinxcontrib-qthelp==1.0.3 # via sphinx35sphinxcontrib-serializinghtml==1.1.4 # via sphinx36urllib3==1.25.9 # via requests37zipp==3.1.0 # via importlib-metadata3839# The following packages are considered to be unsafe in a requirements file:40# setuptools
modified:CONTRIBUTING.rst+11 added-6 removed
94 unmodified lines
95 git remote add fork https://github.com/{username}/flask9697- Create a virtualenv.9899 .. code-block:: text99 .. tabs::100101 $ python3 -m venv env102 $ . env/bin/activate101 .. group-tab:: macOS/Linux102104 On Windows, activating is different.103 .. code-block:: text104106 .. code-block:: text105 $ python3 -m venv env106 $ . env/bin/activate107108 > env\Scripts\activate108 .. group-tab:: Windows109110 .. code-block:: text111112 > py -3 -m venv env113 > env\Scripts\activate114115- Install Flask in editable mode with development dependencies.116117 .. code-block:: text118
102 unmodified lines