-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.bat
More file actions
32 lines (26 loc) · 866 Bytes
/
build.bat
File metadata and controls
32 lines (26 loc) · 866 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
@echo off
color a
mkdir flaskapp
cd flaskapp
mkdir static
cd static
mkdir css
mkdir images
mkdir js
cd ..
mkdir templates
cd templates
setlocal EnableDelayedExpansion
set LF=^
rem Two empty lines are required
set data_flask=from flask import Flask, render_template!LF!app=Flask(__name__)!LF!@app.route('/')!LF!def index():!LF! return render_template('index.html')!LF!if __name__=='__main__':!LF! app.run(debug=True)
set data_index=Hello world!LF!this is flask app
set data_req=click==8.0.1!LF!Flask==2.0.1!LF!importlib-metadata==4.8.1!LF!itsdangerous==2.0.1!LF!Jinja2==3.0.1!LF!MarkupSafe==2.0.1!LF!typing-extensions==3.10.0.2!LF!Werkzeug==2.0.1!LF!zipp==3.5.0!LF!colorama==0.4.4
echo !data_index! > "index.html"
cd ..
echo !data_flask! > "app.py"
echo !data_req! > "requirements.txt"
@REM pause
start chrome http://127.0.0.1:5000/
python app.py
clear