Skip to content

Instantly share code, notes, and snippets.

@sefgit
sefgit / .block
Created January 12, 2024 00:54 — forked from schmidsi/.block
Order Book Visualisation
license: gpl-3.0
@sefgit
sefgit / datgui-build.js
Created December 25, 2023 02:37 — forked from heaversm/datgui-build.js
Automatically build a dat gui from a javascript object
config = { //SAMPLE OBJECT - replace this with your data object
stroke: 2, //svg stroke value
opacity: 0.3, //0-1
offsetX: 120, //px
offsetY: 80,
fontWeight: 400, //css font-weight
fontSize: 12, //in px
changePositive: '\u25B4', //unicode character for up arrow
changeNegative: '\u25BE', //unicode character for down arrow
colorBlue: '#1190A3', //all hex colors will automatically use the addColor dat gui function
@sefgit
sefgit / static-http-receiver.py
Created December 25, 2023 01:33 — forked from traut/static-http-receiver.py
Static HTTP server in Python that saves all POST requests as files in the current directory
import os
from http.server import HTTPServer, BaseHTTPRequestHandler, SimpleHTTPRequestHandler
class CustomHTTPRequestHandler(SimpleHTTPRequestHandler):
def do_POST(self):
filename = os.path.basename(self.path)
file_length = int(self.headers['Content-Length'])
with open(filename, 'wb') as output_file: