forked from fabian/nix_config
Compare commits
8 commits
84cacc56d2
...
e4d2f83c9b
Author | SHA1 | Date | |
---|---|---|---|
e4d2f83c9b | |||
d7bc9b85a0 | |||
8024a1ed64 | |||
3e9486099d | |||
b89521fb7b | |||
e5df34d7e2 | |||
7b5c19a19a | |||
d41d67a858 |
8 changed files with 217 additions and 146 deletions
|
@ -5,7 +5,7 @@
|
|||
...
|
||||
}: {
|
||||
imports = [
|
||||
./terminal
|
||||
./terminal.nix
|
||||
./neovim.nix
|
||||
./baseline.nix
|
||||
./gaming.nix
|
||||
|
@ -14,5 +14,6 @@
|
|||
./zsh
|
||||
./defaultDesktopPack.nix
|
||||
./mapping.nix
|
||||
./zed.nix
|
||||
];
|
||||
}
|
||||
|
|
|
@ -62,7 +62,7 @@ in {
|
|||
enable = true;
|
||||
defaultApplications = {
|
||||
"application/pdf" = with pkgs; ["qpdfview"];
|
||||
"x-scheme-handler/file" = with pkgs; ["kitty"];
|
||||
"x-scheme-handler/file" = with pkgs; ["foot"];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -97,7 +97,7 @@ in {
|
|||
colors = {
|
||||
background = "#141414";
|
||||
focused = {
|
||||
border = "#1c1c1c";
|
||||
border = "#444444";
|
||||
background = "#000000";
|
||||
text = "#eaeaea";
|
||||
indicator = "#000000";
|
||||
|
@ -143,7 +143,7 @@ in {
|
|||
"${mod}+c" = "focus child";
|
||||
"${mod}+d" = "exec ${bemenuCommand}";
|
||||
"${mod}+l" = "exec ${getExe pkgs.gtklock} -d";
|
||||
"${mod}+Return" = "exec ${lib.getExe pkgs.kitty} ${lib.getExe pkgs.tmux}";
|
||||
"${mod}+Return" = "exec ${lib.getExe pkgs.foot} ${lib.getExe pkgs.tmux}";
|
||||
"${mod}+Shift+s" = "exec ${grimshot} copy area";
|
||||
"${mod}+Shift+a" = "exec ${grimshot} copy output";
|
||||
"${mod}+Tab" = "focus right";
|
||||
|
|
117
home/modules/terminal.nix
Normal file
117
home/modules/terminal.nix
Normal file
|
@ -0,0 +1,117 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.local.apps.terminal;
|
||||
in {
|
||||
options.local.apps.terminal.enable = mkEnableOption "terminal emulator settings";
|
||||
config = mkIf cfg.enable {
|
||||
programs = {
|
||||
foot = {
|
||||
enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
term = "xterm-256color";
|
||||
font = "JetBrains Mono:style=Medium:size=15";
|
||||
font-bold = "JetBrains Mono:style=Bold:size=15";
|
||||
font-italic = "JetBrains Mono:style=Italic:size=15";
|
||||
font-bold-italic = "JetBrains Mono:style=Bold Italic:size=15";
|
||||
dpi-aware = "yes";
|
||||
initial-window-size-pixels = "1200x600";
|
||||
};
|
||||
|
||||
cursor = {
|
||||
style = "block";
|
||||
blink = "yes";
|
||||
};
|
||||
|
||||
colors = {
|
||||
background = "000000";
|
||||
regular0 = "616161";
|
||||
regular1 = "ff4d51";
|
||||
regular2 = "35d450";
|
||||
regular3 = "e9e836";
|
||||
regular4 = "5dc5f8";
|
||||
regular5 = "feabf2";
|
||||
regular6 = "24dfc4";
|
||||
regular7 = "ffffff";
|
||||
};
|
||||
|
||||
bell = {
|
||||
system = "no";
|
||||
urgent = "no";
|
||||
notify = "no";
|
||||
visual = "no";
|
||||
command-focused = "no";
|
||||
};
|
||||
|
||||
mouse = {
|
||||
hide-when-typing = "no";
|
||||
};
|
||||
|
||||
key-bindings = {
|
||||
clipboard-copy = "Control+Shift+c";
|
||||
clipboard-paste = "Control+Shift+v";
|
||||
font-increase = "Control+Shift+equal";
|
||||
font-decrease = "Control+Shift+minus";
|
||||
font-reset = "Control+Shift+BackSpace";
|
||||
};
|
||||
|
||||
mouse-bindings = {
|
||||
scrollback-up-mouse = "BTN_WHEEL_BACK";
|
||||
scrollback-down-mouse = "BTN_WHEEL_FORWARD";
|
||||
font-increase = "Control+BTN_WHEEL_BACK";
|
||||
font-decrease = "Control+BTN_WHEEL_FORWARD";
|
||||
select-begin = "BTN_LEFT";
|
||||
select-begin-block = "Control+BTN_LEFT";
|
||||
select-extend = "BTN_RIGHT";
|
||||
select-extend-character-wise = "Control+BTN_RIGHT";
|
||||
select-word = "BTN_LEFT-2";
|
||||
select-word-whitespace = "Control+BTN_LEFT-2";
|
||||
select-quote = " BTN_LEFT-3";
|
||||
select-row = "BTN_LEFT-4";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
tmux = {
|
||||
enable = true;
|
||||
aggressiveResize = true;
|
||||
clock24 = true;
|
||||
escapeTime = 10;
|
||||
terminal = "xterm-256color";
|
||||
keyMode = "emacs";
|
||||
mouse = true;
|
||||
|
||||
extraConfig = ''
|
||||
set -ga update-environment " LIFT_PID"
|
||||
set -g set-titles on
|
||||
set -g renumber-windows on
|
||||
set -sa terminal-overrides ',xterm-termite:RGB'
|
||||
|
||||
set -g status-style bg=default,fg=colour250
|
||||
set -g pane-border-style fg=colour236
|
||||
set -g pane-active-border-style fg=colour240
|
||||
set -g window-status-format " #I:#W "
|
||||
set -g window-status-style bg=default,fg=colour244
|
||||
set -g window-status-current-format " #I:#W "
|
||||
set -g window-status-current-style bg=colour236,fg=white,bold
|
||||
set -g status-position bottom
|
||||
set -g status-left-length 20
|
||||
set -g status-right-length 60
|
||||
set -g status-left ""
|
||||
set -g window-status-separator ""
|
||||
set -g status-justify left
|
||||
'';
|
||||
};
|
||||
};
|
||||
home = {
|
||||
sessionVariables = {
|
||||
"TERMINAL" = "foot";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,55 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.local.apps.terminal;
|
||||
in {
|
||||
options.local.apps.terminal.enable = mkEnableOption "terminal emulator settings";
|
||||
config = mkIf cfg.enable {
|
||||
programs = {
|
||||
kitty = {
|
||||
enable = true;
|
||||
extraConfig = import ./kitty.conf.nix;
|
||||
};
|
||||
|
||||
tmux = {
|
||||
enable = true;
|
||||
aggressiveResize = true;
|
||||
clock24 = true;
|
||||
escapeTime = 10;
|
||||
terminal = "xterm-256color";
|
||||
keyMode = "emacs";
|
||||
mouse = true;
|
||||
|
||||
extraConfig = ''
|
||||
set -ga update-environment " LIFT_PID"
|
||||
set -g set-titles on
|
||||
set -g renumber-windows on
|
||||
set -sa terminal-overrides ',xterm-termite:RGB'
|
||||
|
||||
set -g status-style bg=default,fg=colour250
|
||||
set -g pane-border-style fg=colour236
|
||||
set -g pane-active-border-style fg=colour240
|
||||
set -g window-status-format " #I:#W "
|
||||
set -g window-status-style bg=default,fg=colour244
|
||||
set -g window-status-current-format " #I:#W "
|
||||
set -g window-status-current-style bg=colour236,fg=white,bold
|
||||
set -g status-position bottom
|
||||
set -g status-left-length 20
|
||||
set -g status-right-length 60
|
||||
set -g status-left ""
|
||||
set -g window-status-separator ""
|
||||
set -g status-justify left
|
||||
'';
|
||||
};
|
||||
};
|
||||
home = {
|
||||
sessionVariables = {
|
||||
"TERMINAL" = "kitty";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,87 +0,0 @@
|
|||
''
|
||||
# Fonts
|
||||
font_family JetBrains Mono Medium
|
||||
bold_font JetBrains Mono Bold
|
||||
italic_font JetBrains Mono Italic
|
||||
bold_italic_font JetBrains Mono Bold Italic
|
||||
|
||||
font_size 10
|
||||
disable_ligatures cursor
|
||||
|
||||
initial_window_width 1200
|
||||
initial_window_height 600
|
||||
|
||||
# Cursor
|
||||
cursor_shape beam
|
||||
cursor_beam_thickness 1.9
|
||||
cursor_stop_blinking_after 0
|
||||
|
||||
# Audio
|
||||
enable_audio_bell no
|
||||
|
||||
# Tabs
|
||||
tab_bar_style separator
|
||||
tab_separator " | "
|
||||
tab_title_template "{index}: {title}"
|
||||
|
||||
# Color
|
||||
# special
|
||||
foreground #ffffff
|
||||
foreground_bold #ffffff
|
||||
cursor #ffffff
|
||||
background #000000
|
||||
background_opacity 1
|
||||
|
||||
# Shortcuts
|
||||
map ctrl+shift+c copy_to_clipboard
|
||||
map ctrl+shift+v paste_from_clipboard
|
||||
map ctrl+shift+s paste_from_selection
|
||||
map shift+insert paste_from_selection
|
||||
|
||||
map ctrl+shift+up scroll_line_up
|
||||
map ctrl+shift+down scroll_line_down
|
||||
map ctrl+shift+page_up scroll_page_up
|
||||
map ctrl+shift+page_down scroll_page_down
|
||||
map ctrl+shift+home scroll_home
|
||||
map ctrl+shift+end scroll_end
|
||||
|
||||
map ctrl+shift+enter new_window
|
||||
map ctrl+alt+enter launch --cwd=current
|
||||
map ctrl+shift+w close_window
|
||||
map ctrl+shift+] next_window
|
||||
map ctrl+shift+[ previous_window
|
||||
map ctrl+shift+1 first_window
|
||||
map ctrl+shift+2 second_window
|
||||
map ctrl+shift+3 third_window
|
||||
map ctrl+shift+4 fourth_window
|
||||
map ctrl+shift+5 fifth_window
|
||||
map ctrl+shift+6 sixth_window
|
||||
map ctrl+shift+7 seventh_window
|
||||
map ctrl+shift+8 eighth_window
|
||||
map ctrl+shift+9 ninth_window
|
||||
map ctrl+shift+0 tenth_window
|
||||
|
||||
map ctrl+shift+right next_tab
|
||||
map ctrl+shift+left previous_tab
|
||||
map ctrl+shift+t new_tab
|
||||
map ctrl+shift+q close_tab
|
||||
map ctrl+shift+. move_tab_forward
|
||||
map ctrl+shift+, move_tab_backward
|
||||
map ctrl+shift+alt+t set_tab_title
|
||||
map ctrl+alt+1 goto_tab 1
|
||||
map ctrl+alt+2 goto_tab 2
|
||||
map ctrl+alt+3 goto_tab 3
|
||||
map ctrl+alt+4 goto_tab 4
|
||||
map ctrl+alt+5 goto_tab 5
|
||||
map ctrl+alt+6 goto_tab 6
|
||||
map ctrl+alt+7 goto_tab 7
|
||||
map ctrl+alt+8 goto_tab 8
|
||||
map ctrl+alt+9 goto_tab 9
|
||||
map ctrl+alt+0 goto_tab 10
|
||||
|
||||
map ctrl+shift+equal change_font_size all +1.0
|
||||
map ctrl+shift+minus change_font_size all -1.0
|
||||
map ctrl+shift+backspace change_font_size all 0
|
||||
|
||||
map ctrl+shift+delete clear_terminal reset active
|
||||
''
|
93
home/modules/zed.nix
Normal file
93
home/modules/zed.nix
Normal file
|
@ -0,0 +1,93 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.local.apps.zed;
|
||||
in {
|
||||
options.local.apps.zed.enable = mkEnableOption "zed editor settings";
|
||||
config = mkIf cfg.enable {
|
||||
programs.zed-editor = {
|
||||
enable = true;
|
||||
extensions = [
|
||||
"nix"
|
||||
"codebook"
|
||||
"vscode-dark-high-contrast"
|
||||
"catppuccin-icons"
|
||||
];
|
||||
extraPackages = with pkgs; [
|
||||
nixd
|
||||
];
|
||||
userSettings = {
|
||||
disable_ai = true;
|
||||
theme = {
|
||||
dark = "VSCode Dark High Contrast";
|
||||
light = "VSCode Dark High Contrast";
|
||||
};
|
||||
icon_theme = {
|
||||
dark = "Catppuccin Latte";
|
||||
light = "Catppuccin Latte";
|
||||
};
|
||||
file_icons = true;
|
||||
rulers = [80 120];
|
||||
preferred_line_length = 120;
|
||||
scroll_past_end = true;
|
||||
cursor = {
|
||||
blink_interval = 600;
|
||||
smooth_scroll = true;
|
||||
};
|
||||
autosave = "on_focus_change";
|
||||
auto_update = false;
|
||||
buffer_font_family = "JetBrains Mono";
|
||||
buffer_font_size = 22;
|
||||
hide_mouse = "never";
|
||||
minimap.show = "auto";
|
||||
tabs = {
|
||||
file_icons = true;
|
||||
git_status = true;
|
||||
activate_on_close = "neighbour";
|
||||
show_close_button = "always";
|
||||
};
|
||||
toolbar = {
|
||||
breadcrumbs = true;
|
||||
quick_actions = true;
|
||||
selections_menu = true;
|
||||
agent_review = false;
|
||||
code_actions = false;
|
||||
};
|
||||
format_on_save = "off";
|
||||
use_autoclose = false;
|
||||
git = {
|
||||
git_gutter = "tracked_files";
|
||||
inline_blame = {
|
||||
enabled = true;
|
||||
delay_ms = 5000;
|
||||
};
|
||||
};
|
||||
indent_guides = {
|
||||
enabled = true;
|
||||
line_width = 1;
|
||||
active_line_width = 1;
|
||||
coloring = "fixed";
|
||||
background_coloring = "disabled";
|
||||
};
|
||||
hour_format = "hour24";
|
||||
remove_trailing_whitespace_on_save = false;
|
||||
use_smartcase_search = true;
|
||||
soft_wrap = "editor_width";
|
||||
tab_size = 2;
|
||||
telemetry = {
|
||||
diagnostics = false;
|
||||
metrics = false;
|
||||
};
|
||||
auto_fold_dirs = false;
|
||||
scrollbar = {
|
||||
show = "always";
|
||||
};
|
||||
unnecessary_code_fade = 0.0;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -31,12 +31,14 @@
|
|||
};
|
||||
|
||||
apps = {
|
||||
#todo move some of this to defaultDesktop pack?
|
||||
terminal.enable = true;
|
||||
neovim.enable = true;
|
||||
gaming.enable = true;
|
||||
defaultDesktopPack.enable = true;
|
||||
firefox.enable = true;
|
||||
mapping.enable = true;
|
||||
zed.enable = true;
|
||||
};
|
||||
|
||||
gui = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue