Created
March 15, 2020 01:25
-
-
Save kayvank/081797b53c72bede05727d4b35e72b9c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
λ kayvan [workspace-haskell/monday-morning/MyFirstProject] → hpack && stack build | pbcopy | |
generated MyFirstProject.cabal | |
Stack has not been tested with GHC versions above 8.6, and using 8.8.2, this may fail | |
Stack has not been tested with Cabal versions above 2.4, but version 3.0.1.0 was found, this may fail | |
MyFirstProject> configure (lib + exe) | |
Configuring MyFirstProject-0.1.0.0... | |
MyFirstProject> build (lib + exe) | |
Preprocessing library for MyFirstProject-0.1.0.0.. | |
Building library for MyFirstProject-0.1.0.0.. | |
Preprocessing executable 'new-exec' for MyFirstProject-0.1.0.0.. | |
Building executable 'new-exec' for MyFirstProject-0.1.0.0.. | |
Warning: Enabling workaround for Main module 'Main' listed in 'other-modules' | |
illegally! | |
Preprocessing executable 'MyFirstProject-exe' for MyFirstProject-0.1.0.0.. | |
Building executable 'MyFirstProject-exe' for MyFirstProject-0.1.0.0.. | |
/home/kayvan/dev/workspaces/workspace-haskell/monday-morning/MyFirstProject/app/NewExec.hs:1:8: error: | |
File name does not match module name: | |
Saw: ‘Main’ | |
Expected: ‘NewExec’ | |
| | |
1 | module Main where | |
| ^^^^ | |
-- While building package MyFirstProject-0.1.0.0 using: | |
/home/kayvan/.stack/setup-exe-cache/x86_64-linux-tinfo6/Cabal-simple_mPHDZzAJ_3.0.1.0_ghc-8.8.2 --builddir=.stack-work/dist/x86_64-linux-tinfo6/Cabal-3.0.1.0 build lib:MyFirstProject exe:MyFirstProject-exe exe:new-exec --ghc-options "" | |
Process exited with code: ExitFailure 1 | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main where | |
import Split.LibSplit | |
main :: IO() | |
main = do | |
input <- getLine | |
let result = ourSplit input | |
print result | |
--------------------------- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: MyFirstProject | |
version: 0.1.0.0 | |
github: "githubuser/MyFirstProject" | |
license: BSD3 | |
author: "Author name here" | |
maintainer: "[email protected]" | |
copyright: "2020 Author name here" | |
extra-source-files: | |
- README.md | |
- ChangeLog.md | |
# Metadata used when publishing your package | |
# synopsis: Short description of your package | |
# category: Web | |
# To avoid duplicated efforts in documentation and dealing with the | |
# complications of embedding Haddock markup inside cabal files, it is | |
# common to point users to the README.md file. | |
description: Please see the README on GitHub at <https://github.com/githubuser/MyFirstProject#readme> | |
dependencies: | |
- base >= 4.7 && < 5 | |
library: | |
source-dirs: src | |
exposed-modules: | |
- Lib | |
- Split.LibSplit | |
dependencies: | |
- split | |
executables: | |
MyFirstProject-exe: | |
main: Main.hs | |
source-dirs: app/ | |
ghc-options: | |
- -threaded | |
- -rtsopts | |
- -with-rtsopts=-N | |
dependencies: | |
- MyFirstProject | |
new-exec: | |
source-dirs: app/ | |
main: NewExec.hs | |
dependencies: | |
- MyFirstProject | |
tests: | |
MyFirstProject-test: | |
main: Spec.hs | |
source-dirs: test | |
ghc-options: | |
- -threaded | |
- -rtsopts | |
- -with-rtsopts=-N | |
dependencies: | |
- MyFirstProject |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment