server v1

This commit is contained in:
alisceon 2025-08-12 21:00:01 +02:00
parent 96057e337b
commit cd35565370
4 changed files with 191 additions and 7 deletions

View file

@ -6,7 +6,7 @@
programs = {
fish = {
enable = true;
enable = false;
# Disable greeting
interactiveShellInit = ''
set fish_greeting
@ -45,13 +45,14 @@
}; # end fish
nushell = {
enable = true;
configFile.source = ./conf/config.nu;
shellAliases = {
tsla-fan = "ipmitool -H 10.30.0.3 -U ADMIN -P ADMIN raw 0x30 0x70 0x66 0x01 0x0";
# NixOS commands
nixoss = "sudo nixos-rebuild switch --flake .#${hostName}";
nixos-main = "git checkout main && git pull && sudo nixos-rebuild switch --flake #${hostName}";
nixossr = "sudo nixos-rebuild switch --flake .#${hostName} && reboot";
nixos-main = "git checkout main ; git pull ; sudo nixos-rebuild switch --flake #${hostName}";
nixossr = "sudo nixos-rebuild switch --flake .#${hostName} ; reboot";
nixost = "sudo nixos-rebuild build-vm --flake .#${hostName}";
# Development commands
@ -66,10 +67,7 @@
pypod = "podman run --rm -it --network host -v '.:/run' -w '/run' python /run/";
# Tower commands
weboot = "nix shell nixpkgs#efibootmgr -c sudo efibootmgr -n 0000 && reboot";
# Misc commands
nix-shell = "nix shell";
weboot = "nix shell nixpkgs#efibootmgr -c sudo efibootmgr -n 0000 ; reboot";
};
};
git = {

24
home/conf/config.nu Normal file
View file

@ -0,0 +1,24 @@
let carapace_completer = {|spans|
carapace $spans.0 nushell ...$spans | from json
}
$env.config = {
show_banner: false,
completions: {
case_sensitive: false # case-sensitive completions
quick: true # set to false to prevent auto-selecting completions
partial: true # set to false to prevent partial filling of the prompt
algorithm: "fuzzy" # prefix or fuzzy
external: {
# set to false to prevent nushell looking into $env.PATH to find more suggestions
enable: true
# set to lower can improve completion performance at the cost of omitting some options
max_results: 100
completer: $carapace_completer # check 'carapace_completer'
}
}
}
$env.PATH = ($env.PATH |
split row (char esep) |
prepend /home/myuser/.apps |
append /usr/bin/env
)