git.iko.soy/typeable/cabal2nix
on master help sign in
doc: add slides for the hal8 presentation
commit8ec496d46609ea31d8f6bd882d1232bade3581ed authorPeter Simons <simons@cryp.to> dateThu 20 Jun 2013, 15:05 (13 years ago) parentf5224f6
2 files changed+109
doc/.gitignore+1 doc/hal8-folien.md+108
doc/.gitignore+1
@@ -3,3 +3,4 @@
33/hal8.log
44/hal8.out
55/hal8.pdf
6+/hal8-folien.pdf
doc/hal8-folien.mdnew file+108
@@ -0,0 +1,108 @@
1+% Managing the Haskell Dependency Hell with Nix
2+% Peter Simons \<simons@cryp.to\>
3+% 2013-06-21
4+
5+# Ablauf der Präsentation
6+
7+1) Vorstellung des Nix Paket-Managers
8+
9+ - Übersicht der besonderen Features
10+ - Der Paket-Store
11+ - Nix als Programmiersprache
12+
13+2) Installation von Haskell-Paketen
14+
15+ - Einfache Installation
16+ - Mehrere Versionen gleichzeitig installieren
17+ - Funktionsweise von `ghc-wrapper`
18+ - Nix in Kombination mit `cabal-dev`
19+
20+3) Erweiterung der Nix Paket-Datenbank
21+
22+ - Der `cabal2nix` Konverter
23+
24+4) Continuous-Integration mit der Hydra Build-Farm
25+
26+5) Fragen & Antworten
27+
28+# Was ist Nix und warum will ich das wissen?
29+
30+- Nix ist ein rein funktionaler Paket-Manager.
31+
32+- Nix kann mehrere Paket-Versionen gleichzeitig installieren.
33+
34+- Nix garantiert, dass alle Paket-Abhängigkeiten bekannt sind.
35+
36+- Nix erlaubt atomische Updates.
37+
38+- Nix erlaubt das Zurücknehmen von Updates.
39+
40+- Nix erlaubt die Installation von Binär-Paketen.
41+
42+- Nix ist unabhängig vom Betriebsystem.
43+
44+- Nix hat erstklassige Unterstützung für Multi-User-Systeme.
45+
46+- Nix ist freie Software unter GNU LGPL 2.1.
47+
48+# Der Nix Paket-Store
49+
50+- Nix lebt komplett unterhalb des Verzeichnisses `/nix`.
51+
52+ - Nix deinstallieren: `rm -rf /nix`
53+ - Backup erstellen: `tar cfz nix-backup.tar.gz /nix`
54+
55+- Meta-Daten liegen unterhalb von `/nix/var`.
56+
57+- Alle Pakete werden unterhalb von `/nix/store` installiert:
58+
59+ /nix/store/3768znryvs7nmnr3p2cdlr95hj-ghc-6.12.3
60+ /nix/store/8z0v9s56nc2f5zgdn6hgzchwba-ghc-7.0.4
61+ /nix/store/njwikqrziy7nsc18bpxlvncq1q-ghc-7.6.3
62+
63+- In `/nix/store` installierte Pakete referenzieren niemals
64+ Dateien außerhalb des Stores.
65+
66+# Das Nix-Programm für `parsec 3.1.3`
67+
68+ { cabal, mtl, text }:
69+
70+ cabal.mkDerivation (self: {
71+ pname = "parsec";
72+ version = "3.1.3";
73+ sha256 = "1a64gzirgpa1i78gbbp9z059nh29xmcja4g8vgjb1";
74+ buildDepends = [ mtl text ];
75+ })
76+
77+# Installation von `parsec 3.1.3`
78+
79+ $ nix-env -iA haskellPackages.parsec_3_1_3
80+ installing `haskell-parsec-ghc7.6.3-3.1.3'
81+ these paths will be fetched:
82+ /nix/store/09zlb...-haskell-parsec-ghc7.6.3-3.1.3
83+ /nix/store/4p1rb...-haskell-mtl-ghc7.6.3-2.1.2
84+ /nix/store/i0k3s...-haskell-text-ghc7.6.3-0.11.3.1
85+ /nix/store/q8163...-haskell-transformers-ghc7.6.3-0.3.0.0
86+ [...]
87+ building path(s) `/nix/store/0xfxh1ncksix601m9n71fw1wkfhmsjjz-user-environment'
88+ created 22 symlinks in user environment
89+
90+# Das Nix-Programm für `yesod 1.2.1`
91+
92+ { cabal, aeson, blazeHtml, blazeMarkup, dataDefault,
93+ , hamlet monadControl, networkConduit, safe,
94+ , shakespeareCss shakespeareJs text, transformers,
95+ , unorderedContainers wai, waiExtra, warp yaml,
96+ , yesodAuth, yesodCore yesodForm, yesodPersistent
97+ }:
98+ cabal.mkDerivation (self: {
99+ pname = "yesod";
100+ version = "1.2.1";
101+ sha256 = "19gwhav6sr6gd2kh92ga8a09hq9grllmnacdqk6zg";
102+ buildDepends = [ aeson blazeHtml blazeMarkup
103+ dataDefault hamlet monadControl networkConduit safe
104+ shakespeareCss shakespeareJs text transformers
105+ unorderedContainers wai waiExtra warp yaml yesodAuth
106+ yesodCore yesodForm yesodPersistent
107+ ];
108+ })