Skip to content

Instantly share code, notes, and snippets.

@kconner
kconner / macOS Internals.md
Last active June 30, 2025 19:36
macOS Internals

macOS Internals

Understand your Mac and iPhone more deeply by tracing the evolution of Mac OS X from prelease to Swift. John Siracusa delivers the details.

Starting Points

How to use this gist

You've got two main options:

@fabiolimace
fabiolimace / UUIDv6.sql
Last active June 25, 2025 11:27
Functions for generating UUIDv6 and UUIDv7 on PostgreSQL
/*
* MIT License
*
* Copyright (c) 2023-2024 Fabio Lima
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@NHellFire
NHellFire / copyfileobj.py
Created December 22, 2016 03:20
Python copyfileobj with progress bar
from time import time
import sys
def mksize (bytes):
suffixes = ("B", "kB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB")
suffixesLen = len(suffixes)
for i in range(suffixesLen):
if bytes < pow(1000, i + 1) or i + 1 == suffixesLen:
return "%.2f %s" % (float(bytes) / pow(1024, i), suffixes[i])
@truh
truh / Fragenkatalog_INSY_201401.rst
Last active January 3, 2016 08:09
Fragenkatalog INSY

Fragenkatalog INSY

Imperative PHP-Webapplikationen

Mehrfach-Markierungen mit FOR EACH

@hay
hay / gist:1351230
Last active May 23, 2025 10:46
Enterprisify your Java Class Names!
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Enterprisify your Java Class Names! (by Hay Kranen)</title>
<style>
body {
background: white;
text-align: center;