~metalune/Dotfiles

a92ca40a45b825491b8c281709f382f71799ab31 — metalune 7 days ago c31b6c8
Update
M .config/dunst/dunstrc => .config/dunst/dunstrc +9 -9
@@ 19,15 19,15 @@
    separator_height = 2
    padding = 8
    horizontal_padding = 8
    separator_color = "#585858"
    separator_color = "#073642"
    startup_notification = false
    # https://github.com/knopwob/dunst/issues/26#issuecomment-36159395
    #icon_position = left
    #icon_folders = /usr/share/icons/elementary/actions/16/

[frame]
    width = 1
    color = "#83a598"
    width = 2
    color = "#268bd2"

[shortcuts]
    close = ctrl+space


@@ 36,16 36,16 @@
    context = ctrl+shift+period

[urgency_low]
    background = "#282828"
    foreground = "#ebdbb2"
    background = "#002b36"
    foreground = "#586e75"
    timeout = 5

[urgency_normal]
    background = "#282828"
    foreground = "#ebdbb2"
    background = "#002b36"
    foreground = "#fdf6e3"
    timeout = 20

[urgency_critical]
    background = "#282828"
    foreground = "#ebdbb2"
    background = "#002b36"
    foreground = "#dc322f"
    timeout = 0

M .config/fontconfig/fonts.conf => .config/fontconfig/fonts.conf +12 -6
@@ 1,7 1,9 @@
<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
    <alias> <family>serif</family> <prefer>
    <alias>
        <family>serif</family>
        <prefer>
            <family>Ubuntu</family>
            <family>Linux Libertine</family>
            <family>Joy Pixels</family>


@@ 9,7 11,8 @@
        </prefer>
    </alias>
    <alias>
        <family>sans-serif</family> <prefer>
        <family>sans-serif</family>
        <prefer>
            <family>Ubuntu</family>
            <family>Cantarell</family>
            <family>Linux Biolinum</family>


@@ 31,10 34,15 @@
        <family>monospace</family>
        <prefer>
            <!-- Use Semibold variant of SF Mono -->
            <family>FantasqueSansMono Nerd Font</family>
            <family>TerminessTTF Nerd Font</family>
            <family>Misc Tamsyn</family>
            <family>Hack Nerd Font</family>
            <family>SauceCodePro Nerd Font</family>
            <family>UbuntuMono Nerd Font</family>
            <family>Iosevka Nerd Font</family>
            <family>SpaceMono Nerd Font</family>
            <family>DejaVu Sans Mono</family>
            <family>FantasqueSansMono Nerd Font</family>
            <family>Iosevka Nerd Font</family>
            <family>CodeNewRoman Nerd Font</family>
            <family>LiterationMono Nerd Font</family>
            <family>BlexMono Nerd Font</family>


@@ 48,8 56,6 @@
            <family>JetBrainsMono Nerd Font</family>
            <family>GoMono Nerd Font</family>
            <family>Noto Sans Mono</family>
            <family>SauceCodePro Nerd Font</family>
            <family>Misc Tamsyn</family>
        </prefer>
    </alias>
</fontconfig>

M .config/qutebrowser/config.py => .config/qutebrowser/config.py +5 -0
@@ 8,9 8,12 @@ c.content.fullscreen.window = True
c.content.notifications = False
c.content.blocking.method = "both"
c.content.cookies.accept = "no-3rdparty"
c.scrolling.smooth = True


config.bind("<Ctrl-m>", "hint links spawn mpv {hint-url}")
config.bind("ys", "yank selection")
config.bind("yf", "hint links yank")

c.tabs.show = "multiple"
c.tabs.background = True


@@ 23,6 26,8 @@ c.tabs.width = 49
c.tabs.indicator.width = 0
c.tabs.padding = {"top": 2, "right": 2, "bottom": 2, "left": 5}

c.colors.webpage.preferred_color_scheme = "dark"


# disable history
c.completion.cmd_history_max_items = 0

M .config/sway/config => .config/sway/config +40 -23
@@ 43,8 43,7 @@ bar {
    }
}



# dunno why this works, but it does, nice!
seat seat0 hide_cursor 5000

focus_on_window_activation urgent


