I hereby claim:
- I am dimitri on github.
- I am dimitri (https://keybase.io/dimitri) on keybase.
- I have a public key whose fingerprint is 3AD9 18E6 38A0 3C53 0877 967F F4E0 FE75 60B1 CB4E
To claim this, I am signing this object:
;; automate adding mail at point to ~/.mailrc | |
(require 'mail-parse) | |
(defun thing-at-point-bounds-of-email-address () | |
"return a cons of begin and end position of email address at point, including full name" | |
(save-excursion | |
(let* ((search-point (point)) | |
(start (re-search-backward "[:,]" (line-beginning-position) 'move)) | |
(dummy (goto-char search-point)) | |
(end (re-search-forward "[:,]" (line-end-position) t))) |
;;; fizzbuzz.el --- FizzBuzz in Emacs Lisp | |
;;; | |
;;; Copyright 2012 Dimitri Fontaine | |
;; | |
;; This is using a simple trick: we build a list of entries then print them as-is, | |
;; so that we can manually add \n when necessary and append "fizz" and "buzz" on the | |
;; same line. | |
;; | |
;; This file has two implementations of fizzbuzz then a main routine (interactive) to | |
;; call to fill in a buffer. Try loading the file then M-x fizzbuzz. |
#! /usr/bin/env python | |
""" | |
This script is used to forward events from source queues to | |
destination queue. Source and destination queues must be named | |
the same. The script applies to as many source databases as | |
needed. It allows for consuming all events from a distributed | |
system (think plproxy nodes) from a single federated queue | |
installed on the destination database. |
#! /usr/bin/env python | |
import os, sys | |
# compute lag between two XLOG file names in terms of files and bytes | |
# given 000000010000DAD7000000C4 and 000000010000DB1E00000032 we have: | |
# (int('DB1E',16) - int('DAD7', 16)) * 254 - int('C4',16) + int('132', 16) | |
# | |
# in pgsql:src/include/access/xlog_internal.h we have | |
# |
* An Emacs Workshop for Beginners | |
It's all about discovering Emacs Really | |
** Install | |
*** Emacs 24.3 | |
http://emacsformacosx.com/ | |
http://emacs.naquadah.org/ | |
http://ftp.gnu.org/pub/gnu/emacs/windows/ | |
** Conventions and docs |
#! /usr/bin/env sbcl --script | |
;; compute lag between two XLOG file names in terms of files and bytes | |
(defparameter *xlog-seg-size* (* 16 1024 1024) | |
"Xlog segment size, as per PostgreSQL pg_config.h") | |
(defparameter *xlog-segments-per-xlog-id* 254 | |
"How many Xlog segments we find per xlog ID (00 and FF are skipped)") |
I hereby claim:
To claim this, I am signing this object:
;; see http://www.fogcreek.com/Jobs/SupportEngineer/ | |
(defpackage #:fogcreek | |
(:use #:cl) | |
(:export #:*chars* | |
#:*text* | |
#:count-chars | |
#:sort-chars-by-count | |
#:solve)) |
;;; | |
;;; See https://www.hackerrank.com/challenges/manasa-and-stones | |
;;; | |
(defpackage #:manasa-and-stones | |
(:use :cl)) | |
(in-package #:manasa-and-stones) | |
(defvar *sample-input* "2 |
;;;; minesweeper.asd | |
(asdf:defsystem "minesweeper" | |
:serial t | |
:description "A quick minesweeper game using McCLIM" | |
:author "Dimitri Fontaine <[email protected]>" | |
:license "ISC" | |
:depends-on (#:mcclim) | |
:components ((:file "minesweeper"))) |