Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

3 anos atrás
3 anos atrás
12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. # Skeleton Haskell Flake
  2. included is my attempt at a bare bones haskell project, implemented as a nix flake in order to allow reproducible builds.
  3. ## building
  4. allows usage within `nix shell`, assuming a flakes system, with the followng:
  5. ```
  6. nix shell github:techieAgnostic/haskeleton
  7. ```
  8. otherwise it can be built normally with:
  9. ```
  10. nix build.
  11. ```
  12. or added to a system configuration by creating an input:
  13. ```
  14. inputs.haskeleton.url = "github:techieAgnostic/haskeleton";
  15. ```
  16. and using the `haskeleton.overlay` attribute to import the program into your pkgset.
  17. ## adding hackage dependencies
  18. dependencies can be added to the `haskeleton.cabal` file as normal. the `haskeleton.nix` file must be regenerated once this happens.
  19. > !!!important!!!
  20. in order for this to work without manual editing of `haskeleton.nix`, the command must be run from the `./nix` directory.
  21. ```
  22. cd ./nix
  23. cabal2nix ../ > haskeleton.nix
  24. ```
  25. for packages not in the nixpkgs repository, or that you would like to have a different version of than appears in the repo, you can add them to the `./nix` directory manually like so:
  26. ```
  27. cabal2nix cabal://name-version > ./nix/name.nix
  28. ```
  29. and in order to disable building tests, documentation, or to jailbreak the dependencies of a package (should the build fail for those reasons), add the packages name to the lists defined in `./release.nix`.