Skip to content

Instantly share code, notes, and snippets.

@cosmez
cosmez / sane-defaults.sql
Created May 16, 2025 17:15 — forked from james2doyle/sane-defaults.sql
Here is a list of sensible defaults when using sqlite https://briandouglas.ie/sqlite-defaults/
-- @see https://briandouglas.ie/sqlite-defaults/
-- Set the journal mode to Write-Ahead Logging for concurrency
PRAGMA journal_mode = WAL;
-- Set synchronous mode to NORMAL for performance and data safety balance
PRAGMA synchronous = NORMAL;
-- Set busy timeout to 5 seconds to avoid "database is locked" errors
PRAGMA busy_timeout = 5000;
@cosmez
cosmez / constansts.rkt
Created June 27, 2013 23:01 — forked from soegaard/constansts.rkt
Hack to declare constants
#lang racket
(module constants racket
(provide e pi)
(define e 2.1718281828)
(define pi (* 355/113 1.0)))
(require 'constants)
pi
; (set! pi (+ pi 1))