git.iko.soy/deriving-openapi3
on ce37cfe help sign in
.github/workflows/build.yaml+2−2
since splitsnapshots
unifiedsplit
@@ -17,7 +17,7 @@ jobs:
17 - name: Check library version
17 - name: Check library version
18 if: github.event_name == 'release'
18 if: github.event_name == 'release'
19 run: |
19 run: |
20− if [ "$(awk -F":" '{if ($1 == "version") {gsub(/ /, "", $2); print $2}}' *.cabal)" != "${{ github.event.release.tag_name }}" ]; then
20+ if [ "$(yq eval ".version" package.yaml)" != "${{ github.event.release.tag_name }}" ]; then
21 echo "::error file=action.yaml::Library version does not match release version."
21 echo "::error file=action.yaml::Library version does not match release version."
22 exit 1
22 exit 1
23 fi
23 fi
@@ -33,7 +33,7 @@ jobs:
33 path: |
33 path: |
34 ~/.stack
34 ~/.stack
35 .stack-work
35 .stack-work
36− key: ${{ runner.os }}-stack-${{ hashFiles('stack.yaml') }}-${{ hashFiles('**.cabal') }}
36+ key: ${{ runner.os }}-stack-${{ hashFiles('stack.yaml') }}-${{ hashFiles('package.yaml') }}
37 restore-keys: |
37 restore-keys: |
38 ${{ runner.os }}-stack-${{ hashFiles('stack.yaml') }}
38 ${{ runner.os }}-stack-${{ hashFiles('stack.yaml') }}
39 ${{ runner.os }}-stack
39 ${{ runner.os }}-stack
deriving-openapi3.cabal+11−2
@@ -22,6 +22,11 @@ source-repository head
22 type: git
22 type: git
23 location: https://github.com/ilyakooo0/deriving-openapi3
23 location: https://github.com/ilyakooo0/deriving-openapi3
24
24
25+flag servant-description
26+ description: Create instances for the 'Description' type from 'servant'
27+ manual: False
28+ default: True
29+
25library
30library
26 exposed-modules:
31 exposed-modules:
27 Deriving.OpenApi
32 Deriving.OpenApi
@@ -47,9 +52,13 @@ library
47 ghc-options: -Weverything -Wno-star-is-type -Wno-unsafe -Wno-prepositive-qualified-module -Wno-safe -Wno-missing-safe-haskell-mode -Wno-missing-import-lists -Wno-implicit-prelude
52 ghc-options: -Weverything -Wno-star-is-type -Wno-unsafe -Wno-prepositive-qualified-module -Wno-safe -Wno-missing-safe-haskell-mode -Wno-missing-import-lists -Wno-implicit-prelude
48 build-depends:
53 build-depends:
49 aeson
54 aeson
50− , base >=4.12
55+ , base
51− , deriving-aeson >=0.2.2
56+ , deriving-aeson
52 , lens
57 , lens
53 , openapi3
58 , openapi3
54 , text
59 , text
60+ if flag(servant-description)
61+ cpp-options: -DSERVANT_DESCRIPTION
62+ build-depends:
63+ servant
55 default-language: Haskell2010
64 default-language: Haskell2010