My experiments with an XMonad setup in NixOS. This is my work box now, so it pretty much works.
probably needs:
# useradd -m iain
# passwd iain ...
# passwd root ...
import matplotlib.pyplot as plt | |
def zoom_factory(ax,base_scale = 2.): | |
def zoom_fun(event): | |
# get the current x and y limits | |
cur_xlim = ax.get_xlim() | |
cur_ylim = ax.get_ylim() | |
# set the range | |
cur_xrange = (cur_xlim[1] - cur_xlim[0])*.5 |
;;; pushbullet.el --- An emacs client for the pushbullet android app | |
;;; Using the pushbullet api at https://pushbullet.com/api | |
;;; Uses grapnel for http requests https://github.com/leathekd/grapnel | |
;;; | |
;;; Commentary: | |
;;; | |
;;; Code: | |
(require 'grapnel) | |
(require 'json) |
from collections import OrderedDict as _OrderedDict | |
try: | |
from thread import get_ident as _get_ident | |
except ImportError: | |
from dummy_thread import get_ident as _get_ident | |
class ListDict(_OrderedDict): | |
def __init__(self, *args, **kwds): | |
try: |
My experiments with an XMonad setup in NixOS. This is my work box now, so it pretty much works.
probably needs:
# useradd -m iain
# passwd iain ...
# passwd root ...
{-# LANGUAGE TypeFamilies #-} | |
import Data.Function (on) | |
import Control.Applicative | |
data EventData e = EventData { | |
eventId :: Int, | |
body :: Event e | |
} |
Once upon a time…
I once took notes (almost sentence by sentence with not much editing) about the architectural design concepts - Command and Query Responsibility Segregation (CQRS) and Event Sourcing (ES) - from a presentation of Greg Young and published it as a gist (with the times when a given sentence was heard).
I then found other summaries of the talk and the gist has since been growing up. See the revisions to know the changes and where they came from (aka the sources).
It seems inevitable to throw Domain Driven Design (DDD) in to the mix.
select | |
object, | |
case "lock requested" | |
when 'AccessExclusiveLock' then 'access exclusive' | |
when 'ExclusiveLock' then 'exclusive' | |
when 'ShareRowExclusiveLock' then 'share row exclusive' | |
when 'ShareLock' then 'share' | |
when 'ShareUpdateExclusiveLock' then 'share update exclusive' | |
when 'RowExclusiveLock' then 'row exclusive' | |
when 'RowShareLock' then 'row share' |
#Enable Gzip compressed. | |
gzip on; | |
# Enable compression both for HTTP/1.0 and HTTP/1.1. | |
gzip_http_version 1.1; | |
# Compression level (1-9). | |
# 5 is a perfect compromise between size and cpu usage, offering about | |
# 75% reduction for most ascii files (almost identical to level 9). | |
gzip_comp_level 5; |
# Maintainer: Alexej Magura <agm2819*gmail*> | |
# | |
# | |
pkgname=libtinfo | |
pkgver=5 | |
pkgrel=7 | |
pkgdesc="symlink to ncurses for use in cuda and other packages" | |
arch=('any') | |
url="http://www.gnu.org/software/ncurses/" | |
license=('unknown') |
{ pkgs ? import (builtins.fetchTarball https://github.com/nixos/nixpkgs-channels/archive/nixos-unstable.tar.gz) {} }: | |
let | |
yaml = ./stack.yaml; | |
cabal2nix = "${pkgs.cabal2nix}/bin/cabal2nix --no-check --no-haddock"; | |
in | |
pkgs.writeScript "build.sh" '' | |
export NIX_PATH=nixpkgs=${pkgs.path} | |
resolver=$(awk '/resolver:/{print $2}' ${yaml} | sed 's,\.,_,g') |