Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add version bounds to Text and Servant #14

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
dist/
dist-newstyle/
*~
.direnv/
1 change: 1 addition & 0 deletions lucid/.envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
use flake
27 changes: 27 additions & 0 deletions lucid/flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

68 changes: 68 additions & 0 deletions lucid/flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
{
description = "lucid-htmx";

inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
};

outputs = {
self,
nixpkgs,
}: let
forAllSystems = function:
nixpkgs.lib.genAttrs ["x86_64-linux" "aarch64-linux"] (system:
function rec {
inherit system;
compilerVersion = "ghc964";
pkgs = nixpkgs.legacyPackages.${system};
hsPkgs = pkgs.haskell.packages.${compilerVersion}.override {
overrides = hfinal: hprev:
with pkgs.haskell.lib; {
# Internal Packages
lucid-htmx = overrideCabal (hfinal.callCabal2nix "lucid-htmx" ./. {}) (drv: {checkPhase = "true";});
};
};
});
in {
formatter = forAllSystems ({pkgs, ...}: pkgs.alejandra);

# nix build
packages = forAllSystems (
{hsPkgs, ...}: {
inherit hsPkgs;
lucid-htmx = hsPkgs.lucid-htmx;
default = hsPkgs.lucid-htmx;
}
);

checks = {};

# nix develop
devShells = forAllSystems ({
system,
hsPkgs,
pkgs,
...
}: {
default = hsPkgs.shellFor {
name = "lucid-htmx";
shellHook = ''
export LOCALE_ARCHIVE="${pkgs.glibcLocales}/lib/locale/locale-archive"
export LC_ALL=C.UTF-8
'';
packages = p: [
p.lucid-htmx
];
buildInputs = with pkgs; [
hsPkgs.haskell-language-server
cabal2nix
haskellPackages.ghcid
haskellPackages.fourmolu
haskellPackages.cabal-fmt
haskellPackages.cabal-install
hlint
];
};
});
};
}
3 changes: 3 additions & 0 deletions lucid/fourmolu.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
haddock-style: single-line
haddock-style-module: multi-line
column-limit: 80
4 changes: 4 additions & 0 deletions lucid/hie.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
cradle:
cabal:
- path: "./src"
component: "lib:lucid-htmx"
92 changes: 51 additions & 41 deletions lucid/lucid-htmx.cabal
Original file line number Diff line number Diff line change
@@ -1,57 +1,67 @@
cabal-version: 1.12

-- This file has been generated from package.yaml by hpack version 0.35.1.
--
-- see: https://github.com/sol/hpack

name: lucid-htmx
version: 0.1.0.7
synopsis: Use htmx in your lucid templates
description: Please see the README on GitHub at <https://github.com/monadicsystems/lucid-htmx#readme>
category: Web, HTML
homepage: https://github.com/monadicsystems/lucid-htmx#readme
bug-reports: https://github.com/monadicsystems/lucid-htmx/issues
author: Monadic Systems LLC
maintainer: [email protected]
copyright: 2022 Monadic Systems LLC
license: BSD3
license-file: LICENSE
build-type: Simple
cabal-version: 3.6
name: lucid-htmx
version: 0.1.0.7
synopsis: Use htmx in your lucid templates
description:
Please see the README on GitHub at <https://github.com/monadicsystems/lucid-htmx#readme>

category: Web, HTML
homepage: https://github.com/monadicsystems/lucid-htmx#readme
bug-reports: https://github.com/monadicsystems/lucid-htmx/issues
author: Monadic Systems LLC
maintainer: [email protected]
copyright: 2022 Monadic Systems LLC
license: BSD-3-Clause
license-file: LICENSE
build-type: Simple
extra-source-files:
README.md
ChangeLog.md
ChangeLog.md
README.md

source-repository head
type: git
type: git
location: https://github.com/monadicsystems/lucid-htmx

common def-exts
default-extensions:
LambdaCase
OverloadedStrings

library
import: def-exts

-- cabal-fmt: expand src
exposed-modules:
Lucid.Htmx
Lucid.Htmx.Servant
other-modules:
Paths_lucid_htmx
hs-source-dirs:
src
Lucid.Htmx
Lucid.Htmx.Core
Lucid.Htmx.Event
Lucid.Htmx.Extension
Lucid.Htmx.Extra
Lucid.Htmx.Head
Lucid.Htmx.Render
Lucid.Htmx.Servant

other-modules: Paths_lucid_htmx
hs-source-dirs: src
build-depends:
base >=4.7 && <5
, lucid >=2.9.12.1 && <=2.11.20230408
, servant
, text
, base >=4.7 && <5
, lucid >=2.9.12.1 && <2.11.20230408.0
, servant >=0.19 && <0.30
, text >=2 && <3
default-language: Haskell2010

test-suite lucid-htmx-test
type: exitcode-stdio-1.0
main-is: Spec.hs
other-modules:
Paths_lucid_htmx
hs-source-dirs:
test
ghc-options: -threaded -rtsopts -with-rtsopts=-N
import: def-exts
type: exitcode-stdio-1.0
main-is: Spec.hs
other-modules: Paths_lucid_htmx
hs-source-dirs: test
ghc-options: -threaded -rtsopts -with-rtsopts=-N
build-depends:
base >=4.7 && <5
, lucid >=2.9.12.1 && <=2.11.20230408
, base >=4.7 && <5
, lucid >=2.9.12.1 && <2.11.20230408.0
, lucid-htmx
, servant
, text

default-language: Haskell2010
Loading