Answers for "start flask app command line"

2

run flask app from command line

# For bash do this:
set FLASK_APP=<app_name>

# For powershell do this:
$env FLASK_APP=<app_name>

# Run it like this
flask run
Posted by: Guest on September-20-2020
1

how to set and run flask app on terminal

> set FLASK_APP=hello
> flask run
Posted by: Guest on August-14-2020
0

flask commands

# manage.py

from flask_script import Manager

from myapp import app

manager = Manager(app)

@manager.command
def hello():
    print "hello"

if __name__ == "__main__":
    manager.run()
Posted by: Guest on May-16-2020

Python Answers by Framework

Browse Popular Code Answers by Language