Skip to content

Instantly share code, notes, and snippets.

@PierreR
PierreR / main.go
Created December 9, 2011 23:33
Double Loop (updates and pointers)
package main
import "fmt"
type score struct {
points int
}
type frame struct {
scores []score

Keybase proof

I hereby claim:

  • I am pierrer on github.
  • I am pradermecker (https://keybase.io/pradermecker) on keybase.
  • I have a public key whose fingerprint is 2BF3 EF75 B32C E7BB 67C9 DC7C A6D1 96A3 4E3E 5530

To claim this, I am signing this object:

@PierreR
PierreR / default-alternative.nix
Last active October 26, 2019 07:45
Haskell derivation won't work with nixpkgs 19.09 (or unstable)
let
sources = import ../nix/sources.nix;
overlay = self: super: {
haskellPackages = super.haskellPackages.override {
overrides = self: super: {
language-puppet = import ./language-puppet.nix { };
unit-test = self.callPackage ./unit-test.nix {};
};
};
};
@PierreR
PierreR / doc.nix
Last active October 29, 2019 10:35
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.profiles.doc;
homeDir = config.home.homeDirectory;
in
{
options = {
@PierreR
PierreR / cicd-shell.nix
Last active November 5, 2019 10:38
Haskell environment with mkShell
{ mkDerivation, aeson, ascii-progress, async, base
, concurrent-output, dhall, directory, filepath, haskeline, lens
, neat-interpolation, optparse-applicative, prettyprinter
, prettyprinter-ansi-terminal, process, protolude, raw-strings-qq
, req, stdenv, tasty, tasty-discover, tasty-golden, tasty-hunit
, text, transformers, turtle
}:
mkDerivation {
pname = "cicd-shell";
version = "2.7.1";