diff options
Diffstat (limited to 'config')
| -rw-r--r-- | config/alacritty/default.nix | 7 | ||||
| -rw-r--r-- | config/bash.nix | 43 | ||||
| -rw-r--r-- | config/dotfiles.nix | 8 | ||||
| -rw-r--r-- | config/dunst/dunstrc | 63 | ||||
| -rw-r--r-- | config/dwl.nix | 11 | ||||
| -rw-r--r-- | config/fuzzel/default.nix | 6 | ||||
| -rw-r--r-- | config/git/default.nix | 9 | ||||
| -rw-r--r-- | config/hypr/hyprland.conf | 108 | ||||
| -rw-r--r-- | config/hypr/hyprpaper.conf | 3 | ||||
| -rw-r--r-- | config/nvim/default.nix | 17 | ||||
| -rw-r--r-- | config/waybar/config | 58 | ||||
| -rw-r--r-- | config/waybar/style.css | 99 |
12 files changed, 95 insertions, 337 deletions
diff --git a/config/alacritty/default.nix b/config/alacritty/default.nix index af272ef..04ff1b8 100644 --- a/config/alacritty/default.nix +++ b/config/alacritty/default.nix @@ -1,11 +1,6 @@ { pkgs, config, ... }: { - programs.git = { - enable = true; - userName = "Raghuram Subramani"; - userEmail = "raghus2247@gmail.com"; - }; - programs.alacritty.enable = true; + home.file.".config/alacritty/alacritty.toml".source = ./alacritty.toml; } diff --git a/config/bash.nix b/config/bash.nix new file mode 100644 index 0000000..506400c --- /dev/null +++ b/config/bash.nix @@ -0,0 +1,43 @@ +{ + programs.bash = { + enable = true; + initExtra= '' + export PS1="\[\e[38;5;243m\]\h \[\e[38;5;254m\]\w \[\033[0m\]> " + set -o vi + + if [[ -n "$IN_NIX_SHELL" ]]; then + export PS1="\[\e[38;5;242m\](dev) $PS1" + fi + + sessionizer() { + DIR=$(fd . /data --type d -L -H | fzf) + SESSION_NAME="$DIR_$(date +%M%S)" + + if [ -n "$DIR" ] + then + if [ "$1" == "-cd" ] + then + cd $DIR + return + fi + tmux new-session -d -c "$DIR" -s "$SESSION_NAME" + if [ -n "$TMUX" ] + then + tmux switch -t "$SESSION_NAME" + else + tmux attach -t "$SESSION_NAME" + fi + fi + } + + if [[ $- != *i* ]] + then + sessionizer + fi + + bind '"\C-f": "sessionizer\n"' + bind '"\C-a": "sessionizer -cd\n"' + ''; + }; + +} diff --git a/config/dotfiles.nix b/config/dotfiles.nix new file mode 100644 index 0000000..1a89f9b --- /dev/null +++ b/config/dotfiles.nix @@ -0,0 +1,8 @@ +{ home, lib, ... }: + +{ + home.file = { + ".tmux.conf".source = ./.tmux.conf; + ".fdignore".source = ./.fdignore; + }; +} diff --git a/config/dunst/dunstrc b/config/dunst/dunstrc deleted file mode 100644 index 902ba1c..0000000 --- a/config/dunst/dunstrc +++ /dev/null @@ -1,63 +0,0 @@ -[global] - monitor = 1 - follow = none - indicate_hidden = yes - shrink = no - transparency = 0 - separator_height = 2 - padding = 8 - horizontal_padding = 8 - frame_width = 3 - frame_color = "#aaaaaa" - separator_color = frame - sort = yes - idle_threshold = 120 - font = Monospace 8 - line_height = 0 - markup = full - format = "<b>%s</b>\n%b" - alignment = left - vertical_alignment = center - show_age_threshold = 60 - word_wrap = yes - ellipsize = middle - ignore_newline = no - stack_duplicates = true - hide_duplicate_count = false - show_indicators = yes - icon_position = left - min_icon_size = 0 - max_icon_size = 32 - icon_path = /usr/share/icons/gnome/16x16/status/:/usr/share/icons/gnome/16x16/devices/ - sticky_history = yes - history_length = 20 - dmenu = /usr/bin/dmenu -p dunst: - browser = /usr/bin/sensible-browser - always_run_script = true - title = Dunst - class = Dunst - corner_radius = 0 - ignore_dbusclose = false - force_xinerama = false - mouse_left_click = close_current - mouse_middle_click = do_action, close_current - mouse_right_click = close_all -[experimental] - per_monitor_dpi = false - -[urgency_low] - background = "#131417" - foreground = "#ffffff" - timeout = 10 - -[urgency_normal] - background = "#131417" - foreground = "#ffffff" - timeout = 10 - -[urgency_critical] - background = "#131417" - foreground = "#ffffff" - timeout = 0 - -# vim: ft=cfg diff --git a/config/dwl.nix b/config/dwl.nix new file mode 100644 index 0000000..86d8f25 --- /dev/null +++ b/config/dwl.nix @@ -0,0 +1,11 @@ +{ pkgs, home, fetchFromGitHub, ... }: + +let + dwl-custom = (pkgs.callPackage ../packages/dwl-custom.nix {}); +in { + xdg.portal.enable = true; + xdg.portal.configPackages = [ pkgs.xdg-desktop-portal-gtk pkgs.xdg-desktop-portal-hyprland ]; + xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk pkgs.xdg-desktop-portal-hyprland ]; + + home.packages = [ dwl-custom ]; +} diff --git a/config/fuzzel/default.nix b/config/fuzzel/default.nix new file mode 100644 index 0000000..13feee4 --- /dev/null +++ b/config/fuzzel/default.nix @@ -0,0 +1,6 @@ +{ pkgs, config, ... }: + +{ + home.packages = [ pkgs.fuzzel ]; + home.file.".config/fuzzel/fuzzel.ini".source = ./fuzzel.ini; +} diff --git a/config/git/default.nix b/config/git/default.nix new file mode 100644 index 0000000..4fe7ef6 --- /dev/null +++ b/config/git/default.nix @@ -0,0 +1,9 @@ +{ pkgs, config, ... }: + +{ + programs.git = { + enable = true; + userName = "Raghuram Subramani"; + userEmail = "raghus2247@gmail.com"; + }; +} diff --git a/config/hypr/hyprland.conf b/config/hypr/hyprland.conf deleted file mode 100644 index ff7a4a6..0000000 --- a/config/hypr/hyprland.conf +++ /dev/null @@ -1,108 +0,0 @@ -monitor=eDP-1,1920x1080@60,0x0,1 -monitor=HDMI-A-1,2560x1440@60,-2560x-350,1 - -exec-once = hyprpaper & waybar & dunst & /nix/store/$(ls -la /nix/store | grep 'polkit-gnome' | grep 4096 | awk '{print $9}' | sed -n '$p')/libexec/polkit-gnome-authentication-agent-1 & blueman-applet & nm-applet - -xwayland { - force_zero_scaling = true -} - -input { - kb_layout = us - follow_mouse = 1 - touchpad { - natural_scroll = yes - } - sensitivity = 0 -} - -general { - gaps_in = 4 - gaps_out = 8 - border_size = 2 - col.active_border = rgba(f2f0faff) - col.inactive_border = rgba(272727ff) - - layout = master -} - -decoration { - rounding = 10 - - blur { - enabled = true - size = 3 - passes = 1 - } - - drop_shadow = yes - shadow_range = 4 - shadow_render_power = 3 - col.shadow = rgba(1a1a1aee) -} - -animations { - enabled = yes - - bezier = myBezier, 0.05, 0.9, 0.1, 1.05 - - animation = windows, 1, 4, myBezier - animation = windowsOut, 1, 4, default, popin 80% - animation = fade, 1, 4, default - animation = workspaces, 1, 4, default -} - -master { - new_is_master = false -} - -gestures { - workspace_swipe = true -} - -bind = SUPER SHIFT, RETURN, exec, alacritty -bind = SUPER SHIFT, Q, killactive -bind = SUPER SHIFT, B, exit -bind = SUPER, E, exec, dolphin -bind = SUPER SHIFT, F, togglefloating -bind = SUPER, F, fullscreen, 1 -bind = SUPER, SPACE, exec, pkill fuzzel || fuzzel -bind = SUPER, X, exec, swaylock - -bind = SUPER, RETURN, layoutmsg, swapwithmaster master -bind = SUPER SHIFT, J, layoutmsg, swapnext -bind = SUPER SHIFT, K, layoutmsg, swapprev - -# Move focus with mainMod + hjkl -bind = SUPER, L, movefocus, r -bind = SUPER, H, movefocus, l -bind = SUPER, K, movefocus, u -bind = SUPER, J, movefocus, d - -# Switch workspaces with mainMod + [0-9] -bind = SUPER, 1, workspace, 1 -bind = SUPER, 2, workspace, 2 -bind = SUPER, 3, workspace, 3 -bind = SUPER, 4, workspace, 4 -bind = SUPER, 5, workspace, 5 -bind = SUPER, 6, workspace, 6 -bind = SUPER, 7, workspace, 7 -bind = SUPER, 8, workspace, 8 -bind = SUPER, 9, workspace, 9 -bind = SUPER, 0, workspace, 10 - -# Move active window to a workspace with mainMod + SHIFT + [0-9] -bind = SUPER SHIFT, 1, movetoworkspace, 1 -bind = SUPER SHIFT, 2, movetoworkspace, 2 -bind = SUPER SHIFT, 3, movetoworkspace, 3 -bind = SUPER SHIFT, 4, movetoworkspace, 4 -bind = SUPER SHIFT, 5, movetoworkspace, 5 -bind = SUPER SHIFT, 6, movetoworkspace, 6 -bind = SUPER SHIFT, 7, movetoworkspace, 7 -bind = SUPER SHIFT, 8, movetoworkspace, 8 -bind = SUPER SHIFT, 9, movetoworkspace, 9 -bind = SUPER SHIFT, 0, movetoworkspace, 10 - -# Move/resize windows with mainMod + LMB/RMB and dragging -bindm = SUPER, mouse:272, movewindow -bindm = SUPER, mouse:273, resizewindow diff --git a/config/hypr/hyprpaper.conf b/config/hypr/hyprpaper.conf deleted file mode 100644 index 8204052..0000000 --- a/config/hypr/hyprpaper.conf +++ /dev/null @@ -1,3 +0,0 @@ -preload = /home/compromyse/Pictures/wallpaper.jpg -wallpaper = ,/home/compromyse/Pictures/wallpaper.jpg -splash = false diff --git a/config/nvim/default.nix b/config/nvim/default.nix new file mode 100644 index 0000000..28b879b --- /dev/null +++ b/config/nvim/default.nix @@ -0,0 +1,17 @@ +{ pkgs, config, ... }: + +{ + programs.neovim = { + enable = true; + defaultEditor = true; + viAlias = true; + vimAlias = true; + vimdiffAlias = true; + }; + + home.file.".config/nvim/init.lua".source = ./init.lua; + home.file.".config/nvim/lua" = { + source = ./lua; + recursive = true; + }; +} diff --git a/config/waybar/config b/config/waybar/config deleted file mode 100644 index 6eca628..0000000 --- a/config/waybar/config +++ /dev/null @@ -1,58 +0,0 @@ -{ - "layer": "top", - "height": 40, - "modules-left": ["custom/launcher", "hyprland/workspaces", "hyprland/window"], - "modules-right": ["tray", "cpu", "backlight", "battery", "clock"], - - // Modules configuration - "custom/launcher": { - "format": "<span font='24'></span>" - }, - "hyprland/workspaces": { - "disable-scroll": true, - "on-click": "activate", - "persistent-workspaces": { - "*": [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] - }, - "format": "{icon}", - "format-icons": { - "urgent": "", - "active": "", - "empty": "", - "default": "", - "visible": "", - "sort-by-number": true - } - }, - "hyprland/window": { - "format": "> {title}", - "separate-outputs": true - }, - "tray": { - "spacing": 10 - }, - "clock": { - "timezone": "Asia/Kolkata", - "format": " {:%a, %Y-%m-%d %H:%M}", - }, - "cpu": { - "format": " {usage}%", - "tooltip": false - }, - "backlight": { - "format": "{icon} {percent}%", - "format-icons": ["", "", "", "", "", "", "", "", ""] - }, - "battery": { - "bat": "BAT1", - "states": { - "warning": 30, - "critical": 15 - }, - "format": "{icon} {capacity}%", - "format-charging": " {capacity}%+", - "format-plugged": " {capacity}%", - "format-icons": ["", "", "", "", ""] - } -} - diff --git a/config/waybar/style.css b/config/waybar/style.css deleted file mode 100644 index 139b7cd..0000000 --- a/config/waybar/style.css +++ /dev/null @@ -1,99 +0,0 @@ -* { - font-family: UbuntuMono Nerd Font Mono; - font-weight: 500; - font-size: 16px; -} - -window#waybar { - background-color: rgba(27, 27, 27, 1); - color: #f2f0fa; - transition-property: background-color; - transition-duration: .5s; -} - -button { - box-shadow: inset 0 -3px transparent; - border: none; - border-radius: 0px; -} - -button:hover { - background: inherit; -} - -#custom-launcher { - margin: 0 10px; - padding: 0 10px; -} - -#workspaces { - border-radius: 10px; - background-color: #f2f0fa; - color: #272727; - padding: 0 10px; - margin: 0px 4px; -} - -#workspaces button { - padding: 0 10px; - color: #272727; - background-color: #f2f0fa; -} - -#clock { - padding: 0 10px; - margin: 0 10px; - color: #f2f0fa; - border-radius: 0px; -} - -#battery, -#cpu, -#backlight { - padding: 0 10px; - margin: 0 0px; - background-color: #f2f0fa; - color: #272727; -} - -#battery { - border-radius: 0px 10px 10px 0px; -} - -#cpu { - border-radius: 10px 0px 0px 10px; -} - -#tray { - padding: 0 10px; - margin: 0 0px; - border-radius: 10px; - margin: 0 10px; -} - -#window { - margin: 0 4px; -} - -/* If workspaces is the leftmost module, omit left margin */ -.modules-left > widget:first-child > #workspaces { - margin-left: 0; -} - -#battery.critical:not(.charging) { - background-color: #f53c3c; - color: #ffffff; -} - -label:focus { - background-color: #000000; -} - -#tray > .passive { - -gtk-icon-effect: dim; -} - -#tray > .needs-attention { - -gtk-icon-effect: highlight; - background-color: #eb4d4b; -} |
