-
-
Notifications
You must be signed in to change notification settings - Fork 73
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* [#281] Add example Cabal and Stack projects Resolves #281 * Patch formatting * Update tests on CI * Add extra-source-files * Fix stack test on CI
- Loading branch information
Showing
63 changed files
with
909 additions
and
134 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
13 changes: 7 additions & 6 deletions
13
...lden/fullProject/.github/workflows/ci.yml → ...mples/cabal-full/.github/workflows/ci.yml
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
### Haskell | ||
dist | ||
dist-* | ||
cabal-dev | ||
*.o | ||
*.hi | ||
*.chi | ||
*.chs.h | ||
*.dyn_o | ||
*.dyn_hi | ||
*.prof | ||
*.aux | ||
*.hp | ||
*.eventlog | ||
.virtualenv | ||
.hsenv | ||
.hpc | ||
.cabal-sandbox/ | ||
cabal.sandbox.config | ||
cabal.config | ||
cabal.project.local | ||
.ghc.environment.* | ||
.HTF/ | ||
# Stack | ||
.stack-work/ | ||
stack.yaml.lock | ||
|
||
### IDE/support | ||
# Vim | ||
[._]*.s[a-v][a-z] | ||
[._]*.sw[a-p] | ||
[._]s[a-v][a-z] | ||
[._]sw[a-p] | ||
*~ | ||
tags | ||
|
||
# IntellijIDEA | ||
.idea/ | ||
.ideaHaskellLib/ | ||
*.iml | ||
|
||
# Atom | ||
.haskell-ghc-mod.json | ||
|
||
# VS | ||
.vscode/ | ||
|
||
# Emacs | ||
*# | ||
.dir-locals.el | ||
TAGS | ||
|
||
# other | ||
.DS_Store |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
sudo: true | ||
language: haskell | ||
|
||
git: | ||
depth: 5 | ||
|
||
cabal: "2.4" | ||
|
||
cache: | ||
directories: | ||
- "$HOME/.cabal/store" | ||
|
||
|
||
matrix: | ||
include: | ||
- ghc: 8.4.4 | ||
- ghc: 8.6.5 | ||
- ghc: 8.8.2 | ||
|
||
|
||
install: | ||
# HLint check | ||
- curl -sSL https://raw.github.com/ndmitchell/neil/master/misc/travis.sh | sh -s -- hlint . | ||
|
||
- cabal v2-update | ||
- cabal v2-build --enable-tests --enable-benchmarks | ||
|
||
script: | ||
- cabal v2-test --enable-tests | ||
|
||
notifications: | ||
email: false |
4 changes: 2 additions & 2 deletions
4
...-cli/test/golden/fullProject/CHANGELOG.md → ...oner-cli/examples/cabal-full/CHANGELOG.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
# Changelog | ||
|
||
`fullProject` uses [PVP Versioning][1]. | ||
`cabal-full` uses [PVP Versioning][1]. | ||
The changelog is available [on GitHub][2]. | ||
|
||
## 0.0.0.0 | ||
|
||
* Initially created. | ||
|
||
[1]: https://pvp.haskell.org | ||
[2]: https://github.com/kowainik/fullProject/releases | ||
[2]: https://github.com/kowainik/cabal-full/releases |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
BSD 3-Clause License | ||
|
||
Copyright (c) 2020, Kowainik | ||
All rights reserved. | ||
|
||
Redistribution and use in source and binary forms, with or without | ||
modification, are permitted provided that the following conditions are met: | ||
|
||
1. Redistributions of source code must retain the above copyright notice, this | ||
list of conditions and the following disclaimer. | ||
|
||
2. Redistributions in binary form must reproduce the above copyright notice, | ||
this list of conditions and the following disclaimer in the documentation | ||
and/or other materials provided with the distribution. | ||
|
||
3. Neither the name of the copyright holder nor the names of its | ||
contributors may be used to endorse or promote products derived from | ||
this software without specific prior written permission. | ||
|
||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE | ||
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR | ||
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER | ||
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, | ||
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# cabal-full | ||
|
||
[![GitHub CI](https://github.com/kowainik/cabal-full/workflows/CI/badge.svg)](https://github.com/kowainik/cabal-full/actions) | ||
[![Build status](https://img.shields.io/travis/kowainik/cabal-full.svg?logo=travis)](https://travis-ci.org/kowainik/cabal-full) | ||
[![Windows build status](https://ci.appveyor.com/api/projects/status/github/kowainik/cabal-full?branch=master&svg=true)](https://ci.appveyor.com/project/kowainik/cabal-full) | ||
[![Hackage](https://img.shields.io/hackage/v/cabal-full.svg?logo=haskell)](https://hackage.haskell.org/package/cabal-full) | ||
[![BSD-3-Clause license](https://img.shields.io/badge/license-BSD--3--Clause-blue.svg)](LICENSE) | ||
|
||
Cabal-only example with all integrations |
2 changes: 1 addition & 1 deletion
2
...r-cli/test/golden/fullProject/app/Main.hs → summoner-cli/examples/cabal-full/app/Main.hs
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
module Main (main) where | ||
|
||
import FullProject (someFunc) | ||
import CabalFull (someFunc) | ||
|
||
|
||
main :: IO () | ||
|
File renamed without changes.
File renamed without changes.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
cabal-version: 2.4 | ||
name: cabal-full | ||
version: 0.0.0.0 | ||
synopsis: Cabal-only example with all integrations | ||
description: Cabal-only example with all integrations | ||
homepage: https://github.com/kowainik/cabal-full | ||
bug-reports: https://github.com/kowainik/cabal-full/issues | ||
license: BSD-3-Clause | ||
license-file: LICENSE | ||
author: Kowainik | ||
maintainer: Kowainik <xrom.xkov@gmail.com> | ||
copyright: 2020 Kowainik | ||
category: Testing | ||
build-type: Simple | ||
extra-doc-files: README.md | ||
CHANGELOG.md | ||
tested-with: GHC == 8.4.4 | ||
GHC == 8.6.5 | ||
GHC == 8.8.2 | ||
|
||
source-repository head | ||
type: git | ||
location: https://github.com/kowainik/cabal-full.git | ||
|
||
common common-options | ||
build-depends: base >= 4.11.1.0 && < 4.14 | ||
, relude | ||
|
||
mixins: base hiding (Prelude) | ||
, relude (Relude as Prelude) | ||
|
||
ghc-options: -Wall | ||
-Wcompat | ||
-Widentities | ||
-Wincomplete-uni-patterns | ||
-Wincomplete-record-updates | ||
if impl(ghc >= 8.0) | ||
ghc-options: -Wredundant-constraints | ||
if impl(ghc >= 8.2) | ||
ghc-options: -fhide-source-paths | ||
if impl(ghc >= 8.4) | ||
ghc-options: -Wmissing-export-lists | ||
-Wpartial-fields | ||
if impl(ghc >= 8.8) | ||
ghc-options: -Wmissing-deriving-strategies | ||
|
||
default-language: Haskell2010 | ||
default-extensions: DeriveGeneric | ||
TypeApplications | ||
|
||
library | ||
import: common-options | ||
hs-source-dirs: src | ||
exposed-modules: CabalFull | ||
|
||
executable cabal-full | ||
import: common-options | ||
hs-source-dirs: app | ||
main-is: Main.hs | ||
build-depends: cabal-full | ||
ghc-options: -threaded | ||
-rtsopts | ||
-with-rtsopts=-N | ||
|
||
test-suite cabal-full-test | ||
import: common-options | ||
type: exitcode-stdio-1.0 | ||
hs-source-dirs: test | ||
main-is: Spec.hs | ||
build-depends: cabal-full | ||
ghc-options: -threaded | ||
-rtsopts | ||
-with-rtsopts=-N | ||
|
||
benchmark cabal-full-benchmark | ||
import: common-options | ||
type: exitcode-stdio-1.0 | ||
hs-source-dirs: benchmark | ||
main-is: Main.hs | ||
build-depends: gauge | ||
, cabal-full | ||
ghc-options: -threaded | ||
-rtsopts | ||
-with-rtsopts=-N |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{- | | ||
Copyright: (c) 2020 Kowainik | ||
SPDX-License-Identifier: BSD-3-Clause | ||
Maintainer: Kowainik <xrom.xkov@gmail.com> | ||
Cabal-only example with all integrations | ||
-} | ||
|
||
module CabalFull | ||
( someFunc | ||
) where | ||
|
||
|
||
someFunc :: IO () | ||
someFunc = putStrLn ("someFunc" :: String) |
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...cli/test/golden/smallProject/CHANGELOG.md → ...r-cli/examples/cabal-minimal/CHANGELOG.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# Changelog | ||
|
||
`smallProject` uses [PVP Versioning][1]. | ||
`cabal-minimal` uses [PVP Versioning][1]. | ||
|
||
## 0.0.0.0 | ||
|
||
|
Oops, something went wrong.