Skip to content

Instantly share code, notes, and snippets.

drinking tea

Ben Sima bsima

drinking tea
View GitHub Profile
View gist:ea5d674aaec017e1748f5f399a67ef7b
- system: `"x86_64-linux"`
- host os: `Linux 4.15.0-1037-gcp, Ubuntu, 16.04.6 LTS (Xenial Xerus)`
- multi-user?: `yes`
- sandbox: `relaxed`
- version: `nix-env (Nix) 2.2`
- channels(root): `"nixpkgs-19.09pre186545.f11ce8683e1"`
- nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixpkgs`
bsima /
Created Jan 17, 2019
haskell, cabal, nix err

cabal file

name: hero-server
version: 2
license: AllRightsReserved
license-file: LICENSE
cabal-version: >= 1.18
build-type: Simple
View gist:cf53553544575331f6305dc15d062464
ben@neb:~$ curl -I
HTTP/2 200
accept-ranges: bytes
content-type: image/png
content-length: 5969
date: Fri, 13 Jul 2018 21:52:02 GMT
expires: Fri, 13 Jul 2018 21:52:02 GMT
cache-control: private, max-age=31536000
last-modified: Thu, 08 Dec 2016 01:00:57 GMT
x-content-type-options: nosniff
View exercise.hs
#!/usr/bin/env stack
-- stack --nix --resolver lts-11.7 script
{-# LANGUAGE TypeSynonymInstances #-}
{-# LANGUAGE FlexibleInstances #-}
import Data.List
import Control.Monad
import Control.Exception (assert)
View nixops-output.txt
[ben@lithium:~/src/pprjam]$ nixops modify -d pprjam ops/production.nix && nixops deploy -d pprjam
Warning: Permanently added '' (ED25519) to the list of known hosts.
building all machine configurations...
building path(s) ‘/nix/store/jz1rq5fvi19idr126fpfj9c2sf1bal87-pprjam’
unpacking sources
unpacking source archive /nix/store/7f0rfvihfq5qlckls5rrxiazi7ifhra8-pprjam
source root is pprjam
patching sources
generated pprjam.cabal
bsima / production.nix
Last active Dec 8, 2019
View production.nix
resources.sshKeyPairs.ssh-key = {};
pprjam =
{ config, pkgs, ... }:
pprjam = (import ../release.nix { inherit pkgs; }).pprjam // {
preInstall = ''
echo "======================================================="
echo "======================================================="
View ex.elm
case msg of
AddUserResponse newUsers ->
(newUserList, cmd) =
RemoteData.update \(ls -> (List.append ls newUsers, Cmd.none)) model.users
( { model | users = newUserList }, cmd )
View ListToDict.elm
type alias VenueId =
type alias Venue =
{ id : VenueId
, name : String
type alias HappyHour =
Git Good

This is a starting point for mastering git, a sisyphean task no doubt. Git is a complex software, nobody is expected to master all of it, so if you have a useful tip, please share!

The git manual pages are actually very good. Start with man git and maybe check out man gittutorial. Don't be shy about using `man

You can’t perform that action at this time.