proper scrolls

This commit is contained in:
EatThePooh 2025-08-02 05:10:30 +07:00
parent d92bc3b437
commit 9df3f362fe
11 changed files with 146 additions and 36 deletions

View file

@ -10,39 +10,19 @@
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = nixpkgs.legacyPackages.${system};
toDenoTarget = system:
let
arch = builtins.head (builtins.split "-" system);
os = builtins.elemAt (builtins.split "-" system) 1;
vendor = if os == "darwin" then "apple" else "unknown";
sys = if os == "darwin" then "darwin" else "linux-gnu";
in "${arch}-${vendor}-${sys}";
target = toDenoTarget system;
hjq = import ./shelf/hjq/package.nix {
inherit pkgs;
inherit target;
denoWorkspace = import ./shelf/deno-workspace.nix {
inherit pkgs system;
};
in
{
devShells.default = pkgs.mkShell {
buildInputs = with pkgs; [
deno
hjq
];
shellHook = ''
echo "🦕 Deno development environment loaded!"
echo "Deno version: $(deno --version | head -n1)"
'';
DENO_DIR = "./.deno_cache";
};
# unfortunately this derivation is impure because
# managing deno's deps is HARD, so
# nix build --option sanbox relaxed
packages.default = hjq;
});
{
devShells.default = pkgs.mkShell {
buildInputs = [ ];
shellHook = ''
export DENO_DIR=$PWD/.deno_cache
rm -rf $DENO_DIR
cp -r ${denoWorkspace} $DENO_DIR
chmod -R u+w "$DENO_DIR"
'';
};
});
}