Compare commits

..

2 Commits

Author SHA1 Message Date
5d20b1d45a oh-my-posh setup 2024-11-11 15:36:39 +01:00
b8ca55b940 Cleanup after reinstall 2024-11-11 15:36:09 +01:00
6 changed files with 162 additions and 32 deletions

View File

@ -10,7 +10,7 @@ general {
background {
monitor =
path = /home/foglar/mysystem/nixos/aurora_borealis.png
path = /home/foglar/dotfiles/nixos/aurora_borealis.png
color = rgba(25, 20, 20, 1.0)
# all these options are taken from hyprland, see https://wiki.hyprland.org/Configuring/Variables/#blur for explanations

View File

@ -166,7 +166,7 @@
WLR_NO_HARDWARE_CURSORS = "1";
NIXOS_OZONE_WL = "1";
EDITOR = "nvim";
FLAKE = "/home/foglar/mysystem";
FLAKE = "/home/foglar/dotfiles";
};
hardware = {

View File

@ -14,17 +14,19 @@
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/dbb68bbb-0468-4e0d-be75-547b5f146c34";
{ device = "/dev/disk/by-uuid/2037dfa2-abb1-4f51-90ed-cc3cc5aa94ed";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/C550-8CDA";
{ device = "/dev/disk/by-uuid/3897-60B5";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
swapDevices = [ ];
swapDevices =
[ { device = "/dev/disk/by-uuid/078c9606-e3cc-4770-a200-382b247723a6"; }
];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's

View File

@ -70,7 +70,7 @@
home.sessionVariables = {
EDITOR = "nvim";
FLAKE = "/home/foglar/mysystem";
FLAKE = "/home/foglar/dotfiles";
XDG_DATA_HOME = "$HOME/.local/share";
XDG_PICTURES_DIR = "$HOME/Pictures/Screenshots/";
#FZF_DEFAULT_OPTS = " \

View File

@ -1,16 +1,21 @@
{
pkgs,
{
pkgs,
lib,
config,
...
}:
{
}: {
options = {
terminal_tools.enable =
lib.mkEnableOption "enable terminal tools module";
lib.mkEnableOption "enable terminal tools module";
};
config = lib.mkIf config.terminal_tools.enable {
imports = [
./tools/oh-my-posh.nix
];
config = lib.mkIf config.terminal_tools.enable {
oh-my-posh.enable = lib.mkDefault true;
programs = {
bat.enable = true;
@ -28,30 +33,22 @@
spicetify.enable = true;
};
programs.oh-my-posh = {
enable = true;
enableBashIntegration = true;
#settings = '''';
#useTheme = "catppuccin_mocha";
useTheme = "kali";
};
programs.zoxide = {
enable = true;
enableBashIntegration = true;
};
programs.kitty = {
enable = true;
font.name = lib.mkDefault "JetBrainsMono Nerd Font";
#themeFile = "tokyo_night_night";
#themeFile = "Catppuccin-Mocha";
settings = {
font_size = 11.5;
confirm_os_window_close = 0;
hide_window_decorations = 0;
enable_audio_bell = false;
window_padding_width = 25;
enable = true;
font.name = lib.mkDefault "JetBrainsMono Nerd Font";
#themeFile = "tokyo_night_night";
#themeFile = "Catppuccin-Mocha";
settings = {
font_size = 11.5;
confirm_os_window_close = 0;
hide_window_decorations = 0;
enable_audio_bell = false;
window_padding_width = 25;
};
};
@ -65,7 +62,6 @@
figlet
jp2a
yt-dlp
oh-my-posh
eza
nvtopPackages.full
neofetch
@ -77,4 +73,4 @@
spicetify-cli
];
};
}
}

View File

@ -0,0 +1,132 @@
{
lib,
config,
pkgs,
...
}: {
options = {
oh-my-posh.enable = lib.mkEnableOption "enable oh-my-posh";
};
config = lib.mkIf config.oh-my-posh.enable {
programs.oh-my-posh = {
enable = true;
enableBashIntegration = true;
settings = {
"$schema" = "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json";
"blocks" = [
{
"alignment" = "left";
"segments" = [
{
"type" = "session";
"foreground" = "lightBlue";
"foreground_templates" = [
"{{ if .Root }}lightRed{{ end }}"
];
"properties" = {
"display_host" = true;
};
"style" = "plain";
"template" = "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>(</>{{ .UserName }}{{ if .Root }}💀{{ else }}󱄅 {{ end }}{{ .HostName }}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>)</>";
}
{
"type" = "nix-shell";
"style" = "powerline";
"foreground" = "blue";
"background" = "transparent";
"template" = "{{if eq .Type \"impure\" }}[󱄅 nix-shell]{{ end }}";
}
{
"type" = "python";
"foreground" = "yellow";
"properties" = {
"fetch_version" = true;
"fetch_virtual_env" = true;
"display_default" = false;
"display_mode" = "files";
};
"style" = "plain";
"template" = "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>-[</> {{ if .Error }}{{ .Error }}{{ else }}{{ if .Venv }}{{ .Venv }}{{ end }}{{ .Full }}{{ end }}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>]</>";
}
{
"type" = "go";
"style" = "powerline";
"powerline_symbol" = "";
"foreground" = "#7FD5EA";
"display_mode" = "files";
"fetch_version" = false;
"template" = "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>-[</> {{ if .Error }}{{ .Error }}{{ else }}OS:{{if eq .Env.GOOS \"linux\"}}󰌽{{else if eq .Env.GOOS \"windows\"}}{{else}}{{.Env.GOOS}}{{end}} ARCH:{{.Env.GOARCH}}{{ end }}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>]</>";
}
{
"type" = "path";
"foreground" = "lightWhite";
"properties" = {
"folder_separator_icon" = "<#c0c0c0>/</>";
"style" = "full";
};
"style" = "plain";
"template" = "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>-[</>{{if eq .Folder \"foglar\"}}~{{else}}{{ .Folder }}{{end}}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>]</>";
}
{
"type" = "git";
"foreground" = "white";
"style" = "plain";
"template" = "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>-[</>{{ .HEAD }}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>]</>";
}
];
"type" = "prompt";
}
{
"alignment" = "right";
"segment" = [
{
"type" = "executiontime";
"foreground" = "white";
"properties" = {
"always_enabled" = true;
"style" = "round";
};
"style" = "plain";
"template" = " {{ .FormattedMs }} ";
}
{
"type" = "status";
"foreground" = "green";
"foreground_templates" = [
"{{ if gt .Code 0 }}red{{ end }}"
];
"properties" = {
"always_enabled" = true;
};
"style" = "plain";
"template" = " {{ if gt .Code 0 }}{{.Code}}{{else}}\ueab2{{ end }} ";
}
];
"type" = "prompt";
}
{
"alignment" = "left";
"newline" = true;
"segments" = [
{
"type" = "text";
"foreground" = "lightBlue";
"style" = "plain";
"template" = "<{{ if .Root }}lightBlue{{ else }}green{{ end }}></>{{ if .Root }}<lightRed>#</>{{ else }}\${{ end }} ";
}
];
"type" = "prompt";
}
];
"version" = 2;
};
#useTheme = "catppuccin_mocha";
useTheme = "kali";
};
home.packages = with pkgs; [
oh-my-posh
];
};
}