mirror of
https://github.com/asimonson1125/asimonson1125.github.io.git
synced 2026-02-25 05:09:49 -06:00
housekeeping
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
import flask
|
||||
from flask_sitemap import Sitemap
|
||||
import sass
|
||||
|
||||
app = flask.Flask(__name__)
|
||||
ext = Sitemap(app=app)
|
||||
sass.compile(dirname=('static/scss', 'static/css'), output_style='compressed')
|
||||
|
||||
@app.route('/')
|
||||
@@ -29,15 +27,10 @@ def page404(e):
|
||||
finally:
|
||||
return flask.render_template('error.html', error=eCode, message=message, title=f'{eCode} - Simonson Portfolio'), eCode
|
||||
|
||||
# @app.route('/sitemap.xml')
|
||||
@app.route('/sitemap.xml')
|
||||
@app.route('/robots.txt')
|
||||
def static_from_root():
|
||||
return flask.send_from_directory(app.static_folder, flask.request.path[1:])
|
||||
|
||||
# @ext.register_generator
|
||||
# def index():
|
||||
# # Not needed if you set SITEMAP_INCLUDE_RULES_WITHOUT_PARAMS=True
|
||||
# yield 'index', {}
|
||||
|
||||
if __name__ == '__main__':
|
||||
app.run()
|
||||
|
||||
Reference in New Issue
Block a user