Skip to content

Commit

Permalink
Add Stack project template
Browse files Browse the repository at this point in the history
Relates to #4
  • Loading branch information
rvl committed Mar 4, 2019
1 parent a573469 commit 978e73b
Show file tree
Hide file tree
Showing 6 changed files with 150 additions and 0 deletions.
20 changes: 20 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
Copyright (c) 2019 IOHK

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to
do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

7 changes: 7 additions & 0 deletions app/server/Main.hs
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
module Main where

import Prelude
import Cardano.Wallet (sayHello)

main :: IO ()
main = sayHello
101 changes: 101 additions & 0 deletions cardano-wallet.cabal
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
name: cardano-wallet
version: 2.0.0
synopsis: The Wallet Backend for a Cardano node.
description: Please see README.md
homepage: https://github.com/input-output-hk/cardano-wallet
author: IOHK Engineering Team
maintainer: [email protected]
copyright: 2019 IOHK
license: MIT
license-file: LICENSE
category: Web
build-type: Simple
extra-source-files: README.md
cabal-version: >=1.10

library
default-language:
Haskell2010
default-extensions:
NoImplicitPrelude
OverloadedStrings
ghc-options:
-Wall
-Werror
-Wcompat
-fwarn-redundant-constraints

build-depends:
base

-- Hackage Dependencies
, aeson
, aeson-pretty
, base16-bytestring
, base58-bytestring
, bytestring
, cborg
, containers
, cryptonite
, deepseq
, digest
, generic-lens
, http-client
, memory
, microlens
, text
, time
, transformers

-- Other Project Dependencies
, cardano-crypto

hs-source-dirs:
src
exposed-modules:
Cardano.Wallet
other-modules:
Paths_cardano_wallet


executable cardano-wallet-server
default-language:
Haskell2010
default-extensions:
NoImplicitPrelude
OverloadedStrings
ghc-options:
-threaded -rtsopts
-Wall
-O2

build-depends:
base
, cardano-wallet

hs-source-dirs:
app/server
main-is:
Main.hs

test-suite unit
default-language:
Haskell2010
default-extensions:
NoImplicitPrelude
OverloadedStrings
ghc-options:
-threaded -rtsopts
-Wall
-Werror
-O2

build-depends:
base
, cardano-wallet
type:
exitcode-stdio-1.0
hs-source-dirs:
test/unit
main-is:
Main.hs
8 changes: 8 additions & 0 deletions src/Cardano/Wallet.hs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
module Cardano.Wallet
( sayHello
) where

import Prelude

sayHello :: IO ()
sayHello = putStrLn "Hello, brave new world!"
10 changes: 10 additions & 0 deletions stack.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
resolver: lts-13.8
packages:
- .

extra-deps:
- base58-bytestring-0.1.0
- generic-lens-1.1.0.0

- git: https://github.com/input-output-hk/cardano-crypto
commit: 3c5db489c71a4d70ee43f5f9b979fcde3c797f2a
4 changes: 4 additions & 0 deletions test/unit/Main.hs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import Prelude

main :: IO ()
main = putStrLn "Test suite not yet implemented"

0 comments on commit 978e73b

Please sign in to comment.