Better modules
This commit is contained in:
parent
85a23285b8
commit
21ed795cfd
16 changed files with 534 additions and 302 deletions
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
config.nix
|
||||||
|
|
@ -1 +0,0 @@
|
||||||
{ allowUnfree = true; }
|
|
||||||
89
configs/rofi/nord.rasi
Normal file
89
configs/rofi/nord.rasi
Normal file
|
|
@ -0,0 +1,89 @@
|
||||||
|
* {
|
||||||
|
nord0: #2e3440;
|
||||||
|
nord1: #3b4252;
|
||||||
|
nord2: #434c5e;
|
||||||
|
nord3: #4c566a;
|
||||||
|
nord4: #d8dee9;
|
||||||
|
nord5: #e5e9f0;
|
||||||
|
nord6: #eceff4;
|
||||||
|
nord7: #8fbcbb;
|
||||||
|
nord8: #88c0d0;
|
||||||
|
nord9: #81a1c1;
|
||||||
|
nord10: #5e81ac;
|
||||||
|
nord11: #bf616a;
|
||||||
|
nord12: #d08770;
|
||||||
|
nord13: #ebcb8b;
|
||||||
|
nord14: #a3be8c;
|
||||||
|
nord15: #b48ead;
|
||||||
|
|
||||||
|
background-color: @nord1;
|
||||||
|
border: 0px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 0px;
|
||||||
|
spacing: 0px;
|
||||||
|
text-color: @nord4;
|
||||||
|
}
|
||||||
|
#inputbar {
|
||||||
|
text-color: @nord3;
|
||||||
|
padding: 6px;
|
||||||
|
margin: 0px 0px 2px;
|
||||||
|
children: [ entry ];
|
||||||
|
}
|
||||||
|
#entry {
|
||||||
|
background-color: @nord3;
|
||||||
|
text-color: @nord4;
|
||||||
|
padding: 5px;
|
||||||
|
}
|
||||||
|
#message {
|
||||||
|
border: 0px 0px 1px;
|
||||||
|
border-color: @nord3;
|
||||||
|
padding: 0px 0px 6px 7px;
|
||||||
|
}
|
||||||
|
#listview {
|
||||||
|
lines: 10;
|
||||||
|
padding: 2px 0px 0px;
|
||||||
|
scrollbar: true;
|
||||||
|
}
|
||||||
|
#element {
|
||||||
|
padding: 0px 0px 0px 7px;
|
||||||
|
margin: 0px 0px 5px 0px;
|
||||||
|
text-color: @nord4;
|
||||||
|
}
|
||||||
|
#element.normal.normal {
|
||||||
|
text-color: @nord4;
|
||||||
|
}
|
||||||
|
#element.normal.urgent {
|
||||||
|
text-color: @nord11;
|
||||||
|
}
|
||||||
|
#element.normal.active {
|
||||||
|
text-color: @nord10;
|
||||||
|
}
|
||||||
|
#element.alternate.normal {
|
||||||
|
text-color: @nord4;
|
||||||
|
}
|
||||||
|
#element.alternate.urgent {
|
||||||
|
text-color: @nord11;
|
||||||
|
}
|
||||||
|
#element.alternate.active {
|
||||||
|
text-color: @nord10;
|
||||||
|
}
|
||||||
|
#element.selected.normal {
|
||||||
|
background-color: @nord8;
|
||||||
|
text-color: @nord1;
|
||||||
|
}
|
||||||
|
#element.selected.urgent {
|
||||||
|
background-color: @nord11;
|
||||||
|
text-color: @nord4;
|
||||||
|
}
|
||||||
|
#element.selected.active {
|
||||||
|
background-color: @nord10;
|
||||||
|
text-color: @nord4;
|
||||||
|
}
|
||||||
|
#scrollbar {
|
||||||
|
handle-color: @nord3;
|
||||||
|
handle-width: 0.50em;
|
||||||
|
}
|
||||||
|
#button.selected {
|
||||||
|
background-color: @nord8;
|
||||||
|
text-color: @nord4;
|
||||||
|
}
|
||||||
40
configs/terminator/config
Normal file
40
configs/terminator/config
Normal file
|
|
@ -0,0 +1,40 @@
|
||||||
|
[global_config]
|
||||||
|
scroll_tabbar = True
|
||||||
|
enabled_plugins = ActivityWatch, LaunchpadCodeURLHandler, APTURLHandler, LaunchpadBugURLHandler
|
||||||
|
suppress_multiple_term_dialog = True
|
||||||
|
always_split_with_profile = True
|
||||||
|
[keybindings]
|
||||||
|
help = None
|
||||||
|
[profiles]
|
||||||
|
[[default]]
|
||||||
|
visible_bell = True
|
||||||
|
background_color = "#2e3440"
|
||||||
|
background_darkness = 0.95
|
||||||
|
background_type = transparent
|
||||||
|
cursor_color = "#d8dee9"
|
||||||
|
font = FuraCode Nerd Font Mono weight=450 10
|
||||||
|
foreground_color = "#d8dee9"
|
||||||
|
show_titlebar = False
|
||||||
|
scrollbar_position = hidden
|
||||||
|
scrollback_lines = 10000
|
||||||
|
palette = "#3b4252:#bf616a:#a3be8c:#ebcb8b:#81a1c1:#b48ead:#88c0d0:#e5e9f0:#4c566a:#bf616a:#a3be8c:#ebcb8b:#81a1c1:#b48ead:#8fbcbb:#eceff4"
|
||||||
|
use_system_font = False
|
||||||
|
[[presentation]]
|
||||||
|
visible_bell = True
|
||||||
|
background_color = "#fdf6e3"
|
||||||
|
cursor_color = "#aaaaaa"
|
||||||
|
font = FuraCode Nerd Font Mono weight=450 20
|
||||||
|
foreground_color = "#2e3436"
|
||||||
|
show_titlebar = False
|
||||||
|
palette = "#073642:#dc322f:#859900:#b58900:#268bd2:#d33682:#2aa198:#eee8d5:#002b36:#cb4b16:#586e75:#657b83:#839496:#6c71c4:#93a1a1:#fdf6e3"
|
||||||
|
use_system_font = False
|
||||||
|
[layouts]
|
||||||
|
[[default]]
|
||||||
|
[[[child1]]]
|
||||||
|
parent = window0
|
||||||
|
type = Terminal
|
||||||
|
profile = default
|
||||||
|
[[[window0]]]
|
||||||
|
parent = ""
|
||||||
|
type = Window
|
||||||
|
[plugins]
|
||||||
59
home.nix
59
home.nix
|
|
@ -8,6 +8,9 @@ in {
|
||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
nixpkgs.config = import ./modules/config.nix;
|
||||||
|
xdg.configFile."nixpkgs/config.nix".source = ./modules/config.nix;
|
||||||
|
|
||||||
home = {
|
home = {
|
||||||
language.base = "it_IT.UTF-8";
|
language.base = "it_IT.UTF-8";
|
||||||
keyboard.layout = "it";
|
keyboard.layout = "it";
|
||||||
|
|
@ -18,46 +21,34 @@ in {
|
||||||
gnome3.nautilus
|
gnome3.nautilus
|
||||||
procps-ng
|
procps-ng
|
||||||
mmv-go
|
mmv-go
|
||||||
|
terminator
|
||||||
|
bottom
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
imports = [
|
||||||
|
./modules/alacritty.nix
|
||||||
|
./modules/bat.nix
|
||||||
|
./modules/broot.nix
|
||||||
|
./modules/dircolors.nix
|
||||||
|
./modules/git.nix
|
||||||
|
./modules/kakoune.nix
|
||||||
|
./modules/qogir_theme.nix
|
||||||
|
./modules/rofi.nix
|
||||||
|
./modules/sxhkd.nix
|
||||||
|
./modules/terminator.nix
|
||||||
|
];
|
||||||
|
|
||||||
programs = {
|
programs = {
|
||||||
# alacritty = import ./modules/alacritty.nix pkgs;
|
# command-not-found.enable = true;
|
||||||
|
|
||||||
bat = { enable = true; config.theme = "Nord"; };
|
|
||||||
|
|
||||||
command-not-found.enable = true;
|
|
||||||
|
|
||||||
broot = { enable = true; enableBashIntegration = true; enableZshIntegration = true; };
|
|
||||||
|
|
||||||
dircolors = { enable = true; enableBashIntegration = true; enableZshIntegration = true; };
|
|
||||||
|
|
||||||
direnv = { enable = true; enableBashIntegration = true; enableZshIntegration = true; enableNixDirenvIntegration = true; };
|
|
||||||
|
|
||||||
git = import ./modules/git.nix pkgs;
|
|
||||||
|
|
||||||
home-manager.enable = true;
|
home-manager.enable = true;
|
||||||
|
# info.enable = true;
|
||||||
info.enable = true;
|
# kakoune = import ./modules/kakoune.nix pkgs;
|
||||||
|
# zsh = {
|
||||||
kakoune = import ./modules/kakoune.nix pkgs;
|
# enableVteIntegration = true;
|
||||||
|
# };
|
||||||
rofi = import ./modules/rofi.nix pkgs;
|
|
||||||
|
|
||||||
zsh = {
|
|
||||||
enableVteIntegration = true;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
qt = {
|
xsession.numlock.enable = true;
|
||||||
enable = true;
|
|
||||||
platformTheme = "gtk";
|
|
||||||
};
|
|
||||||
|
|
||||||
services = {
|
|
||||||
# sxhkd = import ./modules/sxhkd.nix pkgs;
|
|
||||||
};
|
|
||||||
|
|
||||||
xsession.numlock.enable = true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,77 +1,77 @@
|
||||||
{ config, pkgs, lib, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
enable = true;
|
programs.alacritty = {
|
||||||
settings = {
|
enable = true;
|
||||||
scrolling.history = 3000;
|
settings = {
|
||||||
font = {
|
scrolling.history = 3000;
|
||||||
normal.family = "FuraCode Nerd Font";
|
font = {
|
||||||
size = 9.0;
|
normal.family = "FuraCode Nerd Font";
|
||||||
};
|
size = 9.0;
|
||||||
background_opacity = 0.95;
|
};
|
||||||
mouse = {
|
background_opacity = 0.95;
|
||||||
hide_when_typing = true;
|
mouse = {
|
||||||
url.modifiers = "Control";
|
hide_when_typing = true;
|
||||||
};
|
url.modifiers = "Control";
|
||||||
|
};
|
||||||
|
|
||||||
# NORD Theme: https://github.com/arcticicestudio/nord-alacritty
|
# NORD Theme: https://github.com/arcticicestudio/nord-alacritty
|
||||||
colors = {
|
colors = {
|
||||||
primary = {
|
primary = {
|
||||||
background = "#2e3440";
|
background = "#2e3440";
|
||||||
foreground = "#d8dee9";
|
|
||||||
dim_foreground = "#a5abb6";
|
|
||||||
};
|
|
||||||
cursor = {
|
|
||||||
text = "#2e3440";
|
|
||||||
cursor = "#d8dee9";
|
|
||||||
};
|
|
||||||
vi_mode_cursor = {
|
|
||||||
text = "#2e3440";
|
|
||||||
cursor = "#d8dee9";
|
|
||||||
};
|
|
||||||
selection = {
|
|
||||||
text = "CellForeground";
|
|
||||||
background = "#4c566a";
|
|
||||||
};
|
|
||||||
search = {
|
|
||||||
matches = {
|
|
||||||
foreground = "CellForeground";
|
|
||||||
background = "#88c0d0";
|
|
||||||
};
|
|
||||||
bar = {
|
|
||||||
background = "#434c5e";
|
|
||||||
foreground = "#d8dee9";
|
foreground = "#d8dee9";
|
||||||
|
dim_foreground = "#a5abb6";
|
||||||
|
};
|
||||||
|
cursor = {
|
||||||
|
text = "#2e3440";
|
||||||
|
cursor = "#d8dee9";
|
||||||
|
};
|
||||||
|
vi_mode_cursor = {
|
||||||
|
text = "#2e3440";
|
||||||
|
cursor = "#d8dee9";
|
||||||
|
};
|
||||||
|
selection = {
|
||||||
|
text = "CellForeground";
|
||||||
|
background = "#4c566a";
|
||||||
|
};
|
||||||
|
search = {
|
||||||
|
matches = {
|
||||||
|
foreground = "CellForeground";
|
||||||
|
background = "#88c0d0";
|
||||||
|
};
|
||||||
|
bar = {
|
||||||
|
background = "#434c5e";
|
||||||
|
foreground = "#d8dee9";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
normal = {
|
||||||
|
black = "#3b4252";
|
||||||
|
red = "#bf616a";
|
||||||
|
green = "#a3be8c";
|
||||||
|
yellow = "#ebcb8b";
|
||||||
|
blue = "#81a1c1";
|
||||||
|
magenta = "#b48ead";
|
||||||
|
cyan = "#88c0d0";
|
||||||
|
white = "#e5e9f0";
|
||||||
|
};
|
||||||
|
bright = {
|
||||||
|
black = "#4c566a";
|
||||||
|
red = "#bf616a";
|
||||||
|
green = "#a3be8c";
|
||||||
|
yellow = "#ebcb8b";
|
||||||
|
blue = "#81a1c1";
|
||||||
|
magenta = "#b48ead";
|
||||||
|
cyan = "#8fbcbb";
|
||||||
|
white = "#eceff4";
|
||||||
|
};
|
||||||
|
dim = {
|
||||||
|
black = "#373e4d";
|
||||||
|
red = "#94545d";
|
||||||
|
green = "#809575";
|
||||||
|
yellow = "#b29e75";
|
||||||
|
blue = "#68809a";
|
||||||
|
magenta = "#8c738c";
|
||||||
|
cyan = "#6d96a5";
|
||||||
|
white = "#aeb3bb";
|
||||||
};
|
};
|
||||||
};
|
|
||||||
normal = {
|
|
||||||
black = "#3b4252";
|
|
||||||
red = "#bf616a";
|
|
||||||
green = "#a3be8c";
|
|
||||||
yellow = "#ebcb8b";
|
|
||||||
blue = "#81a1c1";
|
|
||||||
magenta = "#b48ead";
|
|
||||||
cyan = "#88c0d0";
|
|
||||||
white = "#e5e9f0";
|
|
||||||
};
|
|
||||||
bright = {
|
|
||||||
black = "#4c566a";
|
|
||||||
red = "#bf616a";
|
|
||||||
green = "#a3be8c";
|
|
||||||
yellow = "#ebcb8b";
|
|
||||||
blue = "#81a1c1";
|
|
||||||
magenta = "#b48ead";
|
|
||||||
cyan = "#8fbcbb";
|
|
||||||
white = "#eceff4";
|
|
||||||
};
|
|
||||||
dim = {
|
|
||||||
black = "#373e4d";
|
|
||||||
red = "#94545d";
|
|
||||||
green = "#809575";
|
|
||||||
yellow = "#b29e75";
|
|
||||||
blue = "#68809a";
|
|
||||||
magenta = "#8c738c";
|
|
||||||
cyan = "#6d96a5";
|
|
||||||
white = "#aeb3bb";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
3
modules/bat.nix
Normal file
3
modules/bat.nix
Normal file
|
|
@ -0,0 +1,3 @@
|
||||||
|
{
|
||||||
|
programs.bat = { enable = true; config.theme = "Nord"; };
|
||||||
|
}
|
||||||
7
modules/broot.nix
Normal file
7
modules/broot.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
programs.broot = {
|
||||||
|
enable = true;
|
||||||
|
enableBashIntegration = true;
|
||||||
|
enableZshIntegration = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
7
modules/dircolors.nix
Normal file
7
modules/dircolors.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
programs.dircolors = {
|
||||||
|
enable = true;
|
||||||
|
enableBashIntegration = true;
|
||||||
|
enableZshIntegration = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
7
modules/direnv.nix
Normal file
7
modules/direnv.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
programs.direnv = {
|
||||||
|
enable = true;
|
||||||
|
enableBashIntegration = true;
|
||||||
|
enableZshIntegration = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -3,22 +3,24 @@ let
|
||||||
kakouneCommand = "${pkgs.kakoune}/bin/kak";
|
kakouneCommand = "${pkgs.kakoune}/bin/kak";
|
||||||
meldCommand = "${pkgs.meld}/bin/meld";
|
meldCommand = "${pkgs.meld}/bin/meld";
|
||||||
in {
|
in {
|
||||||
enable = true;
|
programs.git = {
|
||||||
userName = "Filippo Berto";
|
enable = true;
|
||||||
userEmail = "berto.f@protonmail.com";
|
userName = "Filippo Berto";
|
||||||
signing = {
|
userEmail = "berto.f@protonmail.com";
|
||||||
key = "berto.f@protonmail.com";
|
signing = {
|
||||||
signByDefault = true;
|
key = "berto.f@protonmail.com";
|
||||||
|
signByDefault = true;
|
||||||
|
};
|
||||||
|
extraConfig = {
|
||||||
|
core.editor = kakouneCommand;
|
||||||
|
credential.helper = "cache --timeout=3600";
|
||||||
|
diff.guitool = meldCommand;
|
||||||
|
merge.guitool = meldCommand;
|
||||||
|
pull.rebase = true;
|
||||||
|
rebase.autostash = true;
|
||||||
|
init.defaultBranch = "master";
|
||||||
|
};
|
||||||
|
lfs.enable = true;
|
||||||
|
delta.enable = true;
|
||||||
};
|
};
|
||||||
extraConfig = {
|
|
||||||
core.editor = kakouneCommand;
|
|
||||||
credential.helper = "cache --timeout=3600";
|
|
||||||
diff.guitool = meldCommand;
|
|
||||||
merge.guitool = meldCommand;
|
|
||||||
pull.rebase = true;
|
|
||||||
rebase.autostash = true;
|
|
||||||
init.defaultBranch = "master";
|
|
||||||
};
|
|
||||||
lfs.enable = true;
|
|
||||||
delta.enable = true;
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,147 +2,149 @@
|
||||||
let
|
let
|
||||||
unstable = import <nixos-unstable> {};
|
unstable = import <nixos-unstable> {};
|
||||||
in {
|
in {
|
||||||
enable = true;
|
programs.kakoune = {
|
||||||
config = {
|
enable = true;
|
||||||
colorScheme = "nord";
|
config = {
|
||||||
tabStop = 2;
|
colorScheme = "nord";
|
||||||
indentWidth = 2;
|
tabStop = 2;
|
||||||
scrollOff = {
|
indentWidth = 2;
|
||||||
lines = 5;
|
scrollOff = {
|
||||||
columns = 3;
|
lines = 5;
|
||||||
|
columns = 3;
|
||||||
|
};
|
||||||
|
ui = {
|
||||||
|
setTitle = true;
|
||||||
|
changeColors = true;
|
||||||
|
enableMouse = true;
|
||||||
|
};
|
||||||
|
wrapLines = {
|
||||||
|
enable = true;
|
||||||
|
word = true;
|
||||||
|
};
|
||||||
|
numberLines = {
|
||||||
|
enable = true;
|
||||||
|
highlightCursor = true;
|
||||||
|
};
|
||||||
|
keyMappings = [{
|
||||||
|
mode = "normal";
|
||||||
|
docstring = "Open file";
|
||||||
|
key = "<c-o>";
|
||||||
|
effect = ":edit<space>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Comment block";
|
||||||
|
key = "b";
|
||||||
|
effect = ":comment-block<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Comment line";
|
||||||
|
key = "l";
|
||||||
|
effect = ":comment-line<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Show hover info";
|
||||||
|
key = "q";
|
||||||
|
effect = ":lsp-hover<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Jump to definition";
|
||||||
|
key = "d";
|
||||||
|
effect = ":lsp-definition<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "List project diagnostics";
|
||||||
|
key = "i";
|
||||||
|
effect = ":lsp-diagnostics<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Jump to type definition";
|
||||||
|
key = "t";
|
||||||
|
effect = ":lsp-type-definition<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Code actions";
|
||||||
|
key = "a";
|
||||||
|
effect = ":lsp-code-actions<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Format code";
|
||||||
|
key = "F";
|
||||||
|
effect = ":lsp-formatting-sync<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Spellcheck";
|
||||||
|
key = "s";
|
||||||
|
effect = ":spell ";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Spellcheck English";
|
||||||
|
key = "S";
|
||||||
|
effect = ":spell en<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Copy to clipboard";
|
||||||
|
key = "y";
|
||||||
|
effect = "<a-|>${pkgs.xclip}/bin/xclip -i -selection clipboard<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Paste from clipboard (before)";
|
||||||
|
key = "p";
|
||||||
|
effect = "!${pkgs.xclip}/bin/xclip -selection clipboard -o<ret>";
|
||||||
|
} {
|
||||||
|
mode = "user";
|
||||||
|
docstring = "Paste from clipboard (after)";
|
||||||
|
key = "P";
|
||||||
|
effect = "<a-!>${pkgs.xclip}/bin/xclip -selection clipboard -o<ret>";
|
||||||
|
}];
|
||||||
|
hooks = [{
|
||||||
|
name = "WinSetOption";
|
||||||
|
option = "filetype=(rust|python|c|cpp|latex|javascript|go)";
|
||||||
|
commands = builtins.concatStringsSep "\n" [
|
||||||
|
"lsp-enable-window"
|
||||||
|
];
|
||||||
|
} {
|
||||||
|
name = "BufCreate";
|
||||||
|
option = ".*";
|
||||||
|
commands = "editorconfig-load";
|
||||||
|
} {
|
||||||
|
name = "ModuleLoaded";
|
||||||
|
option = "powerline";
|
||||||
|
commands = builtins.concatStringsSep "\n" [
|
||||||
|
# "powerline-theme default"
|
||||||
|
"powerline-enable"
|
||||||
|
];
|
||||||
|
} {
|
||||||
|
name = "ModuleLoaded";
|
||||||
|
option = "auto-pairs";
|
||||||
|
commands = "auto-pairs-enable";
|
||||||
|
} {
|
||||||
|
name = "InsertCompletionShow";
|
||||||
|
option = ".*";
|
||||||
|
commands = builtins.concatStringsSep "\n" [
|
||||||
|
"map window insert <tab> <c-n>"
|
||||||
|
"map window insert <s-tab> <c-p>"
|
||||||
|
];
|
||||||
|
} {
|
||||||
|
name = "InsertCompletionHide";
|
||||||
|
option = ".*";
|
||||||
|
commands = builtins.concatStringsSep "\n" [
|
||||||
|
"unmap window insert <tab> <c-n>"
|
||||||
|
"unmap window insert <s-tab> <c-p>"
|
||||||
|
];
|
||||||
|
}];
|
||||||
};
|
};
|
||||||
ui = {
|
extraConfig = builtins.concatStringsSep "\n" [
|
||||||
setTitle = true;
|
"# Extra"
|
||||||
changeColors = true;
|
"define-command -docstring 'save and quit' x 'write-all; quit'"
|
||||||
enableMouse = true;
|
"add-highlighter global/ regex \\h+$ 0:Error"
|
||||||
};
|
"eval %sh{kak-lsp --kakoune -s \$kak_session}"
|
||||||
wrapLines = {
|
"require-module auto-pairs"
|
||||||
enable = true;
|
"require-module powerline"
|
||||||
word = true;
|
];
|
||||||
};
|
plugins = with pkgs; [
|
||||||
numberLines = {
|
kakounePlugins.kak-auto-pairs
|
||||||
enable = true;
|
unstable.kakounePlugins.powerline-kak
|
||||||
highlightCursor = true;
|
unstable.kakounePlugins.prelude-kak
|
||||||
};
|
];
|
||||||
keyMappings = [{
|
|
||||||
mode = "normal";
|
|
||||||
docstring = "Open file";
|
|
||||||
key = "<c-o>";
|
|
||||||
effect = ":edit<space>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Comment block";
|
|
||||||
key = "b";
|
|
||||||
effect = ":comment-block<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Comment line";
|
|
||||||
key = "l";
|
|
||||||
effect = ":comment-line<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Show hover info";
|
|
||||||
key = "q";
|
|
||||||
effect = ":lsp-hover<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Jump to definition";
|
|
||||||
key = "d";
|
|
||||||
effect = ":lsp-definition<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "List project diagnostics";
|
|
||||||
key = "i";
|
|
||||||
effect = ":lsp-diagnostics<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Jump to type definition";
|
|
||||||
key = "t";
|
|
||||||
effect = ":lsp-type-definition<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Code actions";
|
|
||||||
key = "a";
|
|
||||||
effect = ":lsp-code-actions<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Format code";
|
|
||||||
key = "F";
|
|
||||||
effect = ":lsp-formatting-sync<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Spellcheck";
|
|
||||||
key = "s";
|
|
||||||
effect = ":spell ";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Spellcheck English";
|
|
||||||
key = "S";
|
|
||||||
effect = ":spell en<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Copy to clipboard";
|
|
||||||
key = "y";
|
|
||||||
effect = "<a-|>${pkgs.xclip}/bin/xclip -i -selection clipboard<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Paste from clipboard (before)";
|
|
||||||
key = "p";
|
|
||||||
effect = "!${pkgs.xclip}/bin/xclip -selection clipboard -o<ret>";
|
|
||||||
} {
|
|
||||||
mode = "user";
|
|
||||||
docstring = "Paste from clipboard (after)";
|
|
||||||
key = "P";
|
|
||||||
effect = "<a-!>${pkgs.xclip}/bin/xclip -selection clipboard -o<ret>";
|
|
||||||
}];
|
|
||||||
hooks = [{
|
|
||||||
name = "WinSetOption";
|
|
||||||
option = "filetype=(rust|python|c|cpp|latex|javascript|go)";
|
|
||||||
commands = builtins.concatStringsSep "\n" [
|
|
||||||
"lsp-enable-window"
|
|
||||||
];
|
|
||||||
} {
|
|
||||||
name = "BufCreate";
|
|
||||||
option = ".*";
|
|
||||||
commands = "editorconfig-load";
|
|
||||||
} {
|
|
||||||
name = "ModuleLoaded";
|
|
||||||
option = "powerline";
|
|
||||||
commands = builtins.concatStringsSep "\n" [
|
|
||||||
# "powerline-theme default"
|
|
||||||
"powerline-enable"
|
|
||||||
];
|
|
||||||
} {
|
|
||||||
name = "ModuleLoaded";
|
|
||||||
option = "auto-pairs";
|
|
||||||
commands = "auto-pairs-enable";
|
|
||||||
} {
|
|
||||||
name = "InsertCompletionShow";
|
|
||||||
option = ".*";
|
|
||||||
commands = builtins.concatStringsSep "\n" [
|
|
||||||
"map window insert <tab> <c-n>"
|
|
||||||
"map window insert <s-tab> <c-p>"
|
|
||||||
];
|
|
||||||
} {
|
|
||||||
name = "InsertCompletionHide";
|
|
||||||
option = ".*";
|
|
||||||
commands = builtins.concatStringsSep "\n" [
|
|
||||||
"unmap window insert <tab> <c-n>"
|
|
||||||
"unmap window insert <s-tab> <c-p>"
|
|
||||||
];
|
|
||||||
}];
|
|
||||||
};
|
};
|
||||||
extraConfig = builtins.concatStringsSep "\n" [
|
|
||||||
"# Extra"
|
|
||||||
"define-command -docstring 'save and quit' x 'write-all; quit'"
|
|
||||||
"add-highlighter global/ regex \\h+$ 0:Error"
|
|
||||||
"eval %sh{kak-lsp --kakoune -s \$kak_session}"
|
|
||||||
"require-module auto-pairs"
|
|
||||||
"require-module powerline"
|
|
||||||
];
|
|
||||||
plugins = with pkgs; [
|
|
||||||
kakounePlugins.kak-auto-pairs
|
|
||||||
unstable.kakounePlugins.powerline-kak
|
|
||||||
unstable.kakounePlugins.prelude-kak
|
|
||||||
];
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
67
modules/qogir_theme.nix
Normal file
67
modules/qogir_theme.nix
Normal file
|
|
@ -0,0 +1,67 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
gtk = {
|
||||||
|
enable = true;
|
||||||
|
font = {
|
||||||
|
package = pkgs.cantarell-fonts;
|
||||||
|
name = "Cantarell";
|
||||||
|
size = 9;
|
||||||
|
};
|
||||||
|
iconTheme = {
|
||||||
|
package = pkgs.qogir-icon-theme;
|
||||||
|
name = "Qogir-dark";
|
||||||
|
};
|
||||||
|
theme = {
|
||||||
|
package = pkgs.qogir-theme;
|
||||||
|
name = "Qogir-dark";
|
||||||
|
};
|
||||||
|
# gtk3.extraConfig = {
|
||||||
|
# gtk-theme-name=Drakula
|
||||||
|
# gtk-icon-theme-name=Qogir-dark
|
||||||
|
# gtk-font-name=Cantarell 9
|
||||||
|
# gtk-cursor-theme-name=capitaine-cursors
|
||||||
|
# gtk-cursor-theme-size=0
|
||||||
|
# gtk-toolbar-style=GTK_TOOLBAR_ICONS
|
||||||
|
# gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
||||||
|
# gtk-button-images=1
|
||||||
|
# gtk-menu-images=1
|
||||||
|
# gtk-enable-event-sounds=1
|
||||||
|
# gtk-enable-input-feedback-sounds=1
|
||||||
|
# gtk-xft-antialias=1
|
||||||
|
# gtk-xft-hinting=1
|
||||||
|
# gtk-xft-hintstyle=hintfull
|
||||||
|
# gtk-xft-rgba=none
|
||||||
|
# };
|
||||||
|
# gtk2.extraConfig = {
|
||||||
|
# gtk-theme-name="Arc-Dark"
|
||||||
|
# gtk-icon-theme-name="Qogir-dark"
|
||||||
|
# gtk-font-name="Cantarell 9"
|
||||||
|
# gtk-cursor-theme-name="capitaine-cursors"
|
||||||
|
# gtk-cursor-theme-size=0
|
||||||
|
# gtk-toolbar-style=GTK_TOOLBAR_ICONS
|
||||||
|
# gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
||||||
|
# gtk-button-images=1
|
||||||
|
# gtk-menu-images=1
|
||||||
|
# gtk-enable-event-sounds=1
|
||||||
|
# gtk-enable-input-feedback-sounds=1
|
||||||
|
# gtk-xft-antialias=1
|
||||||
|
# gtk-xft-hinting=1
|
||||||
|
# gtk-xft-hintstyle="hintfull"
|
||||||
|
# gtk-xft-rgba="none"
|
||||||
|
# };
|
||||||
|
};
|
||||||
|
|
||||||
|
qt = {
|
||||||
|
enable = true;
|
||||||
|
platformTheme = "gtk";
|
||||||
|
};
|
||||||
|
|
||||||
|
xsession = {
|
||||||
|
numlock.enable = true;
|
||||||
|
pointerCursor = {
|
||||||
|
package = pkgs.qogir-icon-theme;
|
||||||
|
name = "Qogir";
|
||||||
|
size = 24;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -1,8 +1,11 @@
|
||||||
{ config, pkgs, lib, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
enable = true;
|
programs.rofi = {
|
||||||
extraConfig = {
|
enable = true;
|
||||||
modi = "drun,run,ssh,window";
|
extraConfig = {
|
||||||
};
|
modi = "drun,run,ssh,window";
|
||||||
|
theme = "nord";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
xdg.configFile."rofi/nord.rasi".source = ../configs/rofi/nord.rasi;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,41 +7,47 @@ let
|
||||||
pulseaudioCtl = "${pkgs.pulseaudio-ctl}/bin/pulseaudio-ctl";
|
pulseaudioCtl = "${pkgs.pulseaudio-ctl}/bin/pulseaudio-ctl";
|
||||||
playerctl = "${pkgs.playerctl}/bin/playerctl";
|
playerctl = "${pkgs.playerctl}/bin/playerctl";
|
||||||
alacritty = "${pkgs.alacritty}/bin/alacritty";
|
alacritty = "${pkgs.alacritty}/bin/alacritty";
|
||||||
|
terminator= "${pkgs.terminator}/bin/terminator";
|
||||||
rofi = "${pkgs.rofi}/bin/rofi";
|
rofi = "${pkgs.rofi}/bin/rofi";
|
||||||
bash = "${pkgs.bash}/bin/bash";
|
bash = "${pkgs.bash}/bin/bash";
|
||||||
in {
|
in
|
||||||
enable = true;
|
|
||||||
keybindings = {
|
{
|
||||||
"super + Return" = "${bash} ${alacritty}";
|
services.sxhkd = {
|
||||||
"super + @space" = "${rofi} -show drun";
|
enable = true;
|
||||||
"super + e" = "${nautilus} -w";
|
keybindings = {
|
||||||
"super + Escape" = "pkill -USR1 -x sxhkd";
|
"super + Return" = "${bash} -c ${alacritty} || ${terminator}";
|
||||||
"super + {_,shift + }w" = "${bspc} node -{c,k}";
|
"super + @space" = "${rofi} -show drun";
|
||||||
"super + m" = "${bspc} desktop -l next";
|
"super + e" = "${nautilus} -w";
|
||||||
"super + y" = "${bspc} node newest.marked.local -n newest.!automatic.local";
|
"super + Escape" = "pkill -USR1 -x sxhkd";
|
||||||
"super + g" = "${bspc} node -s biggest";
|
"super + alt + {q,r}" = "${bspc} {quit,wm -r}";
|
||||||
"super + {t,shift + t,s,f}" = "${bspc} node -t {tiled,pseudo_tiled,floating,fullscreen}";
|
"super + {_,shift + }w" = "${bspc} node -{c,k}";
|
||||||
"super + ctrl + {m,x,y,z}" = "${bspc} node -g {marked,locked,sticky,private}";
|
"super + m" = "${bspc} desktop -l next";
|
||||||
"super + {_,shift + }{h,j,k,l}" = "${bspc} node -{f,s} {west,south,north,east}";
|
"super + y" = "${bspc} node newest.marked.local -n newest.!automatic.local";
|
||||||
"super + {p,b,comma,period}" = "${bspc} node -f @{parent,brother,first,second}";
|
"super + g" = "${bspc} node -s biggest";
|
||||||
"super + {_,shift + }c" = "${bspc} node -f {next,prev}.local";
|
"super + {t,shift + t,s,f}" = "${bspc} node -t {tiled,pseudo_tiled,floating,fullscreen}";
|
||||||
"super + bracket{left,right}" = "${bspc} desktop -f {prev,next}.local";
|
"super + ctrl + {m,x,y,z}" = "${bspc} node -g {marked,locked,sticky,private}";
|
||||||
"super + {grave,Tab}" = "${bspc} {node,desktop} -f last";
|
"super + {_,shift + }{h,j,k,l}" = "${bspc} node -{f,s} {west,south,north,east}";
|
||||||
"super + {o,i}" = "${bspc} wm -h off;${bspc} node {older,newer} -f;${bspc} wm -h on";
|
"super + {p,b,comma,period}" = "${bspc} node -f @{parent,brother,first,second}";
|
||||||
"super + {_,shift + }{1-9,0}" = "${bspc} {desktop -f,node -d} 'focused:^{1-9,10}'";
|
"super + {_,shift + }c" = "${bspc} node -f {next,prev}.local";
|
||||||
"super + ctrl + {h,j,k,l}" = "${bspc} node -p {west,south,north,east}";
|
"super + bracket{left,right}" = "${bspc} desktop -f {prev,next}.local";
|
||||||
"super + ctrl + {1-9}" = "${bspc} node -o 0.{1-9}";
|
"super + {grave,Tab}" = "${bspc} {node,desktop} -f last";
|
||||||
"super + ctrl + space" = "${bspc} node -p cancel";
|
"super + {o,i}" = "${bspc} wm -h off;${bspc} node {older,newer} -f;${bspc} wm -h on";
|
||||||
"super + ctrl + shift + space" = "${bspc} query -N -d | xargs -I id -n 1 ${bspc} node id -p cancel";
|
"super + {_,shift + }{1-9,0}" = "${bspc} {desktop -f,node -d} 'focused:^{1-9,10}'";
|
||||||
"super + alt + {h,j,k,l}" = "${bspc} node -z {left -20 0,bottom 0 20,top 0 -20,right 20 0}";
|
"super + ctrl + {h,j,k,l}" = "${bspc} node -p {west,south,north,east}";
|
||||||
"super + alt + shift + {h,j,k,l}" = "${bspc} node -z {right -20 0,top 0 20,bottom 0 -20,left 20 0}";
|
"super + ctrl + {1-9}" = "${bspc} node -o 0.{1-9}";
|
||||||
"super + {Left,Down,Up,Right}" = "${bspc} node -v {-20 0,0 20,0 -20,20 0}";
|
"super + ctrl + space" = "${bspc} node -p cancel";
|
||||||
"XF86AudioRaiseVolume" = "${pulseaudioCtl} up";
|
"super + ctrl + shift + space" = "${bspc} query -N -d | xargs -I id -n 1 ${bspc} node id -p cancel";
|
||||||
"XF86AudioLowerVolume" = "${pulseaudioCtl} down";
|
"super + alt + {h,j,k,l}" = "${bspc} node -z {left -20 0,bottom 0 20,top 0 -20,right 20 0}";
|
||||||
"XF86AudioMute" = "${pulseaudioCtl} mute";
|
"super + alt + shift + {h,j,k,l}" = "${bspc} node -z {right -20 0,top 0 20,bottom 0 -20,left 20 0}";
|
||||||
"XF86AudioPlay" = "${playerctl} play-pause";
|
"super + {Left,Down,Up,Right}" = "${bspc} node -v {-20 0,0 20,0 -20,20 0}";
|
||||||
"XF86AudioNext" = "${playerctl} next";
|
"XF86AudioRaiseVolume" = "${pulseaudioCtl} up";
|
||||||
"XF86AudioPrev" = "${playerctl} previous";
|
"XF86AudioLowerVolume" = "${pulseaudioCtl} down";
|
||||||
|
"XF86AudioMute" = "${pulseaudioCtl} mute";
|
||||||
|
"XF86AudioPlay" = "${playerctl} play-pause";
|
||||||
|
"XF86AudioNext" = "${playerctl} next";
|
||||||
|
"XF86AudioPrev" = "${playerctl} previous";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
8
modules/terminator.nix
Normal file
8
modules/terminator.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
terminator
|
||||||
|
];
|
||||||
|
|
||||||
|
xdg.configFile."terminator/config".source = ../configs/terminator/config;
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue