flake.nix 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. {
  2. description = "A custom synchronization tool";
  3. inputs = {
  4. nixpkgs.url = "github:NixOS/nixpkgs";
  5. utils.url = "github:numtide/flake-utils";
  6. };
  7. outputs = { self, nixpkgs, utils }:
  8. utils.lib.eachDefaultSystem (
  9. system:
  10. let
  11. pkgs = import nixpkgs { inherit system; };
  12. in
  13. rec {
  14. packages = rec {
  15. sync-it = pkgs.rustPlatform.buildRustPackage rec {
  16. name = "sync-it";
  17. version = "1.5.0";
  18. src = ./.;
  19. cargoSha256 = "1/UpgXhwd+vVg4eUYCEokXSAPtdyJxZCSweCJf84uiU=";
  20. meta = with pkgs.stdenv.lib; {
  21. description = "A simple, customizable synchronization tool.";
  22. license = licenses.gpl3Plus;
  23. maintainers = with maintainers; [ swflint ];
  24. };
  25. };
  26. devEnvironment = pkgs.mkShell {
  27. name = "sync-it-dev-environment";
  28. buildInputs = [
  29. pkgs.pre-commit
  30. pkgs.rustc
  31. pkgs.cargo
  32. pkgs.rls
  33. pkgs.clippy
  34. pkgs.rustfmt
  35. pkgs.sloc
  36. ];
  37. };
  38. };
  39. defaultPackage = packages.sync-it;
  40. devShell = packages.devEnvironment;
  41. }
  42. );
  43. }