aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Kummerlaender2018-05-05 13:02:04 +0200
committerAdrian Kummerlaender2018-05-05 13:02:04 +0200
commitdea9a66fccca94ed27387246e384f3dcb20501f6 (patch)
tree06ed6657b0d014d5e8faa0a20b267bf6a9f34472
parent74951f7eb0d8914201a5a4fa1b534abfe0ecfa0d (diff)
downloadnixos_home-dea9a66fccca94ed27387246e384f3dcb20501f6.tar
nixos_home-dea9a66fccca94ed27387246e384f3dcb20501f6.tar.gz
nixos_home-dea9a66fccca94ed27387246e384f3dcb20501f6.tar.bz2
nixos_home-dea9a66fccca94ed27387246e384f3dcb20501f6.tar.lz
nixos_home-dea9a66fccca94ed27387246e384f3dcb20501f6.tar.xz
nixos_home-dea9a66fccca94ed27387246e384f3dcb20501f6.tar.zst
nixos_home-dea9a66fccca94ed27387246e384f3dcb20501f6.zip
Basic attempt at a better structure
-rw-r--r--conf/kitty.conf31
-rw-r--r--conf/pwmt/zathurarc16
-rw-r--r--conf/urxvt.Xresources54
-rw-r--r--conf/xdg/user-dirs.dirs3
-rw-r--r--gui/conf/xmonad.hs (renamed from conf/xmonad/xmonad.hs)2
-rw-r--r--gui/default.nix57
-rw-r--r--gui/gtk.nix54
-rw-r--r--gui/kitty.nix41
-rw-r--r--gui/pcmanfm.nix17
-rw-r--r--gui/pkgs/oomox-archdroid-icon-theme.nix (renamed from pkgs/oomox-archdroid-icon-theme.nix)0
-rw-r--r--gui/pkgs/oomox-gtk-theme.nix (renamed from pkgs/oomox-gtk-theme.nix)0
-rw-r--r--gui/rofi.nix55
-rw-r--r--gui/urxvt.nix62
-rw-r--r--gui/vim.nix21
-rw-r--r--gui/xmonad.nix9
-rw-r--r--gui/zathura.nix26
-rw-r--r--home.nix179
17 files changed, 347 insertions, 280 deletions
diff --git a/conf/kitty.conf b/conf/kitty.conf
deleted file mode 100644
index 29c1362..0000000
--- a/conf/kitty.conf
+++ /dev/null
@@ -1,31 +0,0 @@
-font_family iosevka
-font_size 10
-font_size_delta 1
-adjust_line_height 110%
-
-background #161616
-foreground #F2F2F2
-# black
-color0 #161616
-color8 #F2F2F2
-# red
-color1 #8C3346
-color9 #ff0000
-# green
-color2 #aadb0f
-color10 #909636
-# yellow
-color3 #E4E093
-color11 #ffff00
-# blue
-color4 #352F6A
-color12 #0000ff
-# magenta
-color5 #ce5c00
-color13 #f57900
-# cyan
-color6 #89b6e2
-color14 #46a4ff
-# white
-color7 #F2F2F2
-color15 #ffffff
diff --git a/conf/pwmt/zathurarc b/conf/pwmt/zathurarc
deleted file mode 100644
index 3258fe6..0000000
--- a/conf/pwmt/zathurarc
+++ /dev/null
@@ -1,16 +0,0 @@
-set font "Iosevka 14px"
-
-set inputbar-bg "#161616"
-set inputbar-fg "#909737"
-
-set statusbar-bg "#161616"
-set statusbar-fg "#909737"
-
-set completion-bg "#161616"
-set completion-fg "#909737"
-
-set completion-highlight-bg "#909737"
-set completion-highlight-fg "#161616"
-
-set recolor-lightcolor "#161616"
-set recolor-darkcolor "#ffffff"
diff --git a/conf/urxvt.Xresources b/conf/urxvt.Xresources
deleted file mode 100644
index 5cab29d..0000000
--- a/conf/urxvt.Xresources
+++ /dev/null
@@ -1,54 +0,0 @@
-URxvt.saveLines: 10000
-URxvt.scrollBar: false
-URxvt.font: xft:Iosevka:pixelsize=12
-URxvt.letterSpace: 0
-URxvt.transparent: false
-URxvt.inheritPixmap: false
-URxvt.fading: 20
-URxvt.dynamicColors: on
-
-URxvt.perl-ext-common: default,matcher,clipboard,resize-font
-URxvt.matcher.button: 1
-URxvt.matcher.pattern.1: \\bwww\\.[\\w-]\\.[\\w./?&@#-]*[\\w/-]
-URxvt.url-launcher: firefox
-
-URxvt.keysym.Control-Up: \033[1;5A
-URxvt.keysym.Control-Down: \033[1;5B
-URxvt.keysym.Control-Left: \033[1;5D
-URxvt.keysym.Control-Right: \033[1;5C
-
-URxvt.keysym.M-Down: \033[1;3B
-URxvt.keysym.M-Up: \033[1;3A
-URxvt.keysym.M-Left: \033[1;3D
-URxvt.keysym.M-Right: \033[1;3C
-
-URxvt.keysym.M-c: perl:clipboard:copy
-URxvt.keysym.M-v: perl:clipboard:paste
-
-URxvt.background: #161616
-URxvt.foreground: #F2F2F2
-
-! black
-URxvt.color0: #161616
-URxvt.color8: #F2F2F2
-! red
-URxvt.color1: #8C3346
-URxvt.color9: #ff0000
-! green
-URxvt.color2: #aadb0f
-URxvt.color10: #909636
-! yellow
-URxvt.color3: #E4E093
-URxvt.color11: #ffff00
-! blue
-URxvt.color4: #352F6A
-URxvt.color12: #0000ff
-! magenta
-URxvt.color5: #ce5c00
-URxvt.color13: #f57900
-! cyan
-URxvt.color6: #89b6e2
-URxvt.color14: #46a4ff
-! white
-URxvt.color7: #F2F2F2
-URxvt.color15: #ffffff
diff --git a/conf/xdg/user-dirs.dirs b/conf/xdg/user-dirs.dirs
deleted file mode 100644
index 9088276..0000000
--- a/conf/xdg/user-dirs.dirs
+++ /dev/null
@@ -1,3 +0,0 @@
-XDG_TEMPLATES_DIR="$HOME/"
-XDG_DESKTOP_DIR="$HOME/"
-XDG_DOWNLOADS_DIR="$HOME/downloads/"
diff --git a/conf/xmonad/xmonad.hs b/gui/conf/xmonad.hs
index f42ec34..46547eb 100644
--- a/conf/xmonad/xmonad.hs
+++ b/gui/conf/xmonad.hs
@@ -63,7 +63,7 @@ sideBarRight = floatRectRight $ 1/2
scratchpads = [ NS "terminal" "kitty --class=scratchterm" (className =? "scratchterm")
(customFloating dropDown)
, NS "browser" "firefox" (className =? "Firefox")
- (customFloating dropDown)
+ (customFloating dropDownLarge)
, NS "documentation" "zeal" (className =? "Zeal")
(customFloating dropDown)
, NS "messaging" "telegram-desktop" (className =? "TelegramDesktop")
diff --git a/gui/default.nix b/gui/default.nix
new file mode 100644
index 0000000..2d27f7c
--- /dev/null
+++ b/gui/default.nix
@@ -0,0 +1,57 @@
+{ pkgs, ... }:
+
+{
+ home = {
+ packages = with pkgs; [
+ # file viewers
+ sxiv
+ mpv
+ paraview
+ libreoffice
+ # communication
+ thunderbird
+ tdesktop
+ # UI dev utilities (CLI utilities are added in project specific nix-shells)
+ zeal
+ hotspot
+ qcachegrind
+ gitg
+ ];
+
+ file.".config/user-dirs.dirs".text = ''
+ XDG_TEMPLATES_DIR="$HOME/"
+ XDG_DESKTOP_DIR="$HOME/"
+ XDG_DOWNLOADS_DIR="$HOME/downloads/"
+ '';
+ };
+
+ xsession = {
+ enable = true;
+ initExtra = ''
+ xsetroot -cursor_name left_ptr
+ xset b off
+ '';
+ };
+
+ imports = [
+ # desktop environment
+ ./xmonad.nix
+ ./rofi.nix
+ ./gtk.nix
+ # terminals
+ ./kitty.nix
+ ./urxvt.nix
+ # tools
+ ./vim.nix
+ ./pcmanfm.nix
+ # file viewers
+ ./zathura.nix
+ ];
+
+ services.syncthing.enable = true;
+
+ programs.firefox = {
+ enable = true;
+ enableAdobeFlash = true;
+ };
+}
diff --git a/gui/gtk.nix b/gui/gtk.nix
new file mode 100644
index 0000000..0a580f5
--- /dev/null
+++ b/gui/gtk.nix
@@ -0,0 +1,54 @@
+{ pkgs, ... }:
+
+{
+ gtk = {
+ enable = true;
+
+ theme = let
+ oomox-gtk-theme = pkgs.callPackage ./pkgs/oomox-gtk-theme.nix {
+ pkgs-unstable = import <nixpkgs-unstable> {};
+ theme = {
+ accent_bg = "aadb0f";
+ bg = "d8d8d8";
+ fg = "101010";
+ btn_bg = "f5f5f5";
+ btn_fg = "111111";
+ caret_size = 0.04;
+ caret1_fg = "101010";
+ caret2_fg = "101010";
+ hdr_btn_bg = "161616";
+ hdr_btn_fg = "aadb0f";
+ menu_bg = "909737";
+ menu_fg = "1a1a1a";
+ sel_bg = "aadb0f";
+ sel_fg = "101010";
+ txt_bg = "ffffff";
+ txt_fg = "101010";
+ gradient = 0.0;
+ roundness = 0;
+ spacing = 1;
+ wm_border_focus = "909737";
+ wm_border_unfocus = "909737";
+ gtk3_generate_dark = false;
+ };
+ };
+ in {
+ name = "oomox";
+ package = oomox-gtk-theme;
+ };
+
+ iconTheme = let
+ oomox-archdroid-icon-theme = pkgs.callPackage ./pkgs/oomox-archdroid-icon-theme.nix {
+ color = "909737";
+ };
+ in {
+ name = "oomox-archdroid";
+ package = oomox-archdroid-icon-theme;
+ };
+
+ font = {
+ name = "Iosevka 10";
+ package = pkgs.iosevka;
+ };
+ };
+}
diff --git a/gui/kitty.nix b/gui/kitty.nix
new file mode 100644
index 0000000..46abef2
--- /dev/null
+++ b/gui/kitty.nix
@@ -0,0 +1,41 @@
+{ pkgs, ... }:
+
+{
+ home = {
+ packages = [ pkgs.kitty ];
+
+ file.".config/kitty/kitty.conf".text = ''
+ font_family iosevka
+ font_size 10
+ font_size_delta 1
+ adjust_line_height 110%
+
+ background #161616
+ foreground #F2F2F2
+ # black
+ color0 #161616
+ color8 #F2F2F2
+ # red
+ color1 #8C3346
+ color9 #ff0000
+ # green
+ color2 #aadb0f
+ color10 #909636
+ # yellow
+ color3 #E4E093
+ color11 #ffff00
+ # blue
+ color4 #352F6A
+ color12 #0000ff
+ # magenta
+ color5 #ce5c00
+ color13 #f57900
+ # cyan
+ color6 #89b6e2
+ color14 #46a4ff
+ # white
+ color7 #F2F2F2
+ color15 #ffffff
+ '';
+ };
+}
diff --git a/gui/pcmanfm.nix b/gui/pcmanfm.nix
new file mode 100644
index 0000000..00a1393
--- /dev/null
+++ b/gui/pcmanfm.nix
@@ -0,0 +1,17 @@
+{ pkgs, ... }:
+
+{
+ home = {
+ packages = with pkgs; [
+ pcmanfm gvfs lxmenu-data shared_mime_info
+ veracrypt
+ ];
+
+ sessionVariables = {
+ # required to enable auto-mounting in pcmanfm
+ GIO_EXTRA_MODULES = [ "${pkgs.gvfs}/lib/gio/modules" ];
+ # use GTK theme in libreoffice
+ SAL_USE_VCLPLUGIN = "gtk";
+ };
+ };
+}
diff --git a/pkgs/oomox-archdroid-icon-theme.nix b/gui/pkgs/oomox-archdroid-icon-theme.nix
index 764bf2f..764bf2f 100644
--- a/pkgs/oomox-archdroid-icon-theme.nix
+++ b/gui/pkgs/oomox-archdroid-icon-theme.nix
diff --git a/pkgs/oomox-gtk-theme.nix b/gui/pkgs/oomox-gtk-theme.nix
index 6e217dd..6e217dd 100644
--- a/pkgs/oomox-gtk-theme.nix
+++ b/gui/pkgs/oomox-gtk-theme.nix
diff --git a/gui/rofi.nix b/gui/rofi.nix
new file mode 100644
index 0000000..f2a9eca
--- /dev/null
+++ b/gui/rofi.nix
@@ -0,0 +1,55 @@
+{ pkgs, ... }:
+
+{
+ programs.rofi = {
+ enable = true;
+ location = "top";
+ font = "Iosevka 12";
+ separator = "none";
+ scrollbar = false;
+ borderWidth = 6;
+ yoffset = -6;
+
+ colors = {
+ window = {
+ background = "#222222";
+ border = "#aadb0f";
+ separator = "#000000";
+ };
+ rows = {
+ normal = {
+ background = "#222222";
+ foreground = "#8e8e8e";
+ backgroundAlt = "#161616";
+ highlight = {
+ background = "#111111";
+ foreground = "#aadb0f";
+ };
+ };
+ active = {
+ background = "#222222";
+ foreground = "#8e8e8e";
+ backgroundAlt = "#161616";
+ highlight = {
+ background = "#111111";
+ foreground = "#aadb0f";
+ };
+ };
+ urgent = {
+ background = "#222222";
+ foreground = "#dc322f";
+ backgroundAlt = "#161616";
+ highlight = {
+ background = "#dc322f";
+ foreground = "#161616";
+ };
+ };
+ };
+ };
+
+ extraConfig = ''
+ rofi.modi: combi
+ rofi.combi-modi: windowcd,drun,ssh
+ '';
+ };
+}
diff --git a/gui/urxvt.nix b/gui/urxvt.nix
new file mode 100644
index 0000000..408d5d5
--- /dev/null
+++ b/gui/urxvt.nix
@@ -0,0 +1,62 @@
+{ pkgs, ... }:
+
+{
+ home.packages = [ pkgs.rxvt_unicode ];
+
+ xresources.extraConfig = ''
+ URxvt.saveLines: 10000
+ URxvt.scrollBar: false
+ URxvt.font: xft:Iosevka:pixelsize=12
+ URxvt.letterSpace: 0
+ URxvt.transparent: false
+ URxvt.inheritPixmap: false
+ URxvt.fading: 20
+ URxvt.dynamicColors: on
+
+ URxvt.perl-ext-common: default,matcher,clipboard,resize-font
+ URxvt.matcher.button: 1
+ URxvt.matcher.pattern.1: \\bwww\\.[\\w-]\\.[\\w./?&@#-]*[\\w/-]
+ URxvt.url-launcher: firefox
+
+ URxvt.keysym.Control-Up: \033[1;5A
+ URxvt.keysym.Control-Down: \033[1;5B
+ URxvt.keysym.Control-Left: \033[1;5D
+ URxvt.keysym.Control-Right: \033[1;5C
+
+ URxvt.keysym.M-Down: \033[1;3B
+ URxvt.keysym.M-Up: \033[1;3A
+ URxvt.keysym.M-Left: \033[1;3D
+ URxvt.keysym.M-Right: \033[1;3C
+
+ URxvt.keysym.M-c: perl:clipboard:copy
+ URxvt.keysym.M-v: perl:clipboard:paste
+
+ URxvt.background: #161616
+ URxvt.foreground: #F2F2F2
+
+ ! black
+ URxvt.color0: #161616
+ URxvt.color8: #F2F2F2
+ ! red
+ URxvt.color1: #8C3346
+ URxvt.color9: #ff0000
+ ! green
+ URxvt.color2: #aadb0f
+ URxvt.color10: #909636
+ ! yellow
+ URxvt.color3: #E4E093
+ URxvt.color11: #ffff00
+ ! blue
+ URxvt.color4: #352F6A
+ URxvt.color12: #0000ff
+ ! magenta
+ URxvt.color5: #ce5c00
+ URxvt.color13: #f57900
+ ! cyan
+ URxvt.color6: #89b6e2
+ URxvt.color14: #46a4ff
+ ! white
+ URxvt.color7: #F2F2F2
+ URxvt.color15: #ffffff
+ '';
+}
diff --git a/gui/vim.nix b/gui/vim.nix
new file mode 100644
index 0000000..1b2c4db
--- /dev/null
+++ b/gui/vim.nix
@@ -0,0 +1,21 @@
+{ pkgs, ... }:
+
+{
+ home = {
+ # vim is configured globally for all users but common is the only GUI user
+ file.".gvimrc".text = ''
+ set guifont=Iosevka\ 10
+ set linespace=2
+ set guioptions=agim
+ set guioptions-=m
+ 2match SpecialKeyTab /\t/
+ '';
+ };
+
+ gtk = {
+ gtk2.extraConfig = ''
+ style "vimfix" { bg[NORMAL] = "#161616" }
+ widget "vim-main-window.*GtkForm" style "vimfix"
+ '';
+ };
+}
diff --git a/gui/xmonad.nix b/gui/xmonad.nix
new file mode 100644
index 0000000..85f86c2
--- /dev/null
+++ b/gui/xmonad.nix
@@ -0,0 +1,9 @@
+{ pkgs, ... }:
+
+{
+ xsession.windowManager.xmonad = {
+ enable = true;
+ enableContribAndExtras = true;
+ config = ./conf/xmonad.hs;
+ };
+}
diff --git a/gui/zathura.nix b/gui/zathura.nix
new file mode 100644
index 0000000..41eefbc
--- /dev/null
+++ b/gui/zathura.nix
@@ -0,0 +1,26 @@
+{ pkgs, ... }:
+
+{
+ home = {
+ packages = [ pkgs.zathura ];
+
+ file.".config/zathura/zathurarc".text = ''
+ set font "Iosevka 14px"
+
+ set inputbar-bg "#161616"
+ set inputbar-fg "#909737"
+
+ set statusbar-bg "#161616"
+ set statusbar-fg "#909737"
+
+ set completion-bg "#161616"
+ set completion-fg "#909737"
+
+ set completion-highlight-bg "#909737"
+ set completion-highlight-fg "#161616"
+
+ set recolor-lightcolor "#161616"
+ set recolor-darkcolor "#ffffff"
+ '';
+ };
+}
diff --git a/home.nix b/home.nix
index 843a93d..50d8787 100644
--- a/home.nix
+++ b/home.nix
@@ -6,50 +6,12 @@
path = ''https://github.com/rycee/home-manager/archive/master.tar.gz'';
};
+ imports = [
+ ./gui/default.nix
+ ];
+
home = {
keyboard.layout = "de";
-
- packages = with pkgs; [
- # terminals
- rxvt_unicode
- kitty
- # file viewers
- zathura
- sxiv
- mpv
- paraview
- libreoffice
- # file management
- pcmanfm gvfs lxmenu-data shared_mime_info
- veracrypt
- # communication
- tdesktop
- # UI dev utilities (CLI utilities are added in project specific nix-shells)
- zeal
- hotspot
- qcachegrind
- gitg
- ];
-
- sessionVariables = {
- # required to enable auto-mounting in pcmanfm
- GIO_EXTRA_MODULES = [ "${pkgs.gvfs}/lib/gio/modules" ];
- # use GTK theme in libreoffice
- SAL_USE_VCLPLUGIN = "gtk";
- };
-
- # vim is configured globally for all users but common is the only GUI user
- file.".gvimrc".text = ''
- set guifont=Iosevka\ 10
- set linespace=2
- set guioptions=agim
- set guioptions-=m
- 2match SpecialKeyTab /\t/
- '';
-
- file.".config/kitty/kitty.conf".source = ./conf/kitty.conf;
-
- file.".config/user-dirs.dirs".source = ./conf/xdg/user-dirs.dirs;
};
programs.git = {
@@ -66,137 +28,4 @@
defaultCacheTtlSsh = 120;
enableScDaemon = false;
};
-
- services.syncthing.enable = true;
-
- xsession = {
- enable = true;
- initExtra = ''
- xsetroot -cursor_name left_ptr
- xset b off
- '';
-
- windowManager.xmonad = {
- enable = true;
- enableContribAndExtras = true;
- config = ./conf/xmonad/xmonad.hs;
- };
- };
-
- xresources.extraConfig = builtins.readFile ./conf/urxvt.Xresources;
-
- gtk = {
- enable = true;
-
- theme = let
- oomox-gtk-theme = pkgs.callPackage ./pkgs/oomox-gtk-theme.nix {
- pkgs-unstable = import <nixpkgs-unstable> {};
- theme = {
- accent_bg = "aadb0f";
- bg = "d8d8d8";
- fg = "101010";
- btn_bg = "f5f5f5";
- btn_fg = "111111";
- caret_size = 0.04;
- caret1_fg = "101010";
- caret2_fg = "101010";
- hdr_btn_bg = "161616";
- hdr_btn_fg = "aadb0f";
- menu_bg = "909737";
- menu_fg = "1a1a1a";
- sel_bg = "aadb0f";
- sel_fg = "101010";
- txt_bg = "ffffff";
- txt_fg = "101010";
- gradient = 0.0;
- roundness = 0;
- spacing = 1;
- wm_border_focus = "909737";
- wm_border_unfocus = "909737";
- gtk3_generate_dark = false;
- };
- };
- in {
- name = "oomox";
- package = oomox-gtk-theme;
- };
-
- iconTheme = let
- oomox-archdroid-icon-theme = pkgs.callPackage ./pkgs/oomox-archdroid-icon-theme.nix {
- color = "909737";
- };
- in {
- name = "oomox-archdroid";
- package = oomox-archdroid-icon-theme;
- };
-
- font = {
- name = "Iosevka 10";
- package = pkgs.iosevka;
- };
-
- gtk2.extraConfig = ''
- style "vimfix" { bg[NORMAL] = "#161616" }
- widget "vim-main-window.*GtkForm" style "vimfix"
- '';
- };
-
- programs.rofi = {
- enable = true;
- location = "top";
- font = "Iosevka 12";
- separator = "none";
- scrollbar = false;
- borderWidth = 6;
- yoffset = -6;
-
- colors = {
- window = {
- background = "#222222";
- border = "#aadb0f";
- separator = "#000000";
- };
- rows = {
- normal = {
- background = "#222222";
- foreground = "#8e8e8e";
- backgroundAlt = "#161616";
- highlight = {
- background = "#111111";
- foreground = "#aadb0f";
- };
- };
- active = {
- background = "#222222";
- foreground = "#8e8e8e";
- backgroundAlt = "#161616";
- highlight = {
- background = "#111111";
- foreground = "#aadb0f";
- };
- };
- urgent = {
- background = "#222222";
- foreground = "#dc322f";
- backgroundAlt = "#161616";
- highlight = {
- background = "#dc322f";
- foreground = "#161616";
- };
- };
- };
- };
-
- extraConfig = ''
- rofi.modi: combi
- rofi.combi-modi: windowcd,drun,ssh
- '';
- };
-
- programs.firefox = {
- enable = true;
- enableAdobeFlash = true;
- };
-
- home.file.".config/zathura/zathurarc".text = builtins.readFile ./conf/pwmt/zathurarc;
}