mirror of
https://github.com/sdiehl/wiwinwlh.git
synced 2024-07-07 08:36:30 +03:00
CI for Chapter 7
This commit is contained in:
parent
d4d8cab3bd
commit
31191f9a77
|
@ -8,4 +8,8 @@
|
|||
#ssh ec2 'sudo mv nav.js /srv/http/hask/nav.js'
|
||||
|
||||
rsync --progress tutorial.html ec2:~
|
||||
rsync --progress tutorial.pdf ec2:~
|
||||
rsync --progress tutorial_print.pdf ec2:~
|
||||
ssh ec2 'sudo mv tutorial.html /srv/http/hask/index.html'
|
||||
ssh ec2 'sudo mv tutorial_print.pdf /srv/http/hask/'
|
||||
ssh ec2 'sudo mv tutorial.pdf /srv/http/hask/'
|
||||
|
|
|
@ -5,7 +5,7 @@ import qualified Data.ByteString.Char8 as S8
|
|||
|
||||
-- From pack
|
||||
bstr1 :: S.ByteString
|
||||
bstr1 = S.pack ("foo" :: String)
|
||||
bstr1 = S.pack [102, 111, 111] -- ascii encoding of foo as [Word8]
|
||||
|
||||
-- From overloaded string literal.
|
||||
bstr2 :: S.ByteString
|
||||
|
|
9
src/07-text-bytestring/ci
Executable file
9
src/07-text-bytestring/ci
Executable file
|
@ -0,0 +1,9 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
set -e
|
||||
stack exec ghc -- -e ":q" --interactive builder.hs
|
||||
stack exec ghc -- -e ":q" --interactive bytestring.hs
|
||||
#stack exec ghc -- -e ":q" --interactive overloadedlist.hs
|
||||
stack exec ghc -- -e ":q" --interactive printf.hs
|
||||
stack exec ghc -- -e ":q" --interactive regex.hs
|
||||
stack exec ghc -- -e ":q" --interactive text.hs
|
|
@ -2,10 +2,10 @@
|
|||
{-# LANGUAGE TypeFamilies #-}
|
||||
|
||||
import qualified Data.Map as Map
|
||||
import GHC.Exts (IsList(..))
|
||||
import GHC.Exts (IsList (..))
|
||||
|
||||
instance (Ord k) => IsList (Map.Map k v) where
|
||||
type Item (Map.Map k v) = (k,v)
|
||||
type Item (Map.Map k v) = (k, v)
|
||||
fromList = Map.fromList
|
||||
toList = Map.toList
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user