From 6fe7f71b97465640eb6f54ef39f6205c0456c2de Mon Sep 17 00:00:00 2001 From: Aleksander Cynarski Date: Sun, 26 Jan 2020 13:06:06 +0100 Subject: [PATCH] rofi, dunst configuration --- .config/dunst/dunstrc | 151 +++++++++ .config/i3/config | 15 +- .config/polybar/backup/config | 314 ------------------ .config/polybar/backup/launch.sh | 5 - .../openweathermap-detailed.sh | 2 +- .config/rofi/config | 11 - .config/rofi/config.rasi | 10 + .config/rofi/scripts/appsmenu.sh | 4 + .config/rofi/scripts/powermenu.sh | 19 ++ .config/rofi/themes/app-launcher.rasi | 149 +++++++++ .config/rofi/themes/system-menu.rasi | 19 ++ 11 files changed, 366 insertions(+), 333 deletions(-) create mode 100644 .config/dunst/dunstrc delete mode 100644 .config/polybar/backup/config delete mode 100755 .config/polybar/backup/launch.sh delete mode 100644 .config/rofi/config create mode 100644 .config/rofi/config.rasi create mode 100755 .config/rofi/scripts/appsmenu.sh create mode 100755 .config/rofi/scripts/powermenu.sh create mode 100644 .config/rofi/themes/app-launcher.rasi create mode 100644 .config/rofi/themes/system-menu.rasi diff --git a/.config/dunst/dunstrc b/.config/dunst/dunstrc new file mode 100644 index 0000000..dae001e --- /dev/null +++ b/.config/dunst/dunstrc @@ -0,0 +1,151 @@ +[global] + monitor = 0 + follow = keyboard + geometry = "300x50-20+48" + indicate_hidden = yes + shrink = yes + transparency = 20 + notification_height = 0 + separator_height = 2 + padding = 8 + horizontal_padding = 8 + frame_width = 1 + frame_color = "#355E86" + + # Define a color for the separator. + # possible values are: + # * auto: dunst tries to find a color fitting to the background; + # * foreground: use the same color as the foreground; + # * frame: use the same color as the frame; + # * anything else will be interpreted as a X color. + separator_color = frame + + # Sort messages by urgency. + sort = yes + + idle_threshold = 120 + font = RobotoMono 10 + line_height = 0 + markup = full + + # The format of the message. Possible variables are: + # %a appname + # %s summary + # %b body + # %i iconname (including its path) + # %I iconname (without its path) + # %p progress value if set ([ 0%] to [100%]) or nothing + # %n progress value if set without any extra characters + # %% Literal % + # Markup is allowed + format = "%s\n%b" + + alignment = left + show_age_threshold = 60 + word_wrap = yes + ellipsize = middle + ignore_newline = no + stack_duplicates = true + hide_duplicate_count = true + show_indicators = yes + icon_position = left + max_icon_size = 40 + #icon_path = /usr/share/icons/gnome/16x16/status/:/usr/share/icons/gnome/16x16/devices/:/usr/share/icons/Adwaita/256x256/status/ + sticky_history = yes + history_length = 20 + dmenu = /usr/bin/dmenu -p dunst: + browser = /usr/bin/firefox -new-tab + + # Always run rule-defined scripts, even if the notification is suppressed + always_run_script = true + + title = Dunst + class = Dunst + startup_notification = false + force_xinerama = false +[experimental] + per_monitor_dpi = false + +[shortcuts] + close = ctrl+space + close_all = ctrl+shift+space + history = ctrl+grave + context = ctrl+shift+period + +[urgency_low] + # IMPORTANT: colors have to be defined in quotation marks. + # Otherwise the "#" and following would be interpreted as a comment. + background = "#0D0F12" + foreground = "#355E86" + timeout = 5 + # Icon for notifications with low urgency, uncomment to enable + #icon = /path/to/icon + +[urgency_normal] + background = "#0D0F12" + foreground = "#355E86" + timeout = 5 + +[urgency_critical] + background = "#0D0F12" + foreground = "#355E86" + frame_color = "#355E86" + timeout = 0 + +# Every section that isn't one of the above is interpreted as a rules to +# override settings for certain messages. +# Messages can be matched by "appname", "summary", "body", "icon", "category", +# "msg_urgency" and you can override the "timeout", "urgency", "foreground", +# "background", "new_icon" and "format". +# Shell-like globbing will get expanded. +# +# SCRIPTING +# You can specify a script that gets run when the rule matches by +# setting the "script" option. +# The script will be called as follows: +# script appname summary body icon urgency +# where urgency can be "LOW", "NORMAL" or "CRITICAL". +# +# NOTE: if you don't want a notification to be displayed, set the format +# to "". +# NOTE: It might be helpful to run dunst -print in a terminal in order +# to find fitting options for rules. + +#[espeak] +# summary = "*" +# script = dunst_espeak.sh + +#[script-test] +# summary = "*script*" +# script = dunst_test.sh + +#[ignore] +# # This notification will not be displayed +# summary = "foobar" +# format = "" + +#[history-ignore] +# # This notification will not be saved in history +# summary = "foobar" +# history_ignore = yes + +#[signed_on] +# appname = Pidgin +# summary = "*signed on*" +# urgency = low +# +#[signed_off] +# appname = Pidgin +# summary = *signed off* +# urgency = low +# +#[says] +# appname = Pidgin +# summary = *says* +# urgency = critical +# +#[twitter] +# appname = Pidgin +# summary = *twitter.com* +# urgency = normal +# diff --git a/.config/i3/config b/.config/i3/config index 7355f0d..c836c71 100644 --- a/.config/i3/config +++ b/.config/i3/config @@ -19,8 +19,8 @@ bindsym $mod+Shift+Return exec "$TERMINAL --role=floating &" bindsym $mod+Shift+q kill # start dmenu (a program launcher) -bindsym $mod+d exec --no-startup-id rofi -show drun -bindsym $mod+i exec --no-startup-id rofi -show window +bindsym $mod+d exec --no-startup-id rofi -show drun -theme themes/app-launcher +bindsym $mod+i exec --no-startup-id rofi -show window # move focused window bindsym $mod+j move left @@ -140,11 +140,18 @@ exec --no-startup-id i3-msg 'exec $TERMINAL; workspace 2; exec firefox;' exec --no-startup-id feh --bg-scale ~/Wallpapers/seneca.jpg exec --no-startup-id xrandr --output HDMI1 --right-of eDP1 +exec --no-startup-id xset dpms 500 +exec --no-startup-id xautolock -time 10 -locker "betterlockscreen -l dim" +exec --no-startup-id ~/bin/dunstwal +exec --no-startup-id /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 + exec telegram-desktop # exec cantata exec --no-startup-id sleep 4; i3-msg '[class="Mattermost"] move scratchpad; [class="Telegram"] move scratchpad' +exec_always --no-startup-id wal -R -n + # gaps gaps inner 10 @@ -171,6 +178,10 @@ bindsym $mod+Print exec "owo -s --fullscreen --no-cursor" bindsym $mod+minus [class="Telegram"] scratchpad show bindsym $mod+p [class="Mattermost"] scratchpad show +bindsym $mod+Delete exec rofi -modi system:$HOME/.config/rofi/scripts/powermenu.sh -show system -theme themes/system-menu +bindsym $mod+d exec rofi -modi system:$HOME/.config/rofi/scripts/appsmenu.sh +bindsym $mod+shift+Delete exec betterlockscreen -l + # audio binds bindsym XF86AudioMicMute exec --no-startup-id pulseaudio-ctl mute-input diff --git a/.config/polybar/backup/config b/.config/polybar/backup/config deleted file mode 100644 index bbed047..0000000 --- a/.config/polybar/backup/config +++ /dev/null @@ -1,314 +0,0 @@ -[colors] -background = #aa222222 -#background-alt = #aa444444 -foreground = #dfdfdf -foreground-alt = #555555 -primary = #7596ff -secondary = #e60053 -alert = #bd2c40 - -[settings] -screenchange-reload = false -format-background = ${colors.background} -format-foreground = ${colors.foreground} - -[bar/mybar] -monitor = -fixed-center = true -width = 100% - -background = ${colors.background} -foreground = ${colors.foreground} - -height = 35 -line-size = 1 - -padding = 2.5 -module-margin = 2.5 - -font-0 = IBM Plex Sans Bold:size=8;0 -font-1 = FontAwesome5Free:style=Solid:pixelsize=8;0 -font-2 = FontAwesome5Brands:style=Solid:pixelsize=8;0 - -modules-left = i3 bspwm xwindow -modules-center = date -modules-right = my-apps backlight updates-arch-combined mpd pulseaudio wlan filesystem memory cpu battery temperature - -tray-position = right -tray-padding = 0 - -cursor-click = pointer - - -[module/my-apps] -type = custom/menu - -; If true, will be to the left of the menu items (default). -; If false, it will be on the right of all the items. -expand-right = false - -; "menu-LEVEL-N" has the same properties as "label-NAME" with -; the additional "exec" property -; -; Available exec commands: -; menu-open-LEVEL -; menu-close -; Other commands will be executed using "/usr/bin/env sh -c $COMMAND" - -menu-0-0 = Browsers -menu-0-0-exec = menu-open-1 - -menu-1-0 = Firefox -menu-1-0-exec = firefox & -menu-1-1 = Chromium -menu-1-1-exec = chromium & - - -[module/i3] -type = internal/i3 -format = -wrapping-scroll = false - -label-mode-padding = 2 -label-mode-foreground = #000 -label-mode-background = ${colors.primary} - -; focused = Active workspace on focused monitor -label-focused = %icon% -label-focused-background = ${colors.background-alt} -label-focused-overline = ${colors.primary} -label-focused-padding = 2 - -; unfocused = Inactive workspace on any monitor -label-unfocused = %icon% -label-unfocused-padding = 2 - -; visible = Active workspace on unfocused monitor -label-visible = %icon% -label-visible-background = ${self.label-focused-background} -label-visible-overline = ${self.label-focused-overline} -label-visible-padding = ${self.label-focused-padding} - -; urgent = Workspace with urgency hint set -label-urgent = %icon% -label-urgent-background = ${colors.alert} -label-urgent-padding = 2 - -ws-icon-0 = 1; -ws-icon-1 = 2; -ws-icon-2 = 3; -ws-icon-3 = 4;4 -ws-icon-4 = 5;5 -ws-icon-5 = 6;6 -ws-icon-6 = 7;7 -ws-icon-7 = 8;8 -ws-icon-8 = 9;9 -ws-icon-9 = 10;10 - -[module/bspwm] -type = internal/bspwm -format = -wrapping-scroll = false -fuzzy-match = true - -ws-icon-0 = term; -ws-icon-1 = web; -ws-icon-2 = chat; -ws-icon-3 = irc; - -label-mode-padding = 2 -label-mode-foreground = #000 -label-mode-background = ${colors.primary} - -; focused = Active workspace on focused monitor -label-focused = %index% -label-focused-background = ${colors.background-alt} -label-focused-overline = ${colors.primary} -label-focused-padding = 2 - -; unfocused = Inactive workspace on any monitor -label-unfocused = %index% -label-unfocused-padding = 2 - -; visible = Active workspace on unfocused monitor -label-visible = %index% -label-visible-background = ${self.label-focused-background} -label-visible-overline = ${self.label-focused-overline} -label-visible-padding = ${self.label-focused-padding} - -; urgent = Workspace with urgency hint set -label-urgent = %index% -label-urgent-background = ${colors.alert} -label-urgent-padding = 2 - -[module/xwindow] -type = internal/xwindow -label = %title% -label-maxlen = 100 - -[module/filesystem] -type = internal/fs -mount-0 = / -interval = 30 - -label-mounted = %{F#0a81f5}%mountpoint%%{F-}: %percentage_used%% -label-unmounted-foreground = ${colors.foreground-alt} - -[module/memory] -type = internal/memory -interval = 1 - -format-prefix = " " -format-prefix-foreground = ${colors.foreground-alt} - -label = "RAM: %percentage_used%%" - -[module/backlight] -type = internal/xbacklight - -; XRandR output to get get values from -; Default: the monitor defined for the running bar -output = eDP1 - -; Create scroll handlers used to set the backlight value -; Default: true -enable-scroll = false - -[module/cpu] -type = internal/cpu -interval = 2 - -format-prefix = " " -format-prefix-foreground = ${colors.foreground-alt} - -label = "CPU:%percentage:2%%" - -[module/mpd] -type = internal/mpd -format-online = - -icon-prev =  -icon-stop =  -icon-play =  -icon-pause =  -icon-next =  - -label-song-maxlen = 100 -label-song-ellipsis = true - - -[module/wlan] -type = internal/network -interface = wlp2s0 -interval = 3.0 - -format-prefix = " " -format-connected = -label-connected = "%signal%% %essid%" - -format-disconnected = -;format-disconnected = -;format-disconnected-overline = ${self.format-connected-overline} -;label-disconnected = %ifname% disconnected -;label-disconnected-foreground = ${colors.foreground-alt} - -[module/pulseaudio] -type = internal/pulseaudio - -format-muted-prefix = " " -format-muted-prefix-foreground = ${colors.foreground-alt} - -format-volume-prefix = " " -format-volume-prefix-foregroud = ${colors.foreground-alt} - -format-volume = -label-volume = VOL %percentage%% -label-volume-foreground = ${root.foreground} - -label-muted = muted -label-muted-foreground = #666 - -bar-volume-width = 8 -bar-volume-foreground-0 = #55aa55 -bar-volume-foreground-1 = #55aa55 -bar-volume-foreground-2 = #55aa55 -bar-volume-foreground-3 = #55aa55 -bar-volume-foreground-4 = #55aa55 -bar-volume-foreground-5 = #f5a70a -bar-volume-foreground-6 = #ff5555 -bar-volume-gradient = false -bar-volume-indicator = | -bar-volume-indicator-font = 2 -bar-volume-fill = - -bar-volume-fill-font = 2 -bar-volume-empty = - -bar-volume-empty-font = 2 -bar-volume-empty-foreground = ${colors.foreground-alt} -format-overline = ${colors.primary} - -[module/battery] -type = internal/battery -battery = BAT0 -adapter = AC -full-at = 99 - -format-charging-prefix = " " -format-charging-prefix-foreground = ${colors.foreground-alt} -format-charging = - -label-charging = "BAT: %percentage%%" - -format-discharging-prefix = " " -format-discharging-prefix-foreground = ${colors.foreground-alt} -format-discharging = - -label-discharging = "BAT: %percentage%%" - -format-full-prefix = " " -format-full-prefix-foreground = ${colors.foreground-alt} - -[module/temperature] -type = internal/temperature -thermal-zone = 0 -warn-temperature = 60 - -format =