flake.nix

{
  description = "jake website";

  inputs = {
    nixpkgs.url = "nixpkgs/nixos-unstable";
    utils.url = "github:numtide/flake-utils";

    # Used for shell.nix
    flake-compat = {
      url = github:edolstra/flake-compat;
      flake = false;
    };
  };

  outputs = { self, nixpkgs, utils, ... } @ inputs:
    utils.lib.eachDefaultSystem (system:
      let
        inherit (lib) attrValues;
        pkgs = import nixpkgs { inherit system; };
        lib = pkgs.lib;

        site = pkgs.writeScriptBin "site" ''
          #!${pkgs.stdenv.shell}
          ${pkgs.bun}/bin/bun run main -- $@
        '';

        dev = pkgs.writeScriptBin "dev" ''
          #!${pkgs.stdenv.shell}
          ${pkgs.bun}/bin/bun run dev -- $@
        '';

      in rec {
        devShell = with pkgs; mkShell {
          name = "site";
          buildInputs = [
            bun
            # inotify-tools

            site
            dev
          ];

          LD_LIBRARY_PATH = "${pkgs.lib.makeLibraryPath(with pkgs; [openssl sqlite])}:LD_LIBRARY_PATH";
        };
      });
}
Revisions
DateHash
2024-04-13
2024-01-28
2023-11-07
2023-10-22
2023-10-21
2023-10-20
2023-05-31
2023-05-24
2023-05-24
2023-04-23
2023-04-22
2023-04-22
2023-04-22
2023-03-10
2023-02-24
2023-02-22
2023-01-18
2022-12-31
2022-09-20
Navigation
Previouspackage.json
Nexttsconfig.json
Upsite