Skip to content

Instantly share code, notes, and snippets.

@sogaiu
sogaiu / pretty-literals.lisp
Created May 3, 2021 — forked from rmoritz/pretty-literals.lisp
pretty hash table & vector literal syntax for common lisp
View pretty-literals.lisp
;;;; pretty-literals.lisp - pretty hash table & vector literal syntax
;;;; inspired by and uses code from http://frank.kank.net/essays/hash.html
(in-package #:pretty-literals)
;; vector literal syntax using brackets
(set-macro-character #\[
(lambda (str char)
(declare (ignore char))
(let ((*readtable* (copy-readtable *readtable* nil))
View seesaw-repl-tutorial.clj
; A REPL-based, annotated Seesaw tutorial
; Please visit https://github.com/daveray/seesaw for more info
;
; This is a very basic intro to Seesaw, a Clojure UI toolkit. It covers
; Seesaw's basic features and philosophy, but only scratches the surface
; of what's available. It only assumes knowledge of Clojure. No Swing or
; Java experience is needed.
;
; This material was first presented in a talk at @CraftsmanGuild in
; Ann Arbor, MI.
@sogaiu
sogaiu / rich-already-answered-that.md
Created Apr 18, 2021 — forked from reborg/rich-already-answered-that.md
A curated collection of answers that Rich gave throughout the history of Clojure
View rich-already-answered-that.md

Rich Already Answered That!

A list of commonly asked questions, design decisions, reasons why Clojure is the way it is as they were answered directly by Rich (even when from many years ago, those answers are pretty much valid today!). Feel free to point friends and colleagues here next time they ask (again). Answers are pasted verbatim (I've made small adjustments for readibility, but never changed a sentence) from mailing lists, articles, chats.

How to use:

  • The link in the table of content jumps at the copy of the answer on this page.
  • The link on the answer itself points back at the original post.

Table of Content

@sogaiu
sogaiu / TrueColour.md
Created Feb 27, 2021 — forked from XVilka/TrueColour.md
True Colour (16 million colours) support in various terminal applications and terminals
View TrueColour.md

Terminal Colors

There exists common confusion about terminal colors. This is what we have right now:

  • Plain ASCII
  • ANSI escape codes: 16 color codes with bold/italic and background
  • 256 color palette: 216 colors + 16 ANSI + 24 gray (colors are 24-bit)
  • 24-bit true color: "888" colors (aka 16 milion)
@sogaiu
sogaiu / save.clj
Last active Feb 11, 2019 — forked from Saikyun/save.clj
Proto repl save functionality for ClojureCLR + initial docs attempt
View save.clj
(ns miracle.tools.save
(:require [clojure.walk :refer [postwalk]]))
;; usage
;;
;; (save) or (save :whatever) somewhere in a function to save all the local
;; bindings at that point in time.
;;
;; (save-func ...) where ... is the body of your functions (e.g. (defn hej [a]
;; (save-func (let [b 5] (+ a b)))))
@sogaiu
sogaiu / 0 - data.md
Created Jan 16, 2019 — forked from sundarj/0 - data.md
data: towards enlightenment
View 0 - data.md

data

towards enlightenment

‘It is a capital mistake to theorize before one has data. Insensibly one begins to twist facts to suit theories, instead of theories to suit facts.’