helix ++ + llm.nx2.site trying

This commit is contained in:
Lennart J. Kurzweg (Nx2)
2024-05-08 02:13:08 +02:00
parent 8d1a58d42c
commit 2db49fe4c6
3 changed files with 22 additions and 13 deletions

View File

@@ -1,12 +1,18 @@
{ config, pkgs, rice, ... }:
{
home.packages = with pkgs; [
helix
nixfmt # nix formater
nil # nix language server
python311Packages.python-lsp-server
];
home = {
packages = with pkgs; [
helix
nixfmt # nix formater
nil # nix language server
python311Packages.python-lsp-server
];
sessionVariables = {
EDITOR = "hx";
VISUAL = "hx";
};
};
programs.helix = {
enable = true;
settings = {

View File

@@ -17,18 +17,17 @@ lib.mkIf (user != "tv")
sort_reverse = false;
sort_dir_first = true;
linemode = "size";
show_hidden = true;
show_hidden = false;
show_symlink = true;
};
opener = {
edit = [
{ exec = ''micro "$@"''; desc = "micro"; block = true;}
{ exec = ''hx "$@"''; desc = "helix"; block = true;}
{ exec = ''codium "$@"''; orphan = true;}
{ exec = ''nano "$@"''; desc = "nano"; block = true;}
{ exec = ''sudo nano "$@"''; desc = "sudo nano"; block = true;}
];
play = [
{ exec = ''mpv "$@"''; }
{ exec = ''mpv "$@"''; }
{ exec = ''mediainfo "$1"; echo "Press enter to exit"; read''; block = true; desc = "Show mediainfo";}
];
archive = [
@@ -53,4 +52,4 @@ lib.mkIf (user != "tv")
];
};
};
}
}

View File

@@ -1,12 +1,16 @@
{ config, pkgs, lib, system, user, allowed, secrets, ... }:
{ config, pkgs, lib, system, user, host, allowed, secrets, ... }:
{
environment.systemPackages = with pkgs; [
ollama
];
services.ollama.environmentVariables = {
OLLAMA_ORIGINS = "*";
};
systemd.services.ollama = {
environment.OLLAMA_ORIGINS = "*";
description = "Ollama Service";
after = [ "network-online.target" "ollama-doesnt-respect-xdg-data-home.service" ];
serviceConfig = {
@@ -36,4 +40,4 @@
chown ollama:ollama -R /usr/share/ollama
'';
};
}
}