From 2b90fe86c3160cdac339f97ead9f12b9753b471e Mon Sep 17 00:00:00 2001 From: Waylon Walker Date: Thu, 30 Mar 2017 15:12:24 -0500 Subject: [PATCH] set up a simple working template for a bottle server --- andoid_bottle.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 andoid_bottle.py diff --git a/andoid_bottle.py b/andoid_bottle.py new file mode 100644 index 0000000..0fc7b19 --- /dev/null +++ b/andoid_bottle.py @@ -0,0 +1,22 @@ +import matplotlib +matplotlib.use('agg') +import pandas as pd +from bottle import Bottle + +app = Bottle() + +@app.route('/index') +def index(): + title = 'Hello World' + plot = 'plot placeholder' + footer = 'created fron an android device using Termux' + html = f'''

{title}

+
+ {plot} +
+ {footer}''' + return html + + +if __name__ == '__main__': + app.run()