Ivan Dimitrov
180e38ab65
commit f97a703e0da24e9c98caad7c48cb5882471abdb1 Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Fri Dec 15 06:42:21 2023 +0200 fix build error commit dc759d9e3db46cb77cad34e72472c08553211c1c Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Thu Dec 14 18:05:53 2023 +0200 birthday easter egg maybe not working at all but whatever commit 60dbe3ffe9da67abdf3f1dc2bb3f5c0c5bf86643 Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Fri Dec 8 17:47:33 2023 +0200 newlines commit 1a7230c4d784077e4156fba4cb017cdc24391e42 Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Fri Dec 8 17:46:50 2023 +0200 links commit e1b9e5b00890f9b35e7052a8b5b12b711bfe0911 Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Fri Dec 1 15:49:52 2023 +0200 add public key and some svg shadow commit b5dfb5bfab7d4fdd3bbbfe6457a776533f69730c Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Wed Nov 29 16:32:17 2023 +0200 make it lighter commit b065b62975af24de7fd89717ea55ea67984c1b0e Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Wed Nov 29 15:58:10 2023 +0200 formatting commit bb5bd2e5f16b637680075f89e85b0f6e99851734 Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Wed Nov 29 15:57:22 2023 +0200 metadata and some optimizations commit 3d1fd8a2fa4882bbfefcf19d47df18b44d3962f9 Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Wed Nov 29 15:38:28 2023 +0200 sitemap and robots commit 327f4b7f43b6936f4b0f9dce595837faeb1ac9bf Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Wed Nov 29 10:06:47 2023 +0200 flake update commit 16e08c84c691f8bc69b5e56a2efe37d384be943b Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Tue Nov 28 19:11:41 2023 +0200 flake update commit a7eb0513e6fb22eacaa365f37ad4482272e9bc4d Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Sun Nov 26 12:59:41 2023 +0200 set build inputs to only node commit 59776102f521e20dbede3edb022305d26e69c539 Author: Ivan Dimitrov <ivan@idimitrov.dev> Date: Sun Nov 26 12:55:12 2023 +0200 making the site run on nixos
74 lines
1.9 KiB
Nix
74 lines
1.9 KiB
Nix
{
|
|
description = ''
|
|
NextJS flake
|
|
'';
|
|
|
|
inputs = {
|
|
nixpkgs.url = "nixpkgs";
|
|
ide = {
|
|
url = "github:ivandimitrov8080/flake-ide";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
};
|
|
|
|
outputs = { self, nixpkgs, ide, ... }:
|
|
let
|
|
system = "x86_64-linux";
|
|
pkgs = nixpkgs.legacyPackages.${system};
|
|
nvim = ide.nvim.${system}.standalone {
|
|
plugins = {
|
|
lsp.servers = {
|
|
html.enable = true;
|
|
tsserver.enable = true;
|
|
jsonls.enable = true;
|
|
tailwindcss.enable = true;
|
|
cssls.enable = true;
|
|
efm.enable = true;
|
|
};
|
|
efmls-configs.enable = true;
|
|
};
|
|
};
|
|
buildInputs = with pkgs; [
|
|
coreutils-full
|
|
nodejs_20
|
|
bun
|
|
nvim
|
|
];
|
|
tmuxConfig = ''
|
|
tmux new-session -s my_session -d
|
|
tmux new-window -t my_session:1
|
|
tmux new-window -t my_session:2
|
|
tmux new-window -t my_session:3
|
|
tmux send-keys -t my_session:1.0 'nvim' C-m
|
|
tmux send-keys -t my_session:3.0 'bun run dev' C-m
|
|
tmux attach-session -t my_session
|
|
'';
|
|
in
|
|
{
|
|
devShell.${system} = pkgs.mkShell {
|
|
inherit buildInputs;
|
|
shellHook = ''
|
|
${tmuxConfig}
|
|
'';
|
|
};
|
|
packages.${system}.default = pkgs.buildNpmPackage rec {
|
|
buildInputs = with pkgs; [ nodejs_20 ];
|
|
pname = "idimitrov.dev";
|
|
version = "0.0.1";
|
|
src = ./.;
|
|
npmDepsHash = "sha256-DtnXn7/FP9Ccc5qXKQezi9StKOnhZnqVSbz0HJ3TQ0g=";
|
|
postInstall = ''
|
|
mkdir -p $out/bin/
|
|
cp -r ./.next/standalone/* $out/
|
|
cp -r ./.next/standalone/.* $out/
|
|
cp -r ./.next/static $out/.next/
|
|
cp -r ./public $out/
|
|
rm -rf $out/lib
|
|
echo "${pkgs.nodejs_20}/bin/node $out/server.js" > $out/bin/$pname
|
|
chmod +x $out/bin/$pname
|
|
'';
|
|
};
|
|
};
|
|
}
|
|
|