Compare commits
No commits in common. "be405aa6b06eef5ba20fbcb807bbbd8f9a2e8dfa" and "2d6e5194400ce73d4cfbdb0e35b40ed150acd851" have entirely different histories.
be405aa6b0
...
2d6e519440
18 changed files with 335 additions and 556 deletions
|
@ -37,7 +37,6 @@
|
||||||
nixpkgs.lib.nixosSystem {
|
nixpkgs.lib.nixosSystem {
|
||||||
system = arch;
|
system = arch;
|
||||||
modules = [
|
modules = [
|
||||||
./nixosModules
|
|
||||||
./hosts/${host}
|
./hosts/${host}
|
||||||
./hosts/base
|
./hosts/base
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,7 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./desktop
|
|
||||||
./programs
|
|
||||||
];
|
|
||||||
}
|
|
Binary file not shown.
Before Width: | Height: | Size: 333 KiB |
|
@ -1,6 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./gnome.nix
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,125 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.desktop.gnome;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.desktop.gnome = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = false;
|
|
||||||
example = true;
|
|
||||||
description = "Enable my gnome configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
gnomeExtensions.grand-theft-focus
|
|
||||||
gnomeExtensions.vitals
|
|
||||||
gnomeExtensions.appindicator
|
|
||||||
gnome-commander
|
|
||||||
];
|
|
||||||
dconf = {
|
|
||||||
settings = {
|
|
||||||
"org/gnome/shell" = {
|
|
||||||
disable-user-extensions = false;
|
|
||||||
enabled-extensions = with pkgs.gnomeExtensions; [
|
|
||||||
grand-theft-focus.extensionUuid
|
|
||||||
vitals.extensionUuid
|
|
||||||
appindicator.extensionUuid
|
|
||||||
];
|
|
||||||
favorite-apps = [
|
|
||||||
"firefox.desktop"
|
|
||||||
"Alacritty.desktop"
|
|
||||||
"thunderbird.desktop"
|
|
||||||
"org.gnome.gnome-commander.desktop"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"org/gnome/desktop/interface" = {
|
|
||||||
color-scheme = "prefer-dark";
|
|
||||||
accent-color = "red";
|
|
||||||
show-battery-percentage = true;
|
|
||||||
gtk-enable-primary-paste = false;
|
|
||||||
};
|
|
||||||
"org/gnome/mutter" = {
|
|
||||||
dynamic-workspaces = true;
|
|
||||||
edge-tiling = true;
|
|
||||||
workspaces-only-on-primary = true;
|
|
||||||
};
|
|
||||||
"org/gnome/desktop/peripherals/touchpad" = {
|
|
||||||
natural-scroll = false;
|
|
||||||
click-method = "areas";
|
|
||||||
};
|
|
||||||
"org/gnome/desktop/wm/preferences" = {
|
|
||||||
button-layout = "appmenu:minimize,maximize,close";
|
|
||||||
resize-with-right-button = true;
|
|
||||||
};
|
|
||||||
"org/gnome/desktop/sound" = {
|
|
||||||
event-sounds = false;
|
|
||||||
};
|
|
||||||
"org/gnome/desktop/search-providers" = {
|
|
||||||
disabled = [
|
|
||||||
"org.gnome.Contacts.desktop"
|
|
||||||
"org.gnome.Calculator.desktop"
|
|
||||||
"org.gnome.Calendar.desktop"
|
|
||||||
"org.gnome.Characters.desktop"
|
|
||||||
"org.gnome.clocks.desktop"
|
|
||||||
"org.gnome.Software.desktop"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"org/gnome/shell/extensions/vitals" = {
|
|
||||||
position-in-panel = 0;
|
|
||||||
show-battery = true;
|
|
||||||
icon-style = 1;
|
|
||||||
hot-sensors = [
|
|
||||||
"__temperature_max__"
|
|
||||||
"_memory_available_"
|
|
||||||
"_storage_free_"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"org/gnome/desktop/background" =
|
|
||||||
let
|
|
||||||
bgPath = "file://${./assets/nyan_cat.jpg}";
|
|
||||||
in
|
|
||||||
{
|
|
||||||
picture-options = "zoom";
|
|
||||||
picture-uri = bgPath;
|
|
||||||
picture-uri-dark = bgPath;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
gtk = {
|
|
||||||
enable = true;
|
|
||||||
theme = {
|
|
||||||
name = "Adwaita-dark";
|
|
||||||
package = pkgs.gnome-themes-extra;
|
|
||||||
};
|
|
||||||
gtk3.extraConfig = {
|
|
||||||
gtk-application-prefer-dark-theme = 1;
|
|
||||||
};
|
|
||||||
gtk4.extraConfig = {
|
|
||||||
gtk-application-prefer-dark-theme = 1;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
qt = {
|
|
||||||
enable = true;
|
|
||||||
platformTheme.name = "Adwaita-dark";
|
|
||||||
style = {
|
|
||||||
name = "Adwaita-dark";
|
|
||||||
package = pkgs.adwaita-qt;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
xdg.portal = {
|
|
||||||
enable = true;
|
|
||||||
extraPortals = with pkgs; [ xdg-desktop-portal-gtk ];
|
|
||||||
configPackages = with pkgs; [ xdg-desktop-portal-gtk ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,32 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.programs.alacritty;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.programs.alacritty = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = true;
|
|
||||||
example = false;
|
|
||||||
description = "Enable my alacritty configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
programs.alacritty = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
general = {
|
|
||||||
import = [ "${pkgs.alacritty-theme}/gnome_terminal.toml" ];
|
|
||||||
};
|
|
||||||
font = {
|
|
||||||
size = 16;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,38 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.programs.codium;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.programs.codium = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = true;
|
|
||||||
example = false;
|
|
||||||
description = "Enable my codium configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
programs.vscode = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.vscodium;
|
|
||||||
extensions = with pkgs.vscode-extensions; [
|
|
||||||
jnoortheen.nix-ide
|
|
||||||
tamasfe.even-better-toml
|
|
||||||
vscodevim.vim
|
|
||||||
ms-azuretools.vscode-docker
|
|
||||||
ms-kubernetes-tools.vscode-kubernetes-tools
|
|
||||||
redhat.vscode-yaml
|
|
||||||
ms-python.python
|
|
||||||
ms-python.debugpy
|
|
||||||
ms-python.vscode-pylance
|
|
||||||
golang.go
|
|
||||||
];
|
|
||||||
mutableExtensionsDir = false;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,13 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./alacritty.nix
|
|
||||||
./codium.nix
|
|
||||||
./direnv.nix
|
|
||||||
./git.nix
|
|
||||||
./micro.nix
|
|
||||||
./tmux.nix
|
|
||||||
./zoxide.nix
|
|
||||||
./zsh.nix
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,37 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.programs.direnv;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.programs.direnv = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = true;
|
|
||||||
example = false;
|
|
||||||
description = "Enable my direnv configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
programs.direnv = {
|
|
||||||
enable = true;
|
|
||||||
enableZshIntegration = true;
|
|
||||||
nix-direnv.enable = true;
|
|
||||||
stdlib = ''
|
|
||||||
: ''${XDG_CACHE_HOME:=$HOME/.cache}
|
|
||||||
declare -A direnv_layout_dirs
|
|
||||||
direnv_layout_dir() {
|
|
||||||
echo "''${direnv_layout_dirs[$PWD]:=$(
|
|
||||||
echo -n "$XDG_CACHE_HOME"/direnv/layouts/
|
|
||||||
echo -n "$PWD" | sha1sum | cut -d ' ' -f 1
|
|
||||||
)}"
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,71 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.programs.git;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.programs.git = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = true;
|
|
||||||
example = false;
|
|
||||||
description = "Enable my git configuration";
|
|
||||||
};
|
|
||||||
work-config = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = false;
|
|
||||||
example = true;
|
|
||||||
description = "Generate my job configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
programs.git = {
|
|
||||||
enable = true;
|
|
||||||
userName = "Jakub Kropáček";
|
|
||||||
userEmail = "kropikuba@gmail.com";
|
|
||||||
includes =
|
|
||||||
if cfg.work-config then
|
|
||||||
let
|
|
||||||
workcfg = {
|
|
||||||
user = {
|
|
||||||
email = "jakub.kropacek@olc.cz";
|
|
||||||
name = "Jakub Kropáček";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
in
|
|
||||||
[
|
|
||||||
{
|
|
||||||
condition = "gitdir:~/Repositories/OLC/**";
|
|
||||||
contents = workcfg;
|
|
||||||
}
|
|
||||||
{
|
|
||||||
condition = "gitdir:~/Repositories/OLC-Hexpol/**";
|
|
||||||
contents = workcfg;
|
|
||||||
}
|
|
||||||
]
|
|
||||||
else
|
|
||||||
[ ];
|
|
||||||
extraConfig = {
|
|
||||||
init = {
|
|
||||||
defaultBranch = "master";
|
|
||||||
};
|
|
||||||
push = {
|
|
||||||
autoSetupRemote = true;
|
|
||||||
};
|
|
||||||
status = {
|
|
||||||
submoduleSummary = true;
|
|
||||||
};
|
|
||||||
diff = {
|
|
||||||
submodule = "log";
|
|
||||||
};
|
|
||||||
core = {
|
|
||||||
autocrlf = "input";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,28 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.programs.micro;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.programs.micro = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = true;
|
|
||||||
example = false;
|
|
||||||
description = "Enable my micro configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
programs.micro = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
colorscheme = "atom-dark";
|
|
||||||
wordwrap = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,41 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.programs.tmux;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.programs.tmux = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = true;
|
|
||||||
example = false;
|
|
||||||
description = "Enable my tmux configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
programs.tmux = {
|
|
||||||
enable = true;
|
|
||||||
mouse = true;
|
|
||||||
terminal = "tmux-256color";
|
|
||||||
plugins = with pkgs.tmuxPlugins; [
|
|
||||||
yank
|
|
||||||
sensible
|
|
||||||
];
|
|
||||||
extraConfig = ''
|
|
||||||
# Move status bar to top
|
|
||||||
set -g status-position top
|
|
||||||
|
|
||||||
# Indexing from 1 instead of 0
|
|
||||||
set -g base-index 1
|
|
||||||
set -g pane-base-index 1
|
|
||||||
set-window-option -g pane-base-index 1
|
|
||||||
set-option -g renumber-windows on
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,31 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.programs.zoxide;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.programs.zoxide = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = true;
|
|
||||||
example = false;
|
|
||||||
description = "Enable my zoxide configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
programs.fzf = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.zoxide = {
|
|
||||||
enable = true;
|
|
||||||
options = [
|
|
||||||
"--cmd cd"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,99 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cfg = config.krop.hm.programs.zsh;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.krop.hm.programs.zsh = {
|
|
||||||
enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = true;
|
|
||||||
example = false;
|
|
||||||
description = "Enable my zsh configuration";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
programs.zsh = {
|
|
||||||
enable = true;
|
|
||||||
autocd = true;
|
|
||||||
autosuggestion.enable = true;
|
|
||||||
syntaxHighlighting.enable = true;
|
|
||||||
initExtra = ''
|
|
||||||
bindkey "^[[1;3D" backward-word
|
|
||||||
bindkey "^[[1;5D" backward-word
|
|
||||||
bindkey "^[[1;3C" forward-word
|
|
||||||
bindkey "^[[1;5C" forward-word
|
|
||||||
bindkey "^[[3~" delete-char
|
|
||||||
|
|
||||||
autoload -Uz vcs_info
|
|
||||||
setopt auto_menu
|
|
||||||
setopt complete_in_word
|
|
||||||
setopt always_to_end
|
|
||||||
|
|
||||||
# zstyle command format
|
|
||||||
# zstyle :<namespace>:<function>:<completer>:<command>:<argument>:<tag> <style> <value>
|
|
||||||
zstyle ':completion:*' menu select
|
|
||||||
zstyle ':completion:*' special-dirs true
|
|
||||||
zstyle ':completion:*' list-colors ''${(s.:.)LS_COLORS}
|
|
||||||
zstyle ':completion:*' matcher-list 'm:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'r:|=*' 'l:|=* r:|=*'
|
|
||||||
zstyle ':completion:*' use-cache on
|
|
||||||
zstyle ':completion:*' cache-path "$ZSH/.zsh/.zcompcache"
|
|
||||||
|
|
||||||
|
|
||||||
precmd() {
|
|
||||||
vcs_info
|
|
||||||
is_toolbx_container
|
|
||||||
}
|
|
||||||
|
|
||||||
setopt PROMPT_SUBST
|
|
||||||
|
|
||||||
zstyle ':vcs_info:git:*' formats '[%b] '
|
|
||||||
|
|
||||||
is_toolbx_container() {
|
|
||||||
if [[ -f /run/.containerenv ]]; then
|
|
||||||
CONTAINER_NAME=$(grep -oP 'name="\K[^"]+' /run/.containerenv)
|
|
||||||
TOOLBX_INDICATOR="[%F{magenta}''${CONTAINER_NAME}%f] "
|
|
||||||
else
|
|
||||||
TOOLBX_INDICATOR=""
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
PROMPT='%2~ ''${TOOLBX_INDICATOR}''${vcs_info_msg_0_}»%b '
|
|
||||||
'';
|
|
||||||
dotDir = ".zsh";
|
|
||||||
completionInit = "autoload -U compinit; compinit -d $ZSH/.zcompdump";
|
|
||||||
history.path = "$ZDOTDIR/.zsh_history";
|
|
||||||
shellAliases = {
|
|
||||||
lg = "lazygit";
|
|
||||||
cls = "clear";
|
|
||||||
open = "xdg-open";
|
|
||||||
fire = "firefox";
|
|
||||||
la = "ls -al --color=auto";
|
|
||||||
gs = "git status";
|
|
||||||
ga = "git add";
|
|
||||||
gaa = "git add --all";
|
|
||||||
cg-run = "cargo run";
|
|
||||||
cg-build = "cargo build";
|
|
||||||
cg-test = "cargo test";
|
|
||||||
dc = "docker compose";
|
|
||||||
dc-build = "dc build";
|
|
||||||
dc-run = "dc run --rm";
|
|
||||||
dc-runr = "dc-run -u root";
|
|
||||||
dc-up = "dc up";
|
|
||||||
dc-upd = "dc up -d";
|
|
||||||
dc-down = "dc down";
|
|
||||||
dc-ls = "dc ls";
|
|
||||||
dc-pull = "dc pull";
|
|
||||||
ds-env = "env $(cat .env | grep \"^[A-Z]\" | xargs) docker stack";
|
|
||||||
bw-unlock = "BW_SESSION=$(bw unlock --raw) && export BW_SESSION";
|
|
||||||
t = "tmux";
|
|
||||||
pc = "pre-commit";
|
|
||||||
tb = "toolbox";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -14,6 +14,7 @@
|
||||||
imports = [
|
imports = [
|
||||||
inputs.home-manager.nixosModules.home-manager
|
inputs.home-manager.nixosModules.home-manager
|
||||||
inputs.nix-flatpak.nixosModules.nix-flatpak
|
inputs.nix-flatpak.nixosModules.nix-flatpak
|
||||||
|
../../nixosModules
|
||||||
];
|
];
|
||||||
|
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
|
@ -137,17 +138,6 @@
|
||||||
|
|
||||||
nix.nixPath = [ "nixpkgs=${inputs.nixpkgs}" ];
|
nix.nixPath = [ "nixpkgs=${inputs.nixpkgs}" ];
|
||||||
|
|
||||||
home-manager = {
|
|
||||||
useGlobalPkgs = true;
|
|
||||||
useUserPackages = true;
|
|
||||||
extraSpecialArgs = {
|
|
||||||
inherit inputs;
|
|
||||||
};
|
|
||||||
sharedModules = [
|
|
||||||
../../homeManagerModules
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
# This value determines the NixOS release from which the default
|
||||||
# settings for stateful data, like file locations and database versions
|
# settings for stateful data, like file locations and database versions
|
||||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
# on your system were taken. It‘s perfectly fine and recommended to leave
|
||||||
|
|
|
@ -63,8 +63,13 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
|
useGlobalPkgs = true;
|
||||||
|
useUserPackages = true;
|
||||||
|
extraSpecialArgs = {
|
||||||
|
inherit inputs;
|
||||||
|
};
|
||||||
users = {
|
users = {
|
||||||
"krop" = import ./home.nix;
|
"krop" = import ../../users/krop;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,15 +0,0 @@
|
||||||
{ config, pkgs, ... }:
|
|
||||||
{
|
|
||||||
home.username = "krop";
|
|
||||||
home.homeDirectory = "/home/krop";
|
|
||||||
home.stateVersion = "24.05";
|
|
||||||
|
|
||||||
krop.hm = {
|
|
||||||
desktop.gnome = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
programs.git = {
|
|
||||||
work-config = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -6,12 +6,17 @@
|
||||||
home.stateVersion = "24.05";
|
home.stateVersion = "24.05";
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
|
gnomeExtensions.grand-theft-focus
|
||||||
|
gnomeExtensions.vitals
|
||||||
|
gnomeExtensions.appindicator
|
||||||
spotify
|
spotify
|
||||||
moonlight-qt
|
moonlight-qt
|
||||||
alacritty
|
alacritty
|
||||||
alacritty-theme
|
alacritty-theme
|
||||||
nixd
|
nixd
|
||||||
nil
|
nil
|
||||||
|
fzf
|
||||||
|
zoxide
|
||||||
jetbrains-mono
|
jetbrains-mono
|
||||||
mattermost-desktop
|
mattermost-desktop
|
||||||
gh
|
gh
|
||||||
|
@ -29,6 +34,23 @@
|
||||||
iperf
|
iperf
|
||||||
d2
|
d2
|
||||||
gopls
|
gopls
|
||||||
|
gnome-commander
|
||||||
|
# # Adds the 'hello' command to your environment. It prints a friendly
|
||||||
|
# # "Hello, world!" when run.
|
||||||
|
# hello
|
||||||
|
|
||||||
|
# # It is sometimes useful to fine-tune packages, for example, by applying
|
||||||
|
# # overrides. You can do that directly here, just don't forget the
|
||||||
|
# # parentheses. Maybe you want to install Nerd Fonts with a limited number of
|
||||||
|
# # fonts?
|
||||||
|
# (nerdfonts.override { fonts = [ "FantasqueSansMono" ]; })
|
||||||
|
|
||||||
|
# # You can also create simple shell scripts directly inside your
|
||||||
|
# # configuration. For example, this adds a command 'my-hello' to your
|
||||||
|
# # environment:
|
||||||
|
# (writeShellScriptBin "my-hello" ''
|
||||||
|
# echo "Hello, ${config.home.username}!"
|
||||||
|
# '')
|
||||||
];
|
];
|
||||||
|
|
||||||
home.pointerCursor = {
|
home.pointerCursor = {
|
||||||
|
@ -39,10 +61,316 @@
|
||||||
size = 24;
|
size = 24;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
dconf = {
|
||||||
|
settings = {
|
||||||
|
"org/gnome/shell" = {
|
||||||
|
disable-user-extensions = false;
|
||||||
|
enabled-extensions = with pkgs.gnomeExtensions; [
|
||||||
|
grand-theft-focus.extensionUuid
|
||||||
|
vitals.extensionUuid
|
||||||
|
appindicator.extensionUuid
|
||||||
|
];
|
||||||
|
favorite-apps = [
|
||||||
|
"firefox.desktop"
|
||||||
|
"Alacritty.desktop"
|
||||||
|
"thunderbird.desktop"
|
||||||
|
"org.gnome.gnome-commander.desktop"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"org/gnome/desktop/interface" = {
|
||||||
|
color-scheme = "prefer-dark";
|
||||||
|
accent-color = "red";
|
||||||
|
show-battery-percentage = true;
|
||||||
|
gtk-enable-primary-paste = false;
|
||||||
|
};
|
||||||
|
"org/gnome/mutter" = {
|
||||||
|
dynamic-workspaces = true;
|
||||||
|
edge-tiling = true;
|
||||||
|
workspaces-only-on-primary = true;
|
||||||
|
};
|
||||||
|
"org/gnome/desktop/peripherals/touchpad" = {
|
||||||
|
natural-scroll = false;
|
||||||
|
click-method = "areas";
|
||||||
|
};
|
||||||
|
"org/gnome/desktop/wm/preferences" = {
|
||||||
|
button-layout = "appmenu:minimize,maximize,close";
|
||||||
|
resize-with-right-button = true;
|
||||||
|
};
|
||||||
|
"org/gnome/desktop/sound" = {
|
||||||
|
event-sounds = false;
|
||||||
|
};
|
||||||
|
"org/gnome/desktop/search-providers" = {
|
||||||
|
disabled = [
|
||||||
|
"org.gnome.Contacts.desktop"
|
||||||
|
"org.gnome.Calculator.desktop"
|
||||||
|
"org.gnome.Calendar.desktop"
|
||||||
|
"org.gnome.Characters.desktop"
|
||||||
|
"org.gnome.clocks.desktop"
|
||||||
|
"org.gnome.Software.desktop"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"org/gnome/shell/extensions/vitals" = {
|
||||||
|
position-in-panel = 0;
|
||||||
|
show-battery = true;
|
||||||
|
icon-style = 1;
|
||||||
|
hot-sensors = [
|
||||||
|
"__temperature_max__"
|
||||||
|
"_memory_available_"
|
||||||
|
"_storage_free_"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"org/gnome/desktop/background" =
|
||||||
|
let
|
||||||
|
bgPath = "file://${./nyan_cat.jpg}";
|
||||||
|
in
|
||||||
|
{
|
||||||
|
picture-options = "zoom";
|
||||||
|
picture-uri = bgPath;
|
||||||
|
picture-uri-dark = bgPath;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
gtk = {
|
||||||
|
enable = true;
|
||||||
|
theme = {
|
||||||
|
name = "Adwaita-dark";
|
||||||
|
package = pkgs.gnome-themes-extra;
|
||||||
|
};
|
||||||
|
gtk3.extraConfig = {
|
||||||
|
gtk-application-prefer-dark-theme = 1;
|
||||||
|
};
|
||||||
|
gtk4.extraConfig = {
|
||||||
|
gtk-application-prefer-dark-theme = 1;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
qt = {
|
||||||
|
enable = true;
|
||||||
|
platformTheme.name = "Adwaita-dark";
|
||||||
|
style = {
|
||||||
|
name = "Adwaita-dark";
|
||||||
|
package = pkgs.adwaita-qt;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
xdg.portal = {
|
||||||
|
enable = true;
|
||||||
|
extraPortals = with pkgs; [ xdg-desktop-portal-gtk ];
|
||||||
|
configPackages = with pkgs; [ xdg-desktop-portal-gtk ];
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.fzf = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
programs.go = {
|
programs.go = {
|
||||||
enable = true;
|
enable = true;
|
||||||
goPath = "Repositories/go";
|
goPath = "Repositories/go";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
programs.vscode = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.vscodium;
|
||||||
|
extensions = with pkgs.vscode-extensions; [
|
||||||
|
jnoortheen.nix-ide
|
||||||
|
tamasfe.even-better-toml
|
||||||
|
vscodevim.vim
|
||||||
|
ms-azuretools.vscode-docker
|
||||||
|
ms-kubernetes-tools.vscode-kubernetes-tools
|
||||||
|
redhat.vscode-yaml
|
||||||
|
ms-python.python
|
||||||
|
ms-python.debugpy
|
||||||
|
ms-python.vscode-pylance
|
||||||
|
golang.go
|
||||||
|
];
|
||||||
|
mutableExtensionsDir = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.zoxide = {
|
||||||
|
enable = true;
|
||||||
|
options = [
|
||||||
|
"--cmd cd"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.micro = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
colorscheme = "atom-dark";
|
||||||
|
wordwrap = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.direnv = {
|
||||||
|
enable = true;
|
||||||
|
enableZshIntegration = true;
|
||||||
|
nix-direnv.enable = true;
|
||||||
|
stdlib = ''
|
||||||
|
: ''${XDG_CACHE_HOME:=$HOME/.cache}
|
||||||
|
declare -A direnv_layout_dirs
|
||||||
|
direnv_layout_dir() {
|
||||||
|
echo "''${direnv_layout_dirs[$PWD]:=$(
|
||||||
|
echo -n "$XDG_CACHE_HOME"/direnv/layouts/
|
||||||
|
echo -n "$PWD" | sha1sum | cut -d ' ' -f 1
|
||||||
|
)}"
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.zsh = {
|
||||||
|
enable = true;
|
||||||
|
autocd = true;
|
||||||
|
autosuggestion.enable = true;
|
||||||
|
syntaxHighlighting.enable = true;
|
||||||
|
initExtra = ''
|
||||||
|
bindkey "^[[1;3D" backward-word
|
||||||
|
bindkey "^[[1;5D" backward-word
|
||||||
|
bindkey "^[[1;3C" forward-word
|
||||||
|
bindkey "^[[1;5C" forward-word
|
||||||
|
bindkey "^[[3~" delete-char
|
||||||
|
|
||||||
|
autoload -Uz vcs_info
|
||||||
|
setopt auto_menu
|
||||||
|
setopt complete_in_word
|
||||||
|
setopt always_to_end
|
||||||
|
|
||||||
|
# zstyle command format
|
||||||
|
# zstyle :<namespace>:<function>:<completer>:<command>:<argument>:<tag> <style> <value>
|
||||||
|
zstyle ':completion:*' menu select
|
||||||
|
zstyle ':completion:*' special-dirs true
|
||||||
|
zstyle ':completion:*' list-colors ''${(s.:.)LS_COLORS}
|
||||||
|
zstyle ':completion:*' matcher-list 'm:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'r:|=*' 'l:|=* r:|=*'
|
||||||
|
zstyle ':completion:*' use-cache on
|
||||||
|
zstyle ':completion:*' cache-path "$ZSH/.zsh/.zcompcache"
|
||||||
|
|
||||||
|
|
||||||
|
precmd() {
|
||||||
|
vcs_info
|
||||||
|
is_toolbx_container
|
||||||
|
}
|
||||||
|
|
||||||
|
setopt PROMPT_SUBST
|
||||||
|
|
||||||
|
zstyle ':vcs_info:git:*' formats '[%b] '
|
||||||
|
|
||||||
|
is_toolbx_container() {
|
||||||
|
if [[ -f /run/.containerenv ]]; then
|
||||||
|
CONTAINER_NAME=$(grep -oP 'name="\K[^"]+' /run/.containerenv)
|
||||||
|
TOOLBX_INDICATOR="[%F{magenta}''${CONTAINER_NAME}%f] "
|
||||||
|
else
|
||||||
|
TOOLBX_INDICATOR=""
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
PROMPT='%2~ ''${TOOLBX_INDICATOR}''${vcs_info_msg_0_}»%b '
|
||||||
|
'';
|
||||||
|
dotDir = ".zsh";
|
||||||
|
completionInit = "autoload -U compinit; compinit -d $ZSH/.zcompdump";
|
||||||
|
history.path = "$ZDOTDIR/.zsh_history";
|
||||||
|
shellAliases = {
|
||||||
|
lg = "lazygit";
|
||||||
|
cls = "clear";
|
||||||
|
open = "xdg-open";
|
||||||
|
fire = "firefox";
|
||||||
|
la = "ls -al --color=auto";
|
||||||
|
gs = "git status";
|
||||||
|
ga = "git add";
|
||||||
|
gaa = "git add --all";
|
||||||
|
cg-run = "cargo run";
|
||||||
|
cg-build = "cargo build";
|
||||||
|
cg-test = "cargo test";
|
||||||
|
dc = "docker compose";
|
||||||
|
dc-build = "dc build";
|
||||||
|
dc-run = "dc run --rm";
|
||||||
|
dc-runr = "dc-run -u root";
|
||||||
|
dc-up = "dc up";
|
||||||
|
dc-upd = "dc up -d";
|
||||||
|
dc-down = "dc down";
|
||||||
|
dc-ls = "dc ls";
|
||||||
|
dc-pull = "dc pull";
|
||||||
|
ds-env = "env $(cat .env | grep \"^[A-Z]\" | xargs) docker stack";
|
||||||
|
bw-unlock = "BW_SESSION=$(bw unlock --raw) && export BW_SESSION";
|
||||||
|
t = "tmux";
|
||||||
|
pc = "pre-commit";
|
||||||
|
tb = "toolbox";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.alacritty = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
general = {
|
||||||
|
import = [ "${pkgs.alacritty-theme}/gnome_terminal.toml" ];
|
||||||
|
};
|
||||||
|
font = {
|
||||||
|
size = 16;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.tmux = {
|
||||||
|
enable = true;
|
||||||
|
mouse = true;
|
||||||
|
terminal = "tmux-256color";
|
||||||
|
plugins = with pkgs.tmuxPlugins; [
|
||||||
|
yank
|
||||||
|
sensible
|
||||||
|
];
|
||||||
|
extraConfig = ''
|
||||||
|
# Move status bar to top
|
||||||
|
set -g status-position top
|
||||||
|
|
||||||
|
# Indexing from 1 instead of 0
|
||||||
|
set -g base-index 1
|
||||||
|
set -g pane-base-index 1
|
||||||
|
set-window-option -g pane-base-index 1
|
||||||
|
set-option -g renumber-windows on
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.git = {
|
||||||
|
enable = true;
|
||||||
|
userName = "Jakub Kropáček";
|
||||||
|
userEmail = "kropikuba@gmail.com";
|
||||||
|
includes =
|
||||||
|
let
|
||||||
|
workcfg = {
|
||||||
|
user = {
|
||||||
|
email = "jakub.kropacek@olc.cz";
|
||||||
|
name = "Jakub Kropáček";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
in
|
||||||
|
[
|
||||||
|
{
|
||||||
|
condition = "gitdir:~/Repositories/OLC/**";
|
||||||
|
contents = workcfg;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
condition = "gitdir:~/Repositories/OLC-Hexpol/**";
|
||||||
|
contents = workcfg;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
extraConfig = {
|
||||||
|
init = {
|
||||||
|
defaultBranch = "master";
|
||||||
|
};
|
||||||
|
push = {
|
||||||
|
autoSetupRemote = true;
|
||||||
|
};
|
||||||
|
status = {
|
||||||
|
submoduleSummary = true;
|
||||||
|
};
|
||||||
|
diff = {
|
||||||
|
submodule = "log";
|
||||||
|
};
|
||||||
|
core = {
|
||||||
|
autocrlf = "input";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
# Let Home Manager install and manage itself.
|
# Let Home Manager install and manage itself.
|
||||||
programs.home-manager.enable = true;
|
programs.home-manager.enable = true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue