Skip to content

Commit

Permalink
Add hlint into CI, revDiv func and author
Browse files Browse the repository at this point in the history
  • Loading branch information
KubEF committed Dec 14, 2023
1 parent d3d9afa commit 6732f49
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 8 deletions.
13 changes: 13 additions & 0 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,16 @@ jobs:
run: stack build --system-ghc --test --bench --no-run-tests --no-run-benchmarks
- name: Run tests
run: stack test
hlint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: "Set up HLint"
uses: haskell/actions/hlint-setup@v2

- name: "Run HLint"
uses: haskell/actions/hlint-run@v2
with:
path: src/
fail-on: warning
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright Author name here (c) 2023
Copyright Kubishkin Efim (c) 2023

All rights reserved.

Expand Down
10 changes: 5 additions & 5 deletions package.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: matrix-lib-proj
version: 0.1.0.0
github: "githubuser/matrix-lib-proj"
github: "KubEF/matrix-lib-proj"
license: BSD3
author: "Author name here"
maintainer: "[email protected]"
copyright: "2023 Author name here"
author: "Kubishkin Efim"
maintainer: "[email protected]"
copyright: "2023 Kubishkin Efim"

extra-source-files:
- README.md
Expand All @@ -17,7 +17,7 @@ extra-source-files:
# 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/matrix-lib-proj#readme>
description: Please see the README on GitHub at <https://github.com/KubEF/matrix-lib#readme>

dependencies:
- base >= 4.7 && < 5
Expand Down
6 changes: 4 additions & 2 deletions src/Helpers.hs
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,7 @@ tupleToList2 (a, b) = [a, b]
triplePart :: [a] -> [[a]]
triplePart l = [[l !! n, l !! (n + 1), l !! (n + 2)] | n <- [0, 2 .. (length l - 3)]]

lsEvenWithOne :: (Num a, Enum a) => a -> [a]
lsEvenWithOne n = 1 : [2, 4 .. n]
lsEvenWithOne :: (Integral a) => a -> [a]
lsEvenWithOne n
| even n = 1 : [2, 4 .. n]
| otherwise = 1 : [2, 4 .. n + 1]

0 comments on commit 6732f49

Please sign in to comment.