A repo for my personal website
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Removing unneeded server code

-27
-27
server.py
··· 1 - import http.server 2 - import socketserver 3 - 4 - PORT = 8000 5 - 6 - class HttpRequestHandler(http.server.SimpleHTTPRequestHandler): 7 - extensions_map = { 8 - '': 'application/octet-stream', 9 - '.manifest': 'text/cache-manifest', 10 - '.html': 'text/html', 11 - '.png': 'image/png', 12 - '.jpg': 'image/jpg', 13 - '.svg': 'image/svg+xml', 14 - '.css': 'text/css', 15 - '.js':'application/x-javascript', 16 - '.wasm': 'application/wasm', 17 - '.json': 'application/json', 18 - '.xml': 'application/xml', 19 - } 20 - 21 - httpd = socketserver.TCPServer(("localhost", PORT), HttpRequestHandler) 22 - 23 - try: 24 - print(f"serving at http://localhost:{PORT}") 25 - httpd.serve_forever() 26 - except KeyboardInterrupt: 27 - pass