A semantic search engine for source code https://bitshift.benkurtovic.com/
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.
 
 
 
 
 
 

29 rader
575 B

  1. """
  2. Module to contain all the project's Flask server plumbing.
  3. """
  4. from flask import Flask
  5. from flask import render_template, session
  6. from bitshift.query import parse_query
  7. app = Flask(__name__)
  8. app.config.from_object("bitshift.config")
  9. app_env = app.jinja_env
  10. app_env.line_statement_prefix = "="
  11. app_env.globals.update(assets = assets)
  12. @app.route("/")
  13. def index():
  14. return render_template("index.html")
  15. @app.route("/search/<query>")
  16. def search(query):
  17. ## tree = parse_query(query)
  18. ## database.search(tree)
  19. pass
  20. if __name__ == "__main__":
  21. app.run()