Go through the following from within the project root.
This will:
- Move
~/.ghc
to avoid a known bug - Create a user-writable
/app
for building - Clone the halcyon build tool into
/app
- Remove any current build artifacts
module Main where | |
import Data.Maybe | |
import Debug.Trace | |
import Data.JSON | |
import Network.XHR | |
main = get defaultAjaxOptions | |
{ onReadyStateChange = onSuccess $ \response -> do | |
txt <- getResponseText response |
FROM ubuntu:14.04 | |
RUN apt-get update && apt-get install -y build-essential git pigz zlib1g-dev vim curl libpq-dev | |
ADD . /halcyon | |
RUN ["/halcyon/halcyon", "paths"] | |
ENTRYPOINT ["/halcyon/halcyon"] |
Go through the following from within the project root.
This will:
~/.ghc
to avoid a known bug/app
for building/app
module InstanceLoop where | |
record Target (A : Set) : Set where | |
constructor mkTarget | |
field | |
a : A | |
instance | |
loop : {A : Set} {{tA : Target A}} → Target A |
{-# LANGUAGE QuasiQuotes, TemplateHaskell, TypeFamilies, MultiParamTypeClasses, OverloadedStrings #-} | |
{-# LANGUAGE GADTs #-} | |
{-# LANGUAGE RecordWildCards #-} | |
{-# LANGUAGE EmptyDataDecls #-} | |
import Yesod | |
import System.Environment (getArgs) | |
import qualified Network.Wai.Handler.Warp as Warp | |
import Data.Text (Text) | |
import Data.Conduit.Pool (Pool) | |
import Database.Persist.Store (get, PersistValue (PersistInt64)) |
module Foo where | |
foreign export ccall foo :: Int -> IO Int | |
foo :: Int -> IO Int | |
foo n = return (length (f n)) | |
f :: Int -> [Int] | |
f 0 = [] | |
f n = n:(f (n-1)) |
infix 1000 ♯_ | |
postulate | |
∞ : ∀ {a} (A : Set a) → Set a | |
♯_ : ∀ {a} {A : Set a} → A → ∞ A | |
♭ : ∀ {a} {A : Set a} → ∞ A → A | |
{-# BUILTIN INFINITY ∞ #-} | |
{-# BUILTIN SHARP ♯_ #-} | |
{-# BUILTIN FLAT ♭ #-} |
module Scratch where | |
postulate | |
Inf : ∀ {a} (A : Set a) → Set a | |
delay : ∀ {a} {A : Set a} → A → Inf A | |
force : ∀ {a} {A : Set a} → Inf A → A | |
{-# BUILTIN INFINITY Inf #-} | |
{-# BUILTIN SHARP delay #-} | |
{-# BUILTIN FLAT force #-} |
digraph { | |
"Vannevar Bush" -> "Claude Shannon"; | |
"Claude Shannon" -> "Ivan Sutherland"; | |
subgraph ailab { | |
rank = same; | |
edge[dir=none]; | |
"Seymour Papert" -> "Marvin Minsky"; |