@@ 61,12 60,30 @@ input * {



output "*" bg ~/wallpapers/solarized/0008.png fill
output "*" bg ~/wallpapers/solarized/0010.jpg fill

set $ws1 "01 "
set $ws2 "02 "
set $ws3 "03 "
set $ws4 "04 "
set $ws5 "05 "
set $ws6 "06 "
set $ws7 "07 "
set $ws8 "08 "
set $ws9 "09 "
set $wsX "10 "


####################
### Key Bindings ###
####################

## MULTIMEDIA
bindsym $mod+F5 exec cmus-remote --prev
bindsym $mod+F6 exec cmus-remote --pause
bindsym $mod+F7 exec cmus-remote --next
## MULTIMEDIA

# Start a terminal
bindsym $mod+Return exec $term



@@ 128,27 145,27 @@ bindsym $mod+Ctrl+p reload

## Workspaces
# Switch to workspace
    bindsym $mod+ampersand workspace number 1
    bindsym $mod+bracketleft workspace number 2
    bindsym $mod+braceleft workspace number 3
    bindsym $mod+braceright workspace number 4
    bindsym $mod+parenleft workspace number 5
    bindsym $mod+equal workspace number 6
    bindsym $mod+asterisk workspace number 7
    bindsym $mod+parenright workspace number 8
    bindsym $mod+plus workspace number 9
    bindsym $mod+bracketright workspace number 10
    bindsym $mod+ampersand    workspace $ws1 
    bindsym $mod+bracketleft  workspace $ws2
    bindsym $mod+braceleft    workspace $ws3
    bindsym $mod+braceright   workspace $ws4
    bindsym $mod+parenleft    workspace $ws5
    bindsym $mod+equal        workspace $ws6
    bindsym $mod+asterisk     workspace $ws7
    bindsym $mod+parenright   workspace $ws8
    bindsym $mod+plus         workspace $ws9
    bindsym $mod+bracketright workspace $ws10
# Move focused container to workspace
    bindsym $mod+percent move container to workspace number 1
    bindsym $mod+7 move container to workspace number 2
    bindsym $mod+5 move container to workspace number 3
    bindsym $mod+3 move container to workspace number 4
    bindsym $mod+1 move container to workspace number 5
    bindsym $mod+9 move container to workspace number 6
    bindsym $mod+0 move container to workspace number 7
    bindsym $mod+2 move container to workspace number 8
    bindsym $mod+4 move container to workspace number 9
    bindsym $mod+6 move container to workspace number 10
    bindsym $mod+percent move container to workspace $ws1
    bindsym $mod+7       move container to workspace $ws2
    bindsym $mod+5       move container to workspace $ws3
    bindsym $mod+3       move container to workspace $ws4
    bindsym $mod+1       move container to workspace $ws5
    bindsym $mod+9       move container to workspace $ws6
    bindsym $mod+0       move container to workspace $ws7
    bindsym $mod+2       move container to workspace $ws8
    bindsym $mod+4       move container to workspace $ws9
    bindsym $mod+6       move container to workspace $wsd10


## Layout

M .local/bin/dmconf => .local/bin/dmconf +1 -0
@@ 37,6 37,7 @@ else
	options[qutebrowser bookmarks]="$HOME/.config/qutebrowser/bookmarks/urls"
	options[qutebrowser quickmarks]="$HOME/.config/qutebrowser/quickmarks"
	options[qutebrowser config.py]="$HOME/.config/qutebrowser/config.py"
    options[profanity]="$HOME/.config/profanity/profrc"
    options[tg]="$HOME/.config/tg/conf.py"
	options[ssh]="$HOME/.ssh/config"
	options[sway]="$HOME/.config/sway/config"

A .local/bin/dmsounds => .local/bin/dmsounds +67 -0
@@ 0,0 1,67 @@
#!/usr/bin/env bash
#
# Script name: dmsounds
# Description: Choose a ambient background sound to play
# Dependencies: dmenu, ffmpeg
# GitLab: https://www.gitlab.com/dwt1/dmscripts
# License: https://www.gitlab.com/dwt1/dmscripts/LICENSE
# Contributors: Derek Taylor
#
# Need some ambient sound files?  Here are is a collection
# of 15 free to use sounds for personal or commercial projects:
# http://pbblogassets.s3.amazonaws.com/uploads/2016/09/15-Free-Ambient-Sound-Effects.zip

# Set with the flags "-e", "-u","-o pipefail" cause the script to fail
# if certain things happen, which is a good thing.  Otherwise, we can
# get hidden bugs that are hard to discover.
set -euo pipefail

# The directory where the sound files are located.
soundDir=$HOME/.config/dmsounds

# Produces a listing of the sound files.
soundFiles=$(/bin/ls -1 "$soundDir" | grep -E ".mp3|.m4a|.ogg")

# An array of options to choose.
declare -a options=(
  "Choose sound file"
  "Play random sound"
  "Stop sound player"
  "Quit"
)

# An array of sound files to choose.
declare -a soundList=$soundFiles

# Piping the options array into dmenu.
# We use "printf '%s\n'" to format the array one item to a line.
choice=$(printf '%s\n' "${options[@]}" | dmenu -i -p 'Ambient sounds:' "${@}")

if [ "$choice" == "Choose sound file" ]; then
  # Piping the soundList array into dmenu.
  # We use "printf '%s\n'" to format the array one item to a line.
  choice=$(printf '%s\n' "${soundList[@]}" | sort | dmenu -i -l 20 -p 'Choose sound file:' "$@")
  # Kill PID saved in cache file.
  kill "$(cat "$HOME/.cache/dmsounds")" || echo "ffplay was not running."
  # Play the chosen sound file.
  ffplay -nodisp -loop 0 "$soundDir/$choice" &
  # Get PID for the above command and write to cache.
  _pid=$!
  echo "$_pid" > "$HOME/.cache/dmsounds"

elif [ "$choice" == "Play random sound" ]; then
  getRand=$(printf '%s\n' "${soundList[@]}" | shuf -n 1)
  # Kill PID saved in cache file.
  kill "$(cat "$HOME/.cache/dmsounds")" || echo "ffplay was not running."
  # Play random sound file.
  ffplay -nodisp -loop 0 "$soundDir/$getRand" &
  # Get PID for the above command and write to cache.
  _pid=$!
  echo "$_pid" > "$HOME/.cache/dmsounds"

elif [ "$choice" == "Stop sound player" ]; then
  kill "$(cat "$HOME/.cache/dmsounds")" || echo "ffplay was not running."

else
  echo "Program terminated." && exit 0
fi