Skip to content

Instantly share code, notes, and snippets.

@zvodd
zvodd / freecam.gd
Created August 28, 2019 16:00 — forked from Einlander/freecam.gd
free flight camera for godot
extends Camera
# tested in Godot 3.1
export var normal_flyspeed = 5
export var shift_flyspeed = 15
var flyspeed = normal_flyspeed
var tmp_flyspeed
var view_sensitivity = 0.3
var mousedifference = Vector3()
var yaw = 0
@zvodd
zvodd / parsehar.py
Last active October 26, 2023 10:30 — forked from tomatohater/parsehar.py
parsehar.py - Reads a har file from the filesystem, converts to CSV, then dumps to stdout.
"""Reads a har file from the filesystem, converts to CSV, then dumps to
stdout.
"""
import argparse
import json
from urllib.parse import urlparse
def main(harfile_path):
"""Reads a har file from the filesystem, converts to CSV, then dumps to
@zvodd
zvodd / mysqldump
Last active November 21, 2023 08:28
Git friendly MySQL Dump
With the default mysqldump format, each record dumped will generate an individual INSERT command in the dump file (i.e., the sql file), each on its own line. This is perfect for source control (e.g., svn, git, etc.) as it makes the diff and delta resolution much finer, and ultimately results in a more efficient source control process. However, for significantly sized tables, executing all those INSERT queries can potentially make restoration from the sql file prohibitively slow.
Using the --extended-insert option fixes the multiple INSERT problem by wrapping all the records into a single INSERT command on a single line in the dumped sql file. However, the source control process becomes very inefficient. The entire table contents is represented on a single line in the sql file, and if a single character changes anywhere in that table, source control will flag the entire line (i.e., the entire table) as the delta between versions. And, for large tables, this negates many of the benefits of using a formal sourc