19 lines
280 B
Python
19 lines
280 B
Python
import sys
|
|
|
|
from flask import Flask
|
|
from main import colorize
|
|
|
|
app = Flask(__name__)
|
|
|
|
|
|
@app.route('/<file_name>')
|
|
def hello_world(file_name: str):
|
|
colorize(file_name)
|
|
|
|
|
|
if __name__ == '__main__':
|
|
if len(sys.argv):
|
|
colorize(sys.argv[1])
|
|
else:
|
|
app.run()
|