- Replace home directory paths with $HOME env var - Add sleeps to winitrc so it waits for dwl to start
9970 lines
280 KiB
Org Mode
9970 lines
280 KiB
Org Mode
#+TITLE: Personal Dotfiles
|
||
#+AUTHOR: Sravan Balaji
|
||
#+AUTO_TANGLE: t
|
||
#+STARTUP: showeverything
|
||
|
||
* Table of Contents :TOC_3:noexport:
|
||
- [[#installation][Installation]]
|
||
- [[#dotfiles-configuration][Dotfiles Configuration]]
|
||
- [[#git-submodules][Git Submodules]]
|
||
- [[#ignoring-files-and-directories][Ignoring files and directories]]
|
||
- [[#gnu-stow-ignore][GNU Stow Ignore]]
|
||
- [[#git-ignore][Git Ignore]]
|
||
- [[#git][Git]]
|
||
- [[#gitconfig][Gitconfig]]
|
||
- [[#notifications][Notifications]]
|
||
- [[#dunst-notification-daemon][Dunst Notification Daemon]]
|
||
- [[#configuration][Configuration]]
|
||
- [[#control-script][Control Script]]
|
||
- [[#deadd-notification-center][Deadd Notification Center]]
|
||
- [[#configuration-1][Configuration]]
|
||
- [[#styling][Styling]]
|
||
- [[#control-script-1][Control Script]]
|
||
- [[#awesomewm-naughty][AwesomeWM Naughty]]
|
||
- [[#swaynotificationcenter][SwayNotificationCenter]]
|
||
- [[#config][Config]]
|
||
- [[#style][Style]]
|
||
- [[#xfce4-notifyd][xfce4-notifyd]]
|
||
- [[#control-script-2][Control Script]]
|
||
- [[#application-launcher][Application Launcher]]
|
||
- [[#rofi][Rofi]]
|
||
- [[#configuration-2][Configuration]]
|
||
- [[#themes][Themes]]
|
||
- [[#greenclip-clipboard-manager][Greenclip Clipboard Manager]]
|
||
- [[#fuzzel][Fuzzel]]
|
||
- [[#main][Main]]
|
||
- [[#colors][Colors]]
|
||
- [[#border][Border]]
|
||
- [[#dmenu][dmenu]]
|
||
- [[#key-bindings][Key Bindings]]
|
||
- [[#display-configuration--effects][Display Configuration & Effects]]
|
||
- [[#x11-monitor-setup][X11 Monitor Setup]]
|
||
- [[#xrandr][Xrandr]]
|
||
- [[#autorandr][Autorandr]]
|
||
- [[#compositor][Compositor]]
|
||
- [[#night-light][Night Light]]
|
||
- [[#lock-screen][Lock Screen]]
|
||
- [[#wayland-monitor-setup][Wayland Monitor Setup]]
|
||
- [[#shikane][Shikane]]
|
||
- [[#lock-screen-1][Lock Screen]]
|
||
- [[#command-line-interface][Command Line Interface]]
|
||
- [[#multiplexer][Multiplexer]]
|
||
- [[#tmux][Tmux]]
|
||
- [[#prompt][Prompt]]
|
||
- [[#starship][Starship]]
|
||
- [[#shell][Shell]]
|
||
- [[#bash][Bash]]
|
||
- [[#zsh][Zsh]]
|
||
- [[#fish][Fish]]
|
||
- [[#terminal][Terminal]]
|
||
- [[#kitty][Kitty]]
|
||
- [[#alacritty][Alacritty]]
|
||
- [[#text-editor][Text Editor]]
|
||
- [[#vim][Vim]]
|
||
- [[#emacs][Emacs]]
|
||
- [[#chemacs2][Chemacs2]]
|
||
- [[#vs-code][VS Code]]
|
||
- [[#settings][Settings]]
|
||
- [[#keybindings][Keybindings]]
|
||
- [[#gaming][Gaming]]
|
||
- [[#scripts][Scripts]]
|
||
- [[#pre-launch-script][Pre-Launch Script]]
|
||
- [[#post-exit-script][Post-Exit Script]]
|
||
- [[#playstation-5-dualsense-to-xbox-360-controller-button-mapping][PlayStation 5 (DualSense) to Xbox 360 Controller Button Mapping]]
|
||
- [[#gamemode][Gamemode]]
|
||
- [[#general][General]]
|
||
- [[#filter][Filter]]
|
||
- [[#gpu][GPU]]
|
||
- [[#cpu][CPU]]
|
||
- [[#supervisor][Supervisor]]
|
||
- [[#custom][Custom]]
|
||
- [[#media][Media]]
|
||
- [[#mpv][mpv]]
|
||
- [[#general-settings][General Settings]]
|
||
- [[#key-bindings-1][Key Bindings]]
|
||
- [[#backups--syncing][Backups & Syncing]]
|
||
- [[#backups][Backups]]
|
||
- [[#rsync-options][Rsync Options]]
|
||
- [[#hdd][HDD]]
|
||
- [[#fileserver][Fileserver]]
|
||
- [[#rofi-menu][Rofi Menu]]
|
||
- [[#syncthing][Syncthing]]
|
||
- [[#hotkey-daemon][Hotkey Daemon]]
|
||
- [[#swhkd][swhkd]]
|
||
- [[#user-programs][User Programs]]
|
||
- [[#mangal][Mangal]]
|
||
- [[#trackma][Trackma]]
|
||
- [[#config-1][Config]]
|
||
- [[#gtk][Gtk]]
|
||
- [[#qt][Qt]]
|
||
- [[#swappy][Swappy]]
|
||
- [[#ssh][SSH]]
|
||
- [[#config-2][Config]]
|
||
- [[#system-settings][System Settings]]
|
||
- [[#x11][X11]]
|
||
- [[#xinit][Xinit]]
|
||
- [[#xresources][Xresources]]
|
||
- [[#x11-startup][X11 Startup]]
|
||
- [[#wayland][Wayland]]
|
||
- [[#winit][Winit]]
|
||
- [[#wayland-startup][Wayland Startup]]
|
||
- [[#justfile][Justfile]]
|
||
- [[#miscellaneous-scripts][Miscellaneous Scripts]]
|
||
- [[#media-control][Media Control]]
|
||
- [[#volume-control][Volume Control]]
|
||
- [[#brightness-control][Brightness Control]]
|
||
- [[#trackpad-control][Trackpad Control]]
|
||
- [[#cpu--gpu-control][CPU & GPU Control]]
|
||
- [[#gaming-control][Gaming Control]]
|
||
- [[#session-control][Session Control]]
|
||
- [[#control-center][Control Center]]
|
||
- [[#acknowledgements][Acknowledgements]]
|
||
|
||
* Installation
|
||
|
||
See [[#acknowledgements][Acknowledgements]] for tutorial source.
|
||
|
||
Clone dotfiles into a ~.dotfiles~ folder in home directory.
|
||
|
||
#+BEGIN_SRC shell
|
||
git clone <git-repo-url> $HOME/.dotfiles
|
||
#+END_SRC
|
||
|
||
Pull and update submodules.
|
||
|
||
#+BEGIN_SRC shell
|
||
git submodule update --init --recursive --remote
|
||
#+END_SRC
|
||
|
||
Use [[https://www.gnu.org/software/stow/][GNU Stow]] to create symlinks.
|
||
|
||
* Dotfiles Configuration
|
||
|
||
** Git Submodules
|
||
|
||
#+BEGIN_SRC gitconfig :tangle .gitmodules
|
||
[submodule "dracula-vim-theme"]
|
||
path = vim/.vim/pack/themes/start/dracula
|
||
url = git@github.com:dracula/vim.git
|
||
branch = master
|
||
[submodule "dracula-blender-theme"]
|
||
path = blender/.themes/dracula-blender
|
||
url = git@github.com:dracula/blender.git
|
||
branch = master
|
||
[submodule "dracula-freecad-theme"]
|
||
path = freecad/.themes/dracula-freecad
|
||
url = git@github.com:dracula/freecad.git
|
||
branch = master
|
||
[submodule "dracula-xournalpp-theme"]
|
||
path = xournalpp/.themes/dracula-xournalpp
|
||
url = git@github.com:dracula/xournalpp.git
|
||
branch = master
|
||
[submodule "dracula-gtk-theme"]
|
||
path = gtk/.themes/dracula-gtk
|
||
url = git@github.com:dracula/gtk.git
|
||
branch = master
|
||
[submodule "dracula-fish-theme"]
|
||
path = fish/.themes/dracula-fish
|
||
url = git@github.com:dracula/fish.git
|
||
branch = master
|
||
[submodule "dracula-kitty-theme"]
|
||
path = kitty/.themes/dracula-kitty
|
||
url = git@github.com:dracula/kitty.git
|
||
branch = master
|
||
[submodule "dracula-tty-theme"]
|
||
path = tty/.themes/dracula-tty
|
||
url = git@github.com:dracula/tty.git
|
||
branch = master
|
||
[submodule "xmonad"]
|
||
path = xmonad/.xmonad
|
||
url = ../xmonad.git
|
||
branch = master
|
||
[submodule "dwm-flexipatch"]
|
||
path = dwm/.config/dwm-flexipatch
|
||
url = ../dwm-flexipatch.git
|
||
branch = master
|
||
[submodule "chemacs"]
|
||
path = emacs/.config/emacs
|
||
url = git@github.com:plexus/chemacs2.git
|
||
branch = main
|
||
[submodule "personal-emacs"]
|
||
path = emacs/.config/personal-emacs
|
||
url = ../emacs.git
|
||
branch = main
|
||
[submodule "doom-emacs"]
|
||
path = emacs/.config/doom-emacs
|
||
url = git@github.com:hlissner/doom-emacs.git
|
||
branch = master
|
||
[submodule "doom-emacs-config"]
|
||
path = emacs/.config/doom-emacs-config
|
||
url = ../doom-emacs-config.git
|
||
branch = master
|
||
[submodule "dracula-zathura-theme"]
|
||
path = zathura/.config/zathura
|
||
url = git@github.com:dracula/zathura.git
|
||
branch = master
|
||
[submodule "dracula-gimp-theme"]
|
||
path = gimp/.themes/dracula-gimp
|
||
url = git@github.com:dracula/gimp.git
|
||
branch = master
|
||
[submodule "awesome"]
|
||
path = awesome/.config/awesome
|
||
url = ../awesome.git
|
||
branch = main
|
||
[submodule "hyprland"]
|
||
path = hyprland/.config/hypr
|
||
url = ../hyprland.git
|
||
branch = main
|
||
[submodule "dracula-qt5-theme"]
|
||
path = qt5/.themes/dracula-qt5
|
||
url = git@github.com:dracula/qt5.git
|
||
branch = master
|
||
[submodule "eww"]
|
||
path = eww/.config/eww
|
||
url = ../eww.git
|
||
[submodule "tpm"]
|
||
path = tmux/.tmux/plugins/tpm
|
||
url = git@github.com:tmux-plugins/tpm.git
|
||
branch = master
|
||
[submodule "tmux-sensible"]
|
||
path = tmux/.tmux/plugins/tmux-sensible
|
||
url = git@github.com:tmux-plugins/tmux-sensible.git
|
||
branch = master
|
||
[submodule "dracula-tmux-theme"]
|
||
path = tmux/.tmux/plugins/tmux
|
||
url = git@github.com:dracula/tmux.git
|
||
branch = master
|
||
[submodule "dwl"]
|
||
path = dwl/.config/dwl
|
||
url = ../dwl.git
|
||
branch = main
|
||
[submodule "dracula-calibre-theme"]
|
||
path = calibre/.themes/dracula-calibre
|
||
url = git@github.com:dracula/calibre.git
|
||
branch = main
|
||
#+END_SRC
|
||
|
||
** Ignoring files and directories
|
||
|
||
*** GNU Stow Ignore
|
||
|
||
Things to ignore when stowing dotfiles on system.
|
||
|
||
#+BEGIN_SRC text :tangle .stow-local-ignore
|
||
\.git
|
||
\.gitmodules
|
||
\.gitignore
|
||
LICENSE
|
||
^/.*\.org
|
||
justfile
|
||
#+END_SRC
|
||
|
||
*** Git Ignore
|
||
|
||
Things to ignore in dotfiles git repo.
|
||
|
||
#+BEGIN_SRC gitignore :tangle .gitignore
|
||
fish/.config/fish/fish_variables
|
||
qt5/.config/qt5ct/qt5ct.conf
|
||
|
||
xournalpp/.config/xournalpp/
|
||
!xournalpp/.config/xournalpp/toolbar.ini
|
||
|
||
autorandr/.config/autorandr/
|
||
!autorandr/.config/autorandr/postswitch
|
||
|
||
vim/.vim/.netrwhist
|
||
|
||
vscode/.config/Code
|
||
!vscode/.config/Code/User/settings.json
|
||
!vscode/.config/Code/User/keybindings.json
|
||
#+END_SRC
|
||
|
||
* Git
|
||
|
||
** Gitconfig
|
||
|
||
#+BEGIN_SRC gitconfig :tangle git/.gitconfig
|
||
# Sravan Balaji's Git Configuration
|
||
# Based on: https://gist.github.com/tdd/470582
|
||
[user]
|
||
email = balajsra@umich.edu
|
||
name = Sravan Balaji
|
||
[color]
|
||
# Enable colors in color-supporting terminals
|
||
ui = auto
|
||
[init]
|
||
defaultBranch = main
|
||
[pull]
|
||
rebase = true
|
||
[alias]
|
||
# List available aliases
|
||
aliases = !git config --get-regexp alias | sed -re 's/alias\\.(\\S*)\\s(.*)$/\\1 = \\2/g'
|
||
# Command shortcuts
|
||
ci = commit
|
||
co = checkout
|
||
st = status
|
||
# Display tree-like log, because default log is a pain…
|
||
lg = log --graph --date=relative --pretty=tformat:'%Cred%h%Creset -%C(auto)%d%Creset %s %Cgreen(%an %ad)%Creset'
|
||
# Useful when you have to update your last commit
|
||
# with staged files without editing the commit message.
|
||
oops = commit --amend --no-edit
|
||
# Ensure that force-pushing won't lose someone else's work (only mine).
|
||
push-with-lease = push --force-with-lease
|
||
# Rebase won’t trigger hooks on each "replayed" commit.
|
||
# This is an ugly hack that will replay each commit during rebase with the
|
||
# standard `commit` command which will trigger hooks.
|
||
rebase-with-hooks = rebase -x 'git reset --soft HEAD~1 && git commit -C HEAD@{1}'
|
||
# List local commits that were not pushed to remote repository
|
||
review-local = "!git lg @{push}.."
|
||
# Edit last commit message
|
||
reword = commit --amend
|
||
# Undo last commit but keep changed files in stage
|
||
uncommit = reset --soft HEAD~1
|
||
# Remove file(s) from Git but not from disk
|
||
untrack = rm --cache --
|
||
[core]
|
||
# Emacs
|
||
editor = "emacs"
|
||
# Don't consider trailing space change as a cause for merge conflicts
|
||
whitespace = -trailing-space
|
||
[diff]
|
||
# Use better, descriptive initials (c, i, w) instead of a/b.
|
||
mnemonicPrefix = true
|
||
# Show renames/moves as such
|
||
renames = true
|
||
# When using --word-diff, assume --word-diff-regex=.
|
||
wordRegex = .
|
||
# Display submodule-related information (commit listings)
|
||
submodule = log
|
||
[fetch]
|
||
# Auto-fetch submodule changes (sadly, won't auto-update)
|
||
recurseSubmodules = on-demand
|
||
[grep]
|
||
break = true
|
||
heading = true
|
||
lineNumber = true
|
||
# Consider most regexes to be ERE
|
||
extendedRegexp = true
|
||
[log]
|
||
# Use abbrev SHAs whenever possible/relevant instead of full 40 chars
|
||
abbrevCommit = true
|
||
# Automatically --follow when given a single path
|
||
follow = true
|
||
# Disable decorate for reflog
|
||
# (because there is no dedicated `reflog` section available)
|
||
decorate = false
|
||
[status]
|
||
# Display submodule rev change summaries in status
|
||
submoduleSummary = true
|
||
# Recursively traverse untracked directories to display all contents
|
||
showUntrackedFiles = all
|
||
#+END_SRC
|
||
|
||
* Notifications
|
||
|
||
** Dunst Notification Daemon
|
||
|
||
*** Configuration
|
||
|
||
See ~man dunst.5~ for available options.
|
||
|
||
**** Global
|
||
|
||
#+BEGIN_SRC conf :tangle dunst/.config/dunst/dunstrc
|
||
[global]
|
||
monitor = 0
|
||
follow = keyboard
|
||
width = 700
|
||
height = 120
|
||
offset = 10x35
|
||
origin = top-right
|
||
notification_limit = 50
|
||
indicate_hidden = true
|
||
padding = 10
|
||
icon_corner_radius = 0
|
||
gap_size = 2
|
||
transparency = 15
|
||
frame_width = 2
|
||
sort = true
|
||
idle_threshold = 120
|
||
font = NotoSans Nerd Font 12
|
||
line_height = 0
|
||
markup = full
|
||
format = "<b>%s</b> | <i>%a</i> %p\n%b"
|
||
alignment = center
|
||
vertical_alignment = center
|
||
show_age_threshold = 60
|
||
word_wrap = true
|
||
ellipsize = middle
|
||
stack_duplicates = true
|
||
hide_duplicate_count = false
|
||
show_indicators = yes
|
||
icon_position = left
|
||
min_icon_size = 0
|
||
max_icon_size = 100
|
||
icon_path = /usr/share/icons/Papirus-Dark/16x16/status/:/usr/share/icons/Papirus-Dark/16x16/devices/
|
||
sticky_history = yes
|
||
history_length = 50
|
||
dmenu = /usr/bin/rofi -dmenu -i -p dunst:
|
||
browser = /usr/bin/vivaldi-stable
|
||
always_run_script = true
|
||
title = Dunst
|
||
class = Dunst
|
||
corner_radius = 10
|
||
ignore_dbusclose = false
|
||
force_xinerama = false
|
||
mouse_left_click = context, close_current
|
||
mouse_middle_click = close_all
|
||
mouse_right_click = close_current
|
||
#+END_SRC
|
||
|
||
**** Experimental
|
||
|
||
#+BEGIN_SRC conf :tangle dunst/.config/dunst/dunstrc
|
||
# Experimental features that may or may not work correctly. Do not expect them
|
||
# to have a consistent behaviour across releases.
|
||
[experimental]
|
||
per_monitor_dpi = false
|
||
#+END_SRC
|
||
|
||
**** Shortcuts
|
||
|
||
#+BEGIN_SRC conf :tangle dunst/.config/dunst/dunstrc
|
||
[shortcuts]
|
||
|
||
# Shortcuts are specified as [modifier+][modifier+]...key
|
||
# Available modifiers are "ctrl", "mod1" (the alt-key), "mod2",
|
||
# "mod3" and "mod4" (windows-key).
|
||
# Xev might be helpful to find names for keys.
|
||
|
||
# Close notification.
|
||
# close = ctrl+space
|
||
|
||
# Close all notifications.
|
||
# close_all = ctrl+shift+space
|
||
|
||
# Redisplay last message(s).
|
||
# On the US keyboard layout "grave" is normally above TAB and left
|
||
# of "1". Make sure this key actually exists on your keyboard layout,
|
||
# e.g. check output of 'xmodmap -pke'
|
||
# history = ctrl+grave
|
||
|
||
# Context menu.
|
||
# context = ctrl+shift+period
|
||
#+END_SRC
|
||
|
||
**** Urgency Low
|
||
|
||
#+BEGIN_SRC conf :tangle dunst/.config/dunst/dunstrc
|
||
[urgency_low]
|
||
frame_color = "#5AF78E"
|
||
background = "#282A36"
|
||
foreground = "#F8F8F2"
|
||
timeout = 10
|
||
#+END_SRC
|
||
|
||
**** Urgency Normal
|
||
|
||
#+BEGIN_SRC conf :tangle dunst/.config/dunst/dunstrc
|
||
[urgency_normal]
|
||
frame_color = "#5AF78E"
|
||
background = "#282A36"
|
||
foreground = "#F8F8F2"
|
||
timeout = 10
|
||
#+END_SRC
|
||
|
||
**** Urgency Critical
|
||
|
||
#+BEGIN_SRC conf :tangle dunst/.config/dunst/dunstrc
|
||
[urgency_critical]
|
||
frame_color = "#50FA7B"
|
||
background = "#FF5555"
|
||
foreground = "#F8F8F2"
|
||
timeout = 0
|
||
#+END_SRC
|
||
|
||
**** Miscellaneous
|
||
|
||
#+BEGIN_SRC conf :tangle dunst/.config/dunst/dunstrc
|
||
# 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 (discouraged, see desktop_entry)
|
||
# body
|
||
# category
|
||
# desktop_entry
|
||
# icon
|
||
# match_transient
|
||
# msg_urgency
|
||
# stack_tag
|
||
# summary
|
||
#
|
||
# and you can override the
|
||
# background
|
||
# foreground
|
||
# format
|
||
# frame_color
|
||
# fullscreen
|
||
# new_icon
|
||
# set_stack_tag
|
||
# set_transient
|
||
# timeout
|
||
# urgency
|
||
#
|
||
# Shell-like globbing will get expanded.
|
||
#
|
||
# Instead of the appname filter, it's recommended to use the desktop_entry filter.
|
||
# GLib based applications export their desktop-entry name. In comparison to the appname,
|
||
# the desktop-entry won't get localized.
|
||
#
|
||
# 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.
|
||
|
||
# Disable the transient hint so that idle_threshold cannot be bypassed from the
|
||
# client
|
||
#[transient_disable]
|
||
# match_transient = yes
|
||
# set_transient = no
|
||
#
|
||
# Make the handling of transient notifications more strict by making them not
|
||
# be placed in history.
|
||
#[transient_history_ignore]
|
||
# match_transient = yes
|
||
# history_ignore = yes
|
||
|
||
# fullscreen values
|
||
# show: show the notifications, regardless if there is a fullscreen window opened
|
||
# delay: displays the new notification, if there is no fullscreen window active
|
||
# If the notification is already drawn, it won't get undrawn.
|
||
# pushback: same as delay, but when switching into fullscreen, the notification will get
|
||
# withdrawn from screen again and will get delayed like a new notification
|
||
#[fullscreen_delay_everything]
|
||
# fullscreen = delay
|
||
#[fullscreen_show_critical]
|
||
# msg_urgency = critical
|
||
# fullscreen = show
|
||
|
||
#[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
|
||
|
||
#[skip-display]
|
||
# # This notification will not be displayed, but will be included in the history
|
||
# summary = "foobar"
|
||
# skip_display = 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
|
||
#
|
||
#[stack-volumes]
|
||
# appname = "some_volume_notifiers"
|
||
# set_stack_tag = "volume"
|
||
#
|
||
# vim: ft=cfg
|
||
#+END_SRC
|
||
|
||
*** Control Script
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dunst/.scripts/dunst.sh
|
||
help_menu() {
|
||
echo "Script to interact with dunst. Use only one argument at a time."
|
||
echo " - Toggle On/Off: dunst.sh OR dunst.sh --toggle OR dunst.sh -t"
|
||
echo " - Turn On: dunst.sh --on"
|
||
echo " - Turn Off: dunst.sh --off"
|
||
echo " - Context Menu: dunst.sh --context"
|
||
echo " - Close Notification: dunst.sh --close"
|
||
echo " - Close All Notifications: dunst.sh --close-all"
|
||
echo " - History Pop: dunst.sh --history"
|
||
echo " - History Clear: dunst.sh --history-clear"
|
||
echo " - Toggle Do Not Disturb: dunst.sh --dnd"
|
||
echo " - Pause Notifications: dunst.sh --pause"
|
||
echo " - Unpause Notifications: dunst.sh --unpause"
|
||
echo " - Rofi Menu: dunst.sh --rofi"
|
||
echo " - Help: dunst.sh --help OR dunst.sh -h"
|
||
}
|
||
|
||
is_running() {
|
||
if pgrep -x dunst >/dev/null; then
|
||
echo 1
|
||
else
|
||
echo 0
|
||
fi
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
"⏼ Toggle - toggle"
|
||
" Turn On - on"
|
||
" Turn Off - off"
|
||
" Open Actions - context"
|
||
" Close Notification - close"
|
||
" Close All Notifications - close-all"
|
||
" View History - history"
|
||
" Clear History - history-clear"
|
||
" Toggle Do Not Disturb - dnd"
|
||
" Pause Popup Notifications - pause"
|
||
" Unpause Popup Notifications - unpause"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--toggle)
|
||
if [ $(is_running) -eq '1' ]; then
|
||
main --off
|
||
else
|
||
main --on
|
||
fi
|
||
;;
|
||
--on)
|
||
if [ $(is_running) -eq '1' ]; then
|
||
pkill dunst
|
||
fi
|
||
|
||
# Start Dunst
|
||
/usr/bin/dunst -config ~/.config/dunst/dunstrc &
|
||
|
||
notify-send "Turning Dunst ON"
|
||
;;
|
||
--off)
|
||
notify-send "Turning Dunst OFF"
|
||
|
||
if [ $(is_running) -eq '1' ]; then
|
||
pkill dunst
|
||
fi
|
||
;;
|
||
--context)
|
||
dunstctl context
|
||
;;
|
||
--close)
|
||
dunstctl close
|
||
;;
|
||
--close-all)
|
||
dunstctl close-all
|
||
;;
|
||
--history)
|
||
dunstctl history-pop
|
||
;;
|
||
--history-clear)
|
||
dunstctl history-clear
|
||
;;
|
||
--dnd)
|
||
dunstctl set-paused toggle
|
||
;;
|
||
--pause)
|
||
dunstctl set-paused true
|
||
;;
|
||
--unpause)
|
||
dunstctl set-paused false
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Deadd Notification Center
|
||
|
||
*** Configuration
|
||
|
||
**** General
|
||
|
||
#+BEGIN_SRC yaml :tangle deadd/.config/deadd/deadd.yml
|
||
### Margins for notification-center/notifications
|
||
margin-top: 35
|
||
margin-right: 10
|
||
|
||
### Margins for notification-center
|
||
margin-bottom: 10
|
||
|
||
### Width of the notification center/notifications in pixels.
|
||
width: 700
|
||
|
||
### Command to run at startup. This can be used to setup
|
||
### button states.
|
||
# startup-command: deadd-notification-center-startup
|
||
|
||
### Monitor on which the notification center/notifications will be
|
||
### printed. If "follow-mouse" is set true, this does nothing.
|
||
monitor: 0
|
||
|
||
### If true, the notification center/notifications will open on the
|
||
### screen, on which the mouse is. Overrides the "monitor" setting.
|
||
follow-mouse: true
|
||
#+END_SRC
|
||
|
||
**** Notification Center
|
||
|
||
#+BEGIN_SRC yaml :tangle deadd/.config/deadd/deadd.yml
|
||
notification-center:
|
||
### Margin at the top/right/bottom of the notification center in
|
||
### pixels. This can be used to avoid overlap between the notification
|
||
### center and bars such as polybar or i3blocks.
|
||
# margin-top: 0
|
||
# margin-right: 0
|
||
# margin-bottom: 0
|
||
|
||
### Width of the notification center in pixels.
|
||
# width: 500
|
||
|
||
### Monitor on which the notification center will be printed. If
|
||
### "follow-mouse" is set true, this does nothing.
|
||
# monitor: 0
|
||
|
||
### If true, the notification center will open on the screen, on which
|
||
### the mouse is. Overrides the "monitor" setting.
|
||
# follow-mouse: false
|
||
|
||
### Notification center closes when the mouse leaves it
|
||
hide-on-mouse-leave: false
|
||
|
||
### If newFirst is set to true, newest notifications appear on the top
|
||
### of the notification center. Else, notifications stack, from top to
|
||
### bottom.
|
||
new-first: true
|
||
|
||
### If true, the transient field in notifications will be ignored,
|
||
### thus the notification will be persisted in the notification
|
||
### center anyways
|
||
ignore-transient: false
|
||
|
||
### Custom buttons in notification center
|
||
buttons:
|
||
### Numbers of buttons that can be drawn on a row of the notification
|
||
### center.
|
||
buttons-per-row: 3
|
||
|
||
### Height of buttons in the notification center (in pixels).
|
||
button-height: 60
|
||
|
||
### Horizontal and vertical margin between each button in the
|
||
### notification center (in pixels).
|
||
button-margin: 2
|
||
|
||
### Button actions and labels. For each button you must specify a
|
||
### label and a command.
|
||
actions:
|
||
# - label: VPN
|
||
# command: "sudo vpnToggle"
|
||
# - label: Bluetooth
|
||
# command: bluetoothToggle
|
||
# - label: Wifi
|
||
# command: wifiToggle
|
||
# - label: Screensaver
|
||
# command: screensaverToggle
|
||
# - label: Keyboard
|
||
# command: keyboardToggle
|
||
- label: "Pause Notifications"
|
||
command: "/home/sravan/.scripts/deadd.sh --pause"
|
||
- label: "Unpause Notifications"
|
||
command: "/home/sravan/.scripts/deadd.sh --unpause"
|
||
- label: "Close Notification Center"
|
||
command: "/home/sravan/.scripts/deadd.sh --toggle-center"
|
||
#+END_SRC
|
||
|
||
**** Notification
|
||
|
||
#+BEGIN_SRC yaml :tangle deadd/.config/deadd/deadd.yml
|
||
notification:
|
||
|
||
### If true, markup (<u>, <i>, <b>, <a>) will be displayed properly
|
||
use-markup: true
|
||
|
||
### If true, html entities (& for &, % for %, etc) will be
|
||
### parsed properly. This is useful for chromium-based apps, which
|
||
### tend to send these in notifications.
|
||
parse-html-entities: true
|
||
|
||
dbus:
|
||
### If noti-closed messages are enabled, the sending application
|
||
### will know that a notification was closed/timed out. This can
|
||
### be an issue for certain applications, that overwrite
|
||
### notifications on status updates (e.g. Spotify on each
|
||
### song). When one of these applications thinks, the notification
|
||
### has been closed/timed out, they will not overwrite existing
|
||
### notifications but send new ones. This can lead to redundant
|
||
### notifications in the notification center, as the close-message
|
||
### is send regardless of the notification being persisted.
|
||
send-noti-closed: false
|
||
|
||
app-icon:
|
||
### If set to true: If no icon is passed by the app_icon parameter
|
||
### and no application "desktop-entry"-hint is present, deadd will
|
||
### try to guess the icon from the application name (if present).
|
||
guess-icon-from-name: true
|
||
|
||
### The display size of the application icons in the notification
|
||
### pop-ups and in the notification center
|
||
icon-size: 25
|
||
|
||
image:
|
||
### The maximal display size of images that are part of
|
||
### notifications for notification pop-ups and in the notification
|
||
### center
|
||
size: 100
|
||
|
||
### The margin around the top, bottom, left, and right of
|
||
### notification images.
|
||
margin-top: 10
|
||
margin-bottom: 10
|
||
margin-left: 10
|
||
margin-right: 0
|
||
|
||
### Apply modifications to certain notifications:
|
||
### Each modification rule needs a "match" and either a "modify" or
|
||
### a "script" entry.
|
||
modifications:
|
||
### Match:
|
||
### Matches the notifications against these rules. If all of the
|
||
### values (of one modification rule) match, the "modify"/"script"
|
||
### part is applied.
|
||
# - match:
|
||
### Possible match criteria:
|
||
# title: "Notification title"
|
||
# body: "Notification body"
|
||
# time: "12:44"
|
||
# app-name: "App name"
|
||
|
||
# modify:
|
||
### Possible modifications
|
||
# title: "abc"
|
||
# body: "abc"
|
||
# app-name: "abc"
|
||
# app-icon: "file:///abc.png"
|
||
### The timeout has three special values:
|
||
### timeout: 0 -> don't time out at all
|
||
### timeout: -1 -> use default timeout
|
||
### timeout: 1 -> don't show as pop-up
|
||
### timeout: >1 -> milliseconds until timeout
|
||
# timeout: 1
|
||
# margin-right: 10
|
||
# margin-top: 10
|
||
# image: "file:///abc.png"
|
||
# image-size: 10
|
||
# transient: true
|
||
# send-noti-closed: false
|
||
### Remove action buttons from notifications
|
||
# remove-actions: true
|
||
### Add a class-name to the notification container, that can be
|
||
### used for specific styling of notifications using the
|
||
### deadd.css file
|
||
# class-name: "abc"
|
||
|
||
# - match:
|
||
# app-name: "Chromium"
|
||
|
||
### Instead of modifying a notification directly, a script can be
|
||
### run, which will receive the notification as JSON on STDIN. It
|
||
### is expected to return JSON/YAML configuration that defines the
|
||
### modifications that should be applied. Minimum complete return
|
||
### value must be '{"modify": {}, "match": {}}'. Always leave the "match"
|
||
### object empty (technical reasons, i.e. I am lazy).
|
||
# script: "linux-notification-center-parse-chromium"
|
||
# - match:
|
||
# app-name: "Spotify"
|
||
# modify:
|
||
# image-size: 80
|
||
# timeout: 1
|
||
# send-noti-closed: true
|
||
# class-name: "Spotify"
|
||
# - match:
|
||
# title: Bildschirmhelligkeit
|
||
# modify:
|
||
# image-size: 60
|
||
|
||
popup:
|
||
|
||
### Default timeout used for notifications in milli-seconds. This can
|
||
### be overwritten with the "-t" option (or "--expire-time") of the
|
||
### notify-send command.
|
||
default-timeout: 10000
|
||
|
||
# Margin above/right/between notifications (in pixels). This can
|
||
# be used to avoid overlap between notifications and a bar such as
|
||
# polybar or i3blocks.
|
||
margin-top: 35
|
||
margin-right: 10
|
||
margin-between: 10
|
||
|
||
### Monitor on which the notifications will be
|
||
### printed. If "follow-mouse" is set true, this does nothing.
|
||
# monitor: 0
|
||
|
||
### If true, the notifications will open on the
|
||
### screen, on which the mouse is. Overrides the "monitor" setting.
|
||
# follow-mouse: false
|
||
|
||
click-behavior:
|
||
|
||
### The mouse button for dismissing a popup. Must be either "mouse1",
|
||
### "mouse2", "mouse3", "mouse4", or "mouse5"
|
||
dismiss: mouse1
|
||
|
||
### The mouse button for opening a popup with the default action.
|
||
### Must be either "mouse1", "mouse2", "mouse3", "mouse4", or "mouse5"
|
||
default-action: mouse3
|
||
#+END_SRC
|
||
|
||
*** Styling
|
||
|
||
**** Notification Center
|
||
|
||
#+BEGIN_SRC conf :tangle deadd/.config/deadd/deadd.css
|
||
.blurredBG, #main_window, .blurredBG.low, .blurredBG.normal {
|
||
background: rgba(40, 42, 54, 1.0);
|
||
border: 2px #50fa7b solid;
|
||
border-radius: 10px;
|
||
}
|
||
|
||
.noti-center.time {
|
||
font-size: 32px;
|
||
margin-left: 10px;
|
||
margin-right: 10px;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Notifications
|
||
|
||
#+BEGIN_SRC conf :tangle deadd/.config/deadd/deadd.css
|
||
.title {
|
||
font-weight: bold;
|
||
font-size: 16px;
|
||
margin-left: 10px;
|
||
margin-right: 10px;
|
||
}
|
||
|
||
.body {
|
||
font-weight: normal;
|
||
font-size: 16px;
|
||
margin-left: 10px;
|
||
margin-right: 10px;
|
||
}
|
||
|
||
.appname {
|
||
font-size: 12px;
|
||
margin-left: 10px;
|
||
margin-right: 10px;
|
||
}
|
||
|
||
.time {
|
||
font-size: 12px;
|
||
margin-left: 10px;
|
||
margin-right: 10px;
|
||
}
|
||
|
||
.blurredBG.notification {
|
||
background: rgba(40, 42, 54, 1.0);
|
||
border: 2pt #50fa7b solid;
|
||
border-radius: 10px;
|
||
}
|
||
|
||
.blurredBG.notification.critical {
|
||
background: rgba(255, 85, 85, 1.0);
|
||
border: 2pt #50fa7b solid;
|
||
border-radius: 10px;
|
||
}
|
||
|
||
.notificationInCenter.critical {
|
||
background: rgba(255, 85, 85, 1.0);
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Labels
|
||
|
||
#+BEGIN_SRC conf :tangle deadd/.config/deadd/deadd.css
|
||
label {
|
||
color: #f8f8f2;
|
||
}
|
||
|
||
label.notification {
|
||
color: #f8f8f2;
|
||
}
|
||
|
||
label.critical {
|
||
color: #f8f8f2;
|
||
}
|
||
.notificationInCenter label.critical {
|
||
color: #f8f8f2;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Buttons
|
||
|
||
#+BEGIN_SRC conf :tangle deadd/.config/deadd/deadd.css
|
||
button {
|
||
border-radius: 10px;
|
||
background: rgba(40, 42, 54, 1.0);
|
||
border-width: 2px;
|
||
color: #f8f8f2;
|
||
}
|
||
|
||
button:hover {
|
||
border-radius: 10px;
|
||
background: rgba(68, 71, 90, 0.8);
|
||
border-width: 2px;
|
||
border-color: #50fa7b;
|
||
color: #282a36;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Custom Buttons
|
||
|
||
#+BEGIN_SRC conf :tangle deadd/.config/deadd/deadd.css
|
||
.userbutton {
|
||
border-radius: 10px;
|
||
background: rgba(40, 42, 54, 1.0);
|
||
border-width: 2px;
|
||
}
|
||
|
||
.userbutton:hover {
|
||
border-radius: 10px;
|
||
background: rgba(68, 71, 90, 1.0);
|
||
border-width: 2px;
|
||
border-color: #50fa7b;
|
||
}
|
||
|
||
.userbuttonlabel {
|
||
color: #f8f8f2;
|
||
font-size: 12px;
|
||
}
|
||
|
||
.userbuttonlabel:hover {
|
||
color: #f8f8f2;
|
||
}
|
||
|
||
button.buttonState1 {
|
||
background: rgba(20,0,0,0.5);
|
||
}
|
||
|
||
.userbuttonlabel.buttonState1 {
|
||
color: #fff;
|
||
}
|
||
|
||
button.buttonState1:hover {
|
||
background: rgba(20,0,0, 0.4);
|
||
}
|
||
|
||
.userbuttonlabel.buttonState1:hover {
|
||
color: #111;
|
||
}
|
||
|
||
button.buttonState2 {
|
||
background: rgba(255,255,255,0.3);
|
||
}
|
||
|
||
.userbuttonlabel.buttonState2 {
|
||
color: #111;
|
||
}
|
||
|
||
button.buttonState2:hover {
|
||
background: rgba(20,0,0, 0.3);
|
||
}
|
||
|
||
.userbuttonlabel.buttonState2:hover {
|
||
color: #000;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Images
|
||
|
||
#+BEGIN_SRC conf :tangle deadd/.config/deadd/deadd.css
|
||
image.deadd-noti-center.notification.image {
|
||
margin-left: 10px;
|
||
}
|
||
#+END_SRC
|
||
|
||
*** Control Script
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle deadd/.scripts/deadd.sh
|
||
help_menu() {
|
||
echo "Script to interact with deadd. Use only one argument at a time."
|
||
echo " - Toggle On/Off: deadd.sh OR deadd.sh --toggle OR deadd.sh -t"
|
||
echo " - Turn On: deadd.sh --on"
|
||
echo " - Turn Off: deadd.sh --off"
|
||
echo " - Toggle Notification Center: deadd.sh --toggle-center"
|
||
echo " - Pause Popup Notifications: deadd.sh --pause"
|
||
echo " - Unpause Popup Notifications: deadd.sh --unpause"
|
||
echo " - Rofi Menu: deadd.sh --rofi"
|
||
echo " - Help: deadd.sh --help OR deadd.sh -h"
|
||
}
|
||
|
||
is_running() {
|
||
if pgrep -x deadd-notificat >/dev/null; then
|
||
echo 1
|
||
else
|
||
echo 0
|
||
fi
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
"⏼ Toggle - toggle"
|
||
" Turn On - on"
|
||
" Turn Off - off"
|
||
" Toggle Notification Center - toggle-center"
|
||
" Pause Popup Notifications - pause"
|
||
" Unpause Popup Notifications - unpause"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--toggle)
|
||
if [ $(is_running) -eq '1' ]; then
|
||
main --off
|
||
else
|
||
main --on
|
||
fi
|
||
;;
|
||
--on)
|
||
if [ $(is_running) -eq '1' ]; then
|
||
pkill deadd-notificat
|
||
fi
|
||
|
||
/usr/bin/notify-send.py a --hint \
|
||
boolean:deadd-notification-center:true \
|
||
string:type:reloadStyle
|
||
|
||
notify-send "Turning Deadd ON"
|
||
;;
|
||
--off)
|
||
notify-send "Turning Deadd OFF"
|
||
|
||
if [ $(is_running) -eq '1' ]; then
|
||
pkill deadd-notificat
|
||
fi
|
||
;;
|
||
--toggle-center)
|
||
kill -s USR1 $(pidof deadd-notification-center)
|
||
;;
|
||
--pause)
|
||
notify-send "Pausing Notifications"
|
||
|
||
/usr/bin/notify-send.py a --hint \
|
||
boolean:deadd-notification-center:true \
|
||
string:type:pausePopups > /dev/null 2>&1
|
||
;;
|
||
--unpause)
|
||
/usr/bin/notify-send.py a --hint \
|
||
boolean:deadd-notification-center:true \
|
||
string:type:unpausePopups > /dev/null 2>&1
|
||
|
||
notify-send "Unpausing Notifications"
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** AwesomeWM Naughty
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle naughty/.scripts/naughty.sh
|
||
help_menu() {
|
||
echo "Script to interact with AwesomeWM's naughty. Use only one argument at a time."
|
||
echo " - Toggle Pause/Unpause: naughty.sh OR naughty.sh --toggle OR naughty.sh -t"
|
||
echo " - Pause Popup Notifications: naughty.sh --pause"
|
||
echo " - Unpause Popup Notifications: naughty.sh --unpause"
|
||
echo " - Rofi Menu: naughty.sh --rofi"
|
||
echo " - Help: naughty.sh --help OR naughty.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
"⏼ Toggle - toggle"
|
||
" Pause Popup Notifications - pause"
|
||
" Unpause Popup Notifications - unpause"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--toggle)
|
||
/usr/bin/awesome-client '
|
||
local naughty = require("naughty")
|
||
naughty.toggle()
|
||
'
|
||
;;
|
||
--pause)
|
||
notify-send "Pausing Notifications"
|
||
|
||
/usr/bin/awesome-client '
|
||
local naughty = require("naughty")
|
||
naughty.suspend()
|
||
'
|
||
;;
|
||
--unpause)
|
||
/usr/bin/awesome-client '
|
||
local naughty = require("naughty")
|
||
naughty.resume()
|
||
'
|
||
|
||
notify-send "Unpausing Notifications"
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** SwayNotificationCenter
|
||
|
||
*** Config
|
||
|
||
#+BEGIN_SRC json :tangle swaync/.config/swaync/config.json
|
||
{
|
||
"$schema": "/etc/xdg/swaync/configSchema.json",
|
||
"positionX": "right",
|
||
"positionY": "top",
|
||
"layer": "overlay",
|
||
"control-center-layer": "top",
|
||
"layer-shell": true,
|
||
"cssPriority": "application",
|
||
"control-center-margin-top": 0,
|
||
"control-center-margin-bottom": 0,
|
||
"control-center-margin-right": 0,
|
||
"control-center-margin-left": 0,
|
||
"notification-2fa-action": true,
|
||
"notification-inline-replies": false,
|
||
"notification-icon-size": 64,
|
||
"notification-body-image-height": 100,
|
||
"notification-body-image-width": 200,
|
||
"timeout": 10,
|
||
"timeout-low": 5,
|
||
"timeout-critical": 0,
|
||
"fit-to-screen": true,
|
||
"relative-timestamps": true,
|
||
"control-center-width": 500,
|
||
"control-center-height": 600,
|
||
"notification-window-width": 500,
|
||
"keyboard-shortcuts": true,
|
||
"image-visibility": "when-available",
|
||
"transition-time": 200,
|
||
"hide-on-clear": false,
|
||
"hide-on-action": true,
|
||
"script-fail-notify": true,
|
||
"scripts": {
|
||
"example-script": {
|
||
"exec": "echo 'Do something...'",
|
||
"urgency": "Normal"
|
||
},
|
||
"example-action-script": {
|
||
"exec": "echo 'Do something actionable!'",
|
||
"urgency": "Normal",
|
||
"run-on": "action"
|
||
}
|
||
},
|
||
"notification-visibility": {
|
||
"example-name": {
|
||
"state": "muted",
|
||
"urgency": "Low",
|
||
"app-name": "Spotify"
|
||
}
|
||
},
|
||
"widgets": [
|
||
"inhibitors",
|
||
"title",
|
||
"dnd",
|
||
"notifications"
|
||
],
|
||
"widget-config": {
|
||
"inhibitors": {
|
||
"text": "Inhibitors",
|
||
"button-text": "Clear All",
|
||
"clear-all-button": true
|
||
},
|
||
"title": {
|
||
"text": "Notifications",
|
||
"clear-all-button": true,
|
||
"button-text": "Clear All"
|
||
},
|
||
"dnd": {
|
||
"text": "Do Not Disturb"
|
||
},
|
||
"label": {
|
||
"max-lines": 5,
|
||
"text": "Label Text"
|
||
},
|
||
"mpris": {
|
||
"image-size": 96,
|
||
"image-radius": 12
|
||
},
|
||
"buttons-grid": {
|
||
"actions": [
|
||
{
|
||
"label": "直",
|
||
"type": "toggle",
|
||
"active": true,
|
||
"command": "sh -c '[[ $SWAYNC_TOGGLE_STATE == true ]] && nmcli radio wifi on || nmcli radio wifi off'",
|
||
"update_command": "sh -c '[[ $(nmcli radio wifi) == \"enabled\" ]] && echo true || echo false'"
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
#+END_SRC
|
||
|
||
*** Style
|
||
|
||
#+BEGIN_SRC css :tangle swaync/.config/swaync/style.css
|
||
@define-color cc-bg rgba(46, 46, 46, 0.7);
|
||
@define-color noti-border-color rgba(255, 255, 255, 0.15);
|
||
@define-color noti-bg rgba(48, 48, 48, 0.8);
|
||
@define-color noti-bg-opaque rgb(48, 48, 48);
|
||
@define-color noti-bg-darker rgb(38, 38, 38);
|
||
@define-color noti-bg-hover rgb(56, 56, 56);
|
||
@define-color noti-bg-hover-opaque rgb(56, 56, 56);
|
||
@define-color noti-bg-focus rgba(68, 68, 68, 0.6);
|
||
@define-color noti-close-bg rgba(255, 255, 255, 0.1);
|
||
@define-color noti-close-bg-hover rgba(255, 255, 255, 0.15);
|
||
@define-color text-color rgb(255, 255, 255);
|
||
@define-color text-color-disabled rgb(150, 150, 150);
|
||
@define-color bg-selected rgb(0, 128, 255);
|
||
.notification-row {
|
||
outline: none;
|
||
}
|
||
|
||
.notification-row:focus, .notification-row:hover {
|
||
background: @noti-bg-focus;
|
||
}
|
||
|
||
.notification-row .notification-background {
|
||
padding: 6px 12px;
|
||
}
|
||
|
||
.notification-row .notification-background .close-button {
|
||
/* The notification Close Button */
|
||
background: @noti-close-bg;
|
||
color: @text-color;
|
||
text-shadow: none;
|
||
padding: 0;
|
||
border-radius: 100%;
|
||
margin-top: 5px;
|
||
margin-right: 5px;
|
||
box-shadow: none;
|
||
border: none;
|
||
min-width: 24px;
|
||
min-height: 24px;
|
||
}
|
||
|
||
.notification-row .notification-background .close-button:hover {
|
||
box-shadow: none;
|
||
background: @noti-close-bg-hover;
|
||
transition: background 0.15s ease-in-out;
|
||
border: none;
|
||
}
|
||
|
||
.notification-row .notification-background .notification {
|
||
/* The actual notification */
|
||
border-radius: 12px;
|
||
border: 1px solid @noti-border-color;
|
||
padding: 0;
|
||
transition: background 0.15s ease-in-out;
|
||
background: @noti-bg;
|
||
}
|
||
|
||
.notification-row .notification-background .notification.low {
|
||
/* Low Priority Notification */
|
||
}
|
||
|
||
.notification-row .notification-background .notification.normal {
|
||
/* Normal Priority Notification */
|
||
}
|
||
|
||
.notification-row .notification-background .notification.critical {
|
||
/* Critical Priority Notification */
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-action, .notification-row .notification-background .notification .notification-default-action {
|
||
padding: 4px;
|
||
margin: 0;
|
||
box-shadow: none;
|
||
background: transparent;
|
||
border: none;
|
||
color: @text-color;
|
||
transition: background 0.15s ease-in-out;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-action:hover, .notification-row .notification-background .notification .notification-default-action:hover {
|
||
-gtk-icon-effect: none;
|
||
background: @noti-bg-hover;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action {
|
||
/* The large action that also displays the notification summary and body */
|
||
border-radius: 12px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action:not(:only-child) {
|
||
/* When alternative actions are visible */
|
||
border-bottom-left-radius: 0px;
|
||
border-bottom-right-radius: 0px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content {
|
||
background: transparent;
|
||
border-radius: 12px;
|
||
padding: 4px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .image {
|
||
/* Notification Primary Image */
|
||
-gtk-icon-effect: none;
|
||
border-radius: 100px;
|
||
/* Size in px */
|
||
margin: 4px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .app-icon {
|
||
/* Notification app icon (only visible when the primary image is set) */
|
||
-gtk-icon-effect: none;
|
||
-gtk-icon-shadow: 0 1px 4px black;
|
||
margin: 6px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .text-box .summary {
|
||
/* Notification summary/title */
|
||
font-size: 16px;
|
||
font-weight: bold;
|
||
background: transparent;
|
||
color: @text-color;
|
||
text-shadow: none;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .text-box .time {
|
||
/* Notification time-ago */
|
||
font-size: 16px;
|
||
font-weight: bold;
|
||
background: transparent;
|
||
color: @text-color;
|
||
text-shadow: none;
|
||
margin-right: 30px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .text-box .body {
|
||
/* Notification body */
|
||
font-size: 15px;
|
||
font-weight: normal;
|
||
background: transparent;
|
||
color: @text-color;
|
||
text-shadow: none;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content progressbar {
|
||
/* The optional notification progress bar */
|
||
margin-top: 4px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .body-image {
|
||
/* The "extra" optional bottom notification image */
|
||
margin-top: 4px;
|
||
background-color: white;
|
||
border-radius: 12px;
|
||
-gtk-icon-effect: none;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .inline-reply {
|
||
/* The inline reply section */
|
||
margin-top: 4px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .inline-reply .inline-reply-entry {
|
||
background: @noti-bg-darker;
|
||
color: @text-color;
|
||
caret-color: @text-color;
|
||
border: 1px solid @noti-border-color;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .inline-reply .inline-reply-button {
|
||
margin-left: 4px;
|
||
background: @noti-bg;
|
||
border: 1px solid @noti-border-color;
|
||
border-radius: 12px;
|
||
color: @text-color;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .inline-reply .inline-reply-button:disabled {
|
||
background: initial;
|
||
color: @text-color-disabled;
|
||
border: 1px solid @noti-border-color;
|
||
border-color: transparent;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-default-action .notification-content .inline-reply .inline-reply-button:hover {
|
||
background: @noti-bg-hover;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-action {
|
||
/* The alternative actions below the default action */
|
||
border-top: 1px solid @noti-border-color;
|
||
border-radius: 0px;
|
||
border-right: 1px solid @noti-border-color;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-action:first-child {
|
||
/* add bottom border radius to eliminate clipping */
|
||
border-bottom-left-radius: 12px;
|
||
}
|
||
|
||
.notification-row .notification-background .notification .notification-action:last-child {
|
||
border-bottom-right-radius: 12px;
|
||
border-right: none;
|
||
}
|
||
|
||
.notification-group {
|
||
/* Styling only for Grouped Notifications */
|
||
}
|
||
|
||
.notification-group.low {
|
||
/* Low Priority Group */
|
||
}
|
||
|
||
.notification-group.normal {
|
||
/* Low Priority Group */
|
||
}
|
||
|
||
.notification-group.critical {
|
||
/* Low Priority Group */
|
||
}
|
||
|
||
.notification-group .notification-group-buttons, .notification-group .notification-group-headers {
|
||
margin: 0 16px;
|
||
color: @text-color;
|
||
}
|
||
|
||
.notification-group .notification-group-headers {
|
||
/* Notification Group Headers */
|
||
}
|
||
|
||
.notification-group .notification-group-headers .notification-group-icon {
|
||
color: @text-color;
|
||
}
|
||
|
||
.notification-group .notification-group-headers .notification-group-header {
|
||
color: @text-color;
|
||
}
|
||
|
||
.notification-group .notification-group-buttons {
|
||
/* Notification Group Buttons */
|
||
}
|
||
|
||
.notification-group.collapsed .notification-row .notification {
|
||
background-color: @noti-bg-opaque;
|
||
}
|
||
|
||
.notification-group.collapsed .notification-row:not(:last-child) {
|
||
/* Top notification in stack */
|
||
/* Set lower stacked notifications opacity to 0 */
|
||
}
|
||
|
||
.notification-group.collapsed .notification-row:not(:last-child) .notification-action,
|
||
.notification-group.collapsed .notification-row:not(:last-child) .notification-default-action {
|
||
opacity: 0;
|
||
}
|
||
|
||
.notification-group.collapsed:hover .notification-row:not(:only-child) .notification {
|
||
background-color: @noti-bg-hover-opaque;
|
||
}
|
||
|
||
.control-center {
|
||
/* The Control Center which contains the old notifications + widgets */
|
||
background: @cc-bg;
|
||
color: @text-color;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
.control-center .control-center-list-placeholder {
|
||
/* The placeholder when there are no notifications */
|
||
opacity: 0.5;
|
||
}
|
||
|
||
.control-center .control-center-list {
|
||
/* List of notifications */
|
||
background: transparent;
|
||
}
|
||
|
||
.control-center .control-center-list .notification {
|
||
box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.3), 0 1px 3px 1px rgba(0, 0, 0, 0.7), 0 2px 6px 2px rgba(0, 0, 0, 0.3);
|
||
}
|
||
|
||
.control-center .control-center-list .notification .notification-default-action,
|
||
.control-center .control-center-list .notification .notification-action {
|
||
transition: opacity 400ms ease-in-out, background 0.15s ease-in-out;
|
||
}
|
||
|
||
.control-center .control-center-list .notification .notification-default-action:hover,
|
||
.control-center .control-center-list .notification .notification-action:hover {
|
||
background-color: @noti-bg-hover;
|
||
}
|
||
|
||
.blank-window {
|
||
/* Window behind control center and on all other monitors */
|
||
background: transparent;
|
||
}
|
||
|
||
.floating-notifications {
|
||
background: transparent;
|
||
}
|
||
|
||
.floating-notifications .notification {
|
||
box-shadow: none;
|
||
}
|
||
|
||
/*** Widgets ***/
|
||
/* Title widget */
|
||
.widget-title {
|
||
color: @text-color;
|
||
margin: 8px;
|
||
font-size: 1.5rem;
|
||
}
|
||
|
||
.widget-title > button {
|
||
font-size: initial;
|
||
color: @text-color;
|
||
text-shadow: none;
|
||
background: @noti-bg;
|
||
border: 1px solid @noti-border-color;
|
||
box-shadow: none;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
.widget-title > button:hover {
|
||
background: @noti-bg-hover;
|
||
}
|
||
|
||
/* DND widget */
|
||
.widget-dnd {
|
||
color: @text-color;
|
||
margin: 8px;
|
||
font-size: 1.1rem;
|
||
}
|
||
|
||
.widget-dnd > switch {
|
||
font-size: initial;
|
||
border-radius: 12px;
|
||
background: @noti-bg;
|
||
border: 1px solid @noti-border-color;
|
||
box-shadow: none;
|
||
}
|
||
|
||
.widget-dnd > switch:checked {
|
||
background: @bg-selected;
|
||
}
|
||
|
||
.widget-dnd > switch slider {
|
||
background: @noti-bg-hover;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
/* Label widget */
|
||
.widget-label {
|
||
margin: 8px;
|
||
}
|
||
|
||
.widget-label > label {
|
||
font-size: 1.1rem;
|
||
}
|
||
|
||
/* Mpris widget */
|
||
@define-color mpris-album-art-overlay rgba(0, 0, 0, 0.55);
|
||
@define-color mpris-button-hover rgba(0, 0, 0, 0.50);
|
||
.widget-mpris {
|
||
/* The parent to all players */
|
||
}
|
||
|
||
.widget-mpris .widget-mpris-player {
|
||
padding: 8px;
|
||
padding: 16px;
|
||
margin: 16px 20px;
|
||
background-color: @mpris-album-art-overlay;
|
||
border-radius: 12px;
|
||
box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.75);
|
||
}
|
||
|
||
.widget-mpris .widget-mpris-player button:hover {
|
||
/* The media player buttons (play, pause, next, etc...) */
|
||
background: @noti-bg-hover;
|
||
}
|
||
|
||
.widget-mpris .widget-mpris-player .widget-mpris-album-art {
|
||
border-radius: 12px;
|
||
box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.75);
|
||
}
|
||
|
||
.widget-mpris .widget-mpris-player .widget-mpris-title {
|
||
font-weight: bold;
|
||
font-size: 1.25rem;
|
||
}
|
||
|
||
.widget-mpris .widget-mpris-player .widget-mpris-subtitle {
|
||
font-size: 1.1rem;
|
||
}
|
||
|
||
.widget-mpris .widget-mpris-player > box > button {
|
||
/* Change player control buttons */
|
||
}
|
||
|
||
.widget-mpris .widget-mpris-player > box > button:hover {
|
||
background-color: @mpris-button-hover;
|
||
}
|
||
|
||
.widget-mpris > box > button {
|
||
/* Change player side buttons */
|
||
}
|
||
|
||
.widget-mpris > box > button:disabled {
|
||
/* Change player side buttons insensitive */
|
||
}
|
||
|
||
/* Buttons widget */
|
||
.widget-buttons-grid {
|
||
padding: 8px;
|
||
margin: 8px;
|
||
border-radius: 12px;
|
||
background-color: @noti-bg;
|
||
}
|
||
|
||
.widget-buttons-grid > flowbox > flowboxchild > button {
|
||
background: @noti-bg;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
.widget-buttons-grid > flowbox > flowboxchild > button.toggle:checked {
|
||
/* style given to the active toggle button */
|
||
}
|
||
|
||
/* Menubar widget */
|
||
.widget-menubar > box > .menu-button-bar > button {
|
||
border: none;
|
||
background: transparent;
|
||
}
|
||
|
||
/* .AnyName { Name defined in config after #
|
||
background-color: @noti-bg;
|
||
padding: 8px;
|
||
margin: 8px;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
.AnyName>button {
|
||
background: transparent;
|
||
border: none;
|
||
}
|
||
|
||
.AnyName>button:hover {
|
||
background-color: @noti-bg-hover;
|
||
} */
|
||
.topbar-buttons > button {
|
||
/* Name defined in config after # */
|
||
border: none;
|
||
background: transparent;
|
||
}
|
||
|
||
/* Volume widget */
|
||
.widget-volume {
|
||
background-color: @noti-bg;
|
||
padding: 8px;
|
||
margin: 8px;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
.widget-volume > box > button {
|
||
background: transparent;
|
||
border: none;
|
||
}
|
||
|
||
.per-app-volume {
|
||
background-color: @noti-bg-alt;
|
||
padding: 4px 8px 8px 8px;
|
||
margin: 0px 8px 8px 8px;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
/* Backlight widget */
|
||
.widget-backlight {
|
||
background-color: @noti-bg;
|
||
padding: 8px;
|
||
margin: 8px;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
/* Inhibitors widget */
|
||
.widget-inhibitors {
|
||
margin: 8px;
|
||
font-size: 1.5rem;
|
||
}
|
||
|
||
.widget-inhibitors > button {
|
||
font-size: initial;
|
||
color: @text-color;
|
||
text-shadow: none;
|
||
background: @noti-bg;
|
||
border: 1px solid @noti-border-color;
|
||
box-shadow: none;
|
||
border-radius: 12px;
|
||
}
|
||
|
||
.widget-inhibitors > button:hover {
|
||
background: @noti-bg-hover;
|
||
}
|
||
#+END_SRC
|
||
|
||
** xfce4-notifyd
|
||
|
||
*** Control Script
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle xfce4-notifyd/.scripts/xfce4-notifyd.sh
|
||
help_menu() {
|
||
echo "Script to interact with xfce4-notifyd. Use only one argument at a time."
|
||
echo " - Toggle Notification Center: xfce4-notifyd.sh --toggle-center"
|
||
echo " - Pause Popup Notifications: xfce4-notifyd.sh --pause"
|
||
echo " - Unpause Popup Notifications: xfce4-notifyd.sh --unpause"
|
||
echo " - Rofi Menu: xfce4-notifyd.sh --rofi"
|
||
echo " - Help: xfce4-notifyd.sh --help OR xfce4-notifyd.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" Toggle Notification Center - toggle-center"
|
||
" Pause Popup Notifications - pause"
|
||
" Unpause Popup Notifications - unpause"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--toggle-center)
|
||
xfce4-notifyd-config
|
||
;;
|
||
--pause)
|
||
notify-send "Pausing Notifications"
|
||
|
||
xfconf-query -c xfce4-notifyd -p /do-not-disturb -s true
|
||
;;
|
||
--unpause)
|
||
xfconf-query -c xfce4-notifyd -p /do-not-disturb -s false
|
||
|
||
notify-send "Unpausing Notifications"
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
* Application Launcher
|
||
|
||
** Rofi
|
||
|
||
*** Configuration
|
||
|
||
#+BEGIN_SRC css :tangle rofi/.config/rofi/config.rasi
|
||
configuration {
|
||
modi: "combi";
|
||
/* width: 50;*/
|
||
/* lines: 15;*/
|
||
/* columns: 1;*/
|
||
font: "NotoSans Nerd Font 12";
|
||
/* bw: 1;*/
|
||
/* location: 0;*/
|
||
/* padding: 5;*/
|
||
/* yoffset: 0;*/
|
||
/* xoffset: 0;*/
|
||
/* fixed-num-lines: true;*/
|
||
show-icons: true;
|
||
terminal: "kitty";
|
||
/* ssh-client: "ssh";*/
|
||
/* ssh-command: "{terminal} -e {ssh-client} {host} [-p {port}]";*/
|
||
/* run-command: "{cmd}";*/
|
||
/* run-list-command: "";*/
|
||
/* run-shell-command: "{terminal} -e {cmd}";*/
|
||
/* window-command: "wmctrl -i -R {window}";*/
|
||
/* window-match-fields: "all";*/
|
||
icon-theme: "Papirus-Dark";
|
||
/* drun-match-fields: "name,generic,exec,categories";*/
|
||
/* drun-show-actions: false;*/
|
||
/* drun-display-format: "{name} [<span weight='light' size='small'><i>({generic})</i></span>]";*/
|
||
/* disable-history: false;*/
|
||
/* ignored-prefixes: "";*/
|
||
/* sort: false;*/
|
||
/* sorting-method: ;*/
|
||
/* case-sensitive: false;*/
|
||
/* cycle: true;*/
|
||
sidebar-mode: false;
|
||
/* eh: 1;*/
|
||
/* auto-select: false;*/
|
||
/* parse-hosts: false;*/
|
||
/* parse-known-hosts: true;*/
|
||
combi-modi: "window,drun";
|
||
/* matching: "normal";*/
|
||
/* tokenize: true;*/
|
||
/* m: "-5";*/
|
||
/* line-margin: 2;*/
|
||
/* line-padding: 1;*/
|
||
/* filter: ;*/
|
||
/* separator-style: "dash";*/
|
||
/* hide-scrollbar: false;*/
|
||
/* fullscreen: false;*/
|
||
/* fake-transparency: false;*/
|
||
/* dpi: -1;*/
|
||
/* threads: 0;*/
|
||
/* scrollbar-width: 8;*/
|
||
/* scroll-method: 0;*/
|
||
/* fake-background: "screenshot";*/
|
||
/* window-format: "{w} {c} {t}";*/
|
||
/* click-to-exit: true;*/
|
||
/* show-match: true;*/
|
||
/* color-normal: ;*/
|
||
/* color-urgent: ;*/
|
||
/* color-active: ;*/
|
||
/* color-window: ;*/
|
||
/* max-history-size: 25;*/
|
||
/* combi-hide-mode-prefix: false;*/
|
||
/* matching-negate-char: '-' /* unsupported */;*/
|
||
/* cache-dir: ;*/
|
||
/* pid: "/run/user/1000/rofi.pid";*/
|
||
display-window: "window";
|
||
/* display-windowcd: ;*/
|
||
display-run: "execute";
|
||
/* display-ssh: ;*/
|
||
display-drun: "launch";
|
||
display-combi: "combi";
|
||
/* display-keys: ;*/
|
||
/* kb-primary-paste: "Control+V,Shift+Insert";*/
|
||
/* kb-secondary-paste: "Control+v,Insert";*/
|
||
/* kb-clear-line: "Control+w";*/
|
||
/* kb-move-front: "Control+a";*/
|
||
/* kb-move-end: "Control+e";*/
|
||
/* kb-move-word-back: "Alt+b,Control+Left";*/
|
||
/* kb-move-word-forward: "Alt+f,Control+Right";*/
|
||
/* kb-move-char-back: "Left,Control+b";*/
|
||
/* kb-move-char-forward: "Right,Control+f";*/
|
||
/* kb-remove-word-back: "Control+Alt+h,Control+BackSpace";*/
|
||
/* kb-remove-word-forward: "Control+Alt+d";*/
|
||
/* kb-remove-char-forward: "Delete,Control+d";*/
|
||
kb-remove-char-back: "BackSpace";
|
||
kb-remove-to-eol: "Control+Shift+e";
|
||
/* kb-remove-to-sol: "Control+u";*/
|
||
kb-accept-entry: "Control+m,Return,KP_Enter";
|
||
/* kb-accept-custom: "Control+Return";*/
|
||
/* kb-accept-alt: "Shift+Return";*/
|
||
/* kb-delete-entry: "Shift+Delete";*/
|
||
kb-mode-next: "Shift+Right,Control+Tab";
|
||
kb-mode-previous: "Shift+Left";
|
||
/* kb-row-left: "Control+Page_Up";*/
|
||
/* kb-row-right: "Control+Page_Down";*/
|
||
kb-row-up: "Up,Control+k,Control+p";
|
||
kb-row-down: "Down,Control+j,Control+n";
|
||
/* kb-row-tab: "Tab";*/
|
||
/* kb-page-prev: "Page_Up";*/
|
||
/* kb-page-next: "Page_Down";*/
|
||
/* kb-row-first: "Home,KP_Home";*/
|
||
/* kb-row-last: "End,KP_End";*/
|
||
/* kb-row-select: "Control+space";*/
|
||
/* kb-screenshot: "Alt+S";*/
|
||
/* kb-ellipsize: "Alt+period";*/
|
||
/* kb-toggle-case-sensitivity: "grave,dead_grave";*/
|
||
/* kb-toggle-sort: "Alt+grave";*/
|
||
/* kb-cancel: "Escape,Control+g,Control+bracketleft";*/
|
||
/* kb-custom-1: "Alt+1";*/
|
||
/* kb-custom-2: "Alt+2";*/
|
||
/* kb-custom-3: "Alt+3";*/
|
||
/* kb-custom-4: "Alt+4";*/
|
||
/* kb-custom-5: "Alt+5";*/
|
||
/* kb-custom-6: "Alt+6";*/
|
||
/* kb-custom-7: "Alt+7";*/
|
||
/* kb-custom-8: "Alt+8";*/
|
||
/* kb-custom-9: "Alt+9";*/
|
||
/* kb-custom-10: "Alt+0";*/
|
||
/* kb-custom-11: "Alt+exclam";*/
|
||
/* kb-custom-12: "Alt+at";*/
|
||
/* kb-custom-13: "Alt+numbersign";*/
|
||
/* kb-custom-14: "Alt+dollar";*/
|
||
/* kb-custom-15: "Alt+percent";*/
|
||
/* kb-custom-16: "Alt+dead_circumflex";*/
|
||
/* kb-custom-17: "Alt+ampersand";*/
|
||
/* kb-custom-18: "Alt+asterisk";*/
|
||
/* kb-custom-19: "Alt+parenleft";*/
|
||
/* kb-select-1: "Super+1";*/
|
||
/* kb-select-2: "Super+2";*/
|
||
/* kb-select-3: "Super+3";*/
|
||
/* kb-select-4: "Super+4";*/
|
||
/* kb-select-5: "Super+5";*/
|
||
/* kb-select-6: "Super+6";*/
|
||
/* kb-select-7: "Super+7";*/
|
||
/* kb-select-8: "Super+8";*/
|
||
/* kb-select-9: "Super+9";*/
|
||
/* kb-select-10: "Super+0";*/
|
||
/* ml-row-left: "ScrollLeft";*/
|
||
/* ml-row-right: "ScrollRight";*/
|
||
/* ml-row-up: "ScrollUp";*/
|
||
/* ml-row-down: "ScrollDown";*/
|
||
/* me-select-entry: "MousePrimary";*/
|
||
/* me-accept-entry: "MouseDPrimary";*/
|
||
/* me-accept-custom: "Control+MouseDPrimary";*/
|
||
}
|
||
|
||
@theme "centertab-dracula"
|
||
#+END_SRC
|
||
|
||
*** Themes
|
||
|
||
**** Centertab Dracula
|
||
|
||
#+BEGIN_SRC css :tangle rofi/.config/rofi/themes/centertab-dracula.rasi
|
||
/**
|
||
,* ROFI Color theme: centertab-dracula
|
||
,* User: balajsra
|
||
,* Copyright: deadguy & Sravan Balaji
|
||
,*/
|
||
|
||
,* {
|
||
background-color: #282a36ff;
|
||
text-color: #f8f8f2ff;
|
||
selbg: #8be9fdff;
|
||
actbg: #44475aff;
|
||
urgbg: #ff5555ff;
|
||
winbg: #8be9fdff;
|
||
|
||
normal-foreground: @text-color;
|
||
normal-background: @background-color;
|
||
|
||
selected-normal-foreground: @winbg;
|
||
selected-normal-background: @actbg;
|
||
|
||
urgent-foreground: @text-color;
|
||
urgent-background: @background-color;
|
||
|
||
selected-urgent-foreground: @background-color;
|
||
selected-urgent-background: @urgbg;
|
||
|
||
active-foreground: @background-color;
|
||
active-background: @selbg;
|
||
|
||
selected-active-foreground: @winbg;
|
||
selected-active-background: @actbg;
|
||
|
||
line-margin: 2;
|
||
line-padding: 2;
|
||
separator-style: "none";
|
||
hide-scrollbar: "true";
|
||
margin: 0;
|
||
padding: 0;
|
||
}
|
||
|
||
window {
|
||
location: south west;
|
||
anchor: south west;
|
||
height: calc(100% - 45px);
|
||
width: 700;
|
||
x-offset: 10;
|
||
y-offset: -10;
|
||
orientation: horizontal;
|
||
children: [mainbox];
|
||
border: 2;
|
||
border-color: @winbg;
|
||
border-radius: 10;
|
||
transparency: "real";
|
||
}
|
||
|
||
mainbox {
|
||
spacing: 0.8em;
|
||
children: [ entry, listview, mode-switcher ];
|
||
}
|
||
|
||
button {
|
||
padding: 5px 2px;
|
||
}
|
||
|
||
button selected {
|
||
background-color: @active-background;
|
||
text-color: @background-color;
|
||
}
|
||
|
||
inputbar {
|
||
padding: 5px;
|
||
spacing: 5px;
|
||
}
|
||
|
||
listview {
|
||
spacing: 0.5em;
|
||
dynamic: false;
|
||
cycle: true;
|
||
}
|
||
|
||
element {
|
||
padding: 10px;
|
||
}
|
||
|
||
element-icon {
|
||
size: 2.00ch;
|
||
}
|
||
|
||
entry {
|
||
expand: false;
|
||
text-color: @normal-foreground;
|
||
vertical-align: 1;
|
||
padding: 5px;
|
||
}
|
||
|
||
element normal.normal {
|
||
background-color: @normal-background;
|
||
text-color: @normal-foreground;
|
||
}
|
||
|
||
element normal.urgent {
|
||
background-color: @urgent-background;
|
||
text-color: @urgent-foreground;
|
||
}
|
||
|
||
element normal.active {
|
||
background-color: @active-background;
|
||
text-color: @active-foreground;
|
||
}
|
||
|
||
element selected.normal {
|
||
background-color: @selected-normal-background;
|
||
text-color: @selected-normal-foreground;
|
||
border: 0 5px solid 0 0;
|
||
border-color: @active-background;
|
||
}
|
||
|
||
element selected.urgent {
|
||
background-color: @selected-urgent-background;
|
||
text-color: @selected-urgent-foreground;
|
||
}
|
||
|
||
element selected.active {
|
||
background-color: @selected-active-background;
|
||
text-color: @selected-active-foreground;
|
||
}
|
||
|
||
element alternate.normal {
|
||
background-color: @normal-background;
|
||
text-color: @normal-foreground;
|
||
}
|
||
|
||
element alternate.urgent {
|
||
background-color: @urgent-background;
|
||
text-color: @urgent-foreground;
|
||
}
|
||
|
||
element alternate.active {
|
||
background-color: @active-background;
|
||
text-color: @active-foreground;
|
||
}
|
||
|
||
element-text {
|
||
background-color: inherit;
|
||
text-color: inherit;
|
||
}
|
||
|
||
element-icon {
|
||
background-color: inherit;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Dmenu Dracula
|
||
|
||
#+BEGIN_SRC css :tangle rofi/.config/rofi/themes/dmenu-dracula.rasi
|
||
/**
|
||
,* ROFI Color theme: dmenu-dracula
|
||
,* User: balajsra
|
||
,* Copyright: Sravan Balaji
|
||
,*/
|
||
|
||
,* {
|
||
background-color: #282a36;
|
||
text-color: #f8f8f2;
|
||
font: "NotoSans Nerd Font 12";
|
||
}
|
||
|
||
#window {
|
||
anchor: north;
|
||
location: north;
|
||
width: 100%;
|
||
padding: 2px 5px 2px 5px; /* top right bottom left */
|
||
children: [ horibox ];
|
||
}
|
||
|
||
#horibox {
|
||
orientation: horizontal;
|
||
children: [ prompt, entry, listview ];
|
||
}
|
||
|
||
#listview {
|
||
layout: horizontal;
|
||
spacing: 10px;
|
||
lines: 100;
|
||
}
|
||
|
||
#entry {
|
||
expand: false;
|
||
width: 10em;
|
||
}
|
||
|
||
#element {
|
||
padding: 1px 5px 1px 5px; /* top right bottom left */
|
||
}
|
||
#element selected {
|
||
background-color: #bd93f9;
|
||
text-color: #282a36;
|
||
}
|
||
|
||
#element-text {
|
||
background-color: inherit;
|
||
text-color: inherit;
|
||
}
|
||
|
||
#element-icon {
|
||
background-color: inherit;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Blurry Full Dracula
|
||
|
||
#+BEGIN_SRC css :tangle rofi/.config/rofi/themes/dracula-blurry-full.rasi
|
||
/*
|
||
,*
|
||
,* Author : Aditya Shakya (adi1090x)
|
||
,* Mail : adi1090x@gmail.com
|
||
,* Github : @adi1090x
|
||
,* Reddit : @adi1090x
|
||
,*
|
||
,* Dracula Theme Colors : Sravan Balaji (balajsra)
|
||
,* Mail: balajsra@umich.edu
|
||
,* Github: @balajsra
|
||
,*/
|
||
|
||
configuration {
|
||
drun-display-format: "{name}";
|
||
threads: 0;
|
||
scroll-method: 0;
|
||
disable-history: false;
|
||
fullscreen: false;
|
||
hide-scrollbar: true;
|
||
sidebar-mode: false;
|
||
}
|
||
|
||
,* {
|
||
background: #00000000;
|
||
background-color: #282a36cc;
|
||
background-entry: #44475acc;
|
||
background-alt: #44475acc;
|
||
foreground: #f8f8f2cc;
|
||
foreground-selected: #50fa7bcc;
|
||
urgent: #ff5555cc;
|
||
urgent-selected: #ff5555cc;
|
||
}
|
||
|
||
window {
|
||
transparency: "real";
|
||
background-color: @background;
|
||
text-color: @foreground;
|
||
height: 100%;
|
||
width: 100%;
|
||
location: northwest;
|
||
anchor: northwest;
|
||
x-offset: 0;
|
||
y-offset: 0;
|
||
}
|
||
|
||
prompt {
|
||
enabled: false;
|
||
}
|
||
|
||
inputbar {
|
||
background-color: @background-alt;
|
||
text-color: @foreground;
|
||
expand: false;
|
||
border-radius: 6px;
|
||
margin: 0px 430px 0px 430px;
|
||
padding: 10px 10px 10px 10px;
|
||
position: north;
|
||
}
|
||
|
||
entry {
|
||
background-color: @background;
|
||
text-color: @foreground;
|
||
placeholder-color: @foreground;
|
||
expand: true;
|
||
horizontal-align: 0.5;
|
||
placeholder: "Search applications";
|
||
blink: true;
|
||
}
|
||
|
||
case-indicator {
|
||
background-color: @background;
|
||
text-color: @foreground;
|
||
spacing: 0;
|
||
}
|
||
|
||
listview {
|
||
background-color: @background;
|
||
columns: 7;
|
||
spacing: 4px;
|
||
cycle: false;
|
||
dynamic: true;
|
||
layout: vertical;
|
||
}
|
||
|
||
mainbox {
|
||
background-color: @background-color;
|
||
children: [ inputbar, listview ];
|
||
spacing: 25px;
|
||
padding: 70px 135px 55px 135px;
|
||
}
|
||
|
||
element {
|
||
background-color: @background;
|
||
text-color: @foreground;
|
||
orientation: vertical;
|
||
border-radius: 9px;
|
||
padding: 20px 0px 20px 0px;
|
||
}
|
||
|
||
element-icon {
|
||
background-color: inherit;
|
||
size: 65px;
|
||
border: 0px;
|
||
}
|
||
|
||
element-text {
|
||
background-color: inherit;
|
||
text-color: inherit;
|
||
expand: true;
|
||
horizontal-align: 0.5;
|
||
vertical-align: 0.5;
|
||
margin: 5px 10px 0px 10px;
|
||
}
|
||
|
||
element normal.urgent,
|
||
element alternate.urgent {
|
||
background-color: @urgent;
|
||
text-color: @foreground;
|
||
border-radius: 9px;
|
||
}
|
||
|
||
element normal.active,
|
||
element alternate.active {
|
||
background-color: @background-alt;
|
||
text-color: @foreground;
|
||
}
|
||
|
||
element selected {
|
||
background-color: @background-alt;
|
||
text-color: @foreground-selected;
|
||
}
|
||
|
||
element selected.urgent {
|
||
background-color: @urgent-selected;
|
||
text-color: @foreground;
|
||
}
|
||
|
||
element selected.active {
|
||
background-color: @background-alt;
|
||
color: @foreground-selected;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Official Dracula Theme
|
||
|
||
#+BEGIN_SRC css :tangle rofi/.config/rofi/themes/dracula.rasi
|
||
/*Dracula theme based on the Purple official rofi theme*/
|
||
|
||
,* {
|
||
font: "JetBrainsMono Nerd Font 12";
|
||
foreground: #f8f8f2;
|
||
background-color: #282a36;
|
||
active-background: #6272a4;
|
||
urgent-background: #ff5555;
|
||
selected-background: @active-background;
|
||
selected-urgent-background: @urgent-background;
|
||
selected-active-background: @active-background;
|
||
separatorcolor: @active-background;
|
||
bordercolor: @active-background;
|
||
}
|
||
|
||
#window {
|
||
background-color: @background;
|
||
border: 1;
|
||
border-radius: 6;
|
||
border-color: @bordercolor;
|
||
padding: 5;
|
||
}
|
||
#mainbox {
|
||
border: 0;
|
||
padding: 0;
|
||
}
|
||
#message {
|
||
border: 1px dash 0px 0px ;
|
||
border-color: @separatorcolor;
|
||
padding: 1px ;
|
||
}
|
||
#textbox {
|
||
text-color: @foreground;
|
||
}
|
||
#listview {
|
||
fixed-height: 0;
|
||
border: 2px dash 0px 0px ;
|
||
border-color: @bordercolor;
|
||
spacing: 2px ;
|
||
scrollbar: false;
|
||
padding: 2px 0px 0px ;
|
||
}
|
||
#element {
|
||
border: 0;
|
||
padding: 1px ;
|
||
}
|
||
#element.normal.normal {
|
||
background-color: @background;
|
||
text-color: @foreground;
|
||
}
|
||
#element.normal.urgent {
|
||
background-color: @urgent-background;
|
||
text-color: @urgent-foreground;
|
||
}
|
||
#element.normal.active {
|
||
background-color: @active-background;
|
||
text-color: @foreground;
|
||
}
|
||
#element.selected.normal {
|
||
background-color: @selected-background;
|
||
text-color: @foreground;
|
||
}
|
||
#element.selected.urgent {
|
||
background-color: @selected-urgent-background;
|
||
text-color: @foreground;
|
||
}
|
||
#element.selected.active {
|
||
background-color: @selected-active-background;
|
||
text-color: @foreground;
|
||
}
|
||
#element.alternate.normal {
|
||
background-color: @background;
|
||
text-color: @foreground;
|
||
}
|
||
#element.alternate.urgent {
|
||
background-color: @urgent-background;
|
||
text-color: @foreground;
|
||
}
|
||
#element.alternate.active {
|
||
background-color: @active-background;
|
||
text-color: @foreground;
|
||
}
|
||
#element-text {
|
||
background-color: inherit;
|
||
text-color: inherit;
|
||
}
|
||
#element-icon {
|
||
background-color: inherit;
|
||
}
|
||
#scrollbar {
|
||
width: 2px ;
|
||
border: 0;
|
||
handle-width: 8px ;
|
||
padding: 0;
|
||
}
|
||
#sidebar {
|
||
border: 2px dash 0px 0px ;
|
||
border-color: @separatorcolor;
|
||
}
|
||
#button.selected {
|
||
background-color: @selected-background;
|
||
text-color: @foreground;
|
||
}
|
||
#inputbar {
|
||
spacing: 0;
|
||
text-color: @foreground;
|
||
padding: 1px ;
|
||
}
|
||
#case-indicator {
|
||
spacing: 0;
|
||
text-color: @foreground;
|
||
}
|
||
#entry {
|
||
spacing: 0;
|
||
text-color: @foreground;
|
||
}
|
||
#prompt {
|
||
spacing: 0;
|
||
text-color: @foreground;
|
||
}
|
||
#inputbar {
|
||
children: [ prompt,textbox-prompt-colon,entry,case-indicator ];
|
||
}
|
||
#textbox-prompt-colon {
|
||
expand: false;
|
||
str: ":";
|
||
margin: 0px 0.3em 0em 0em ;
|
||
text-color: @foreground;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Sidetab Dracula
|
||
|
||
#+BEGIN_SRC css :tangle rofi/.config/rofi/themes/sidetab-dracula.rasi
|
||
/**
|
||
,* ROFI Color theme: sidetab-dracula
|
||
,* User: balajsra
|
||
,* Copyright: deadguy & Sravan Balaji
|
||
,*/
|
||
|
||
configuration {
|
||
display-drun: "Launch";
|
||
display-run: "Execute";
|
||
display-window: "Window";
|
||
show-icons: true;
|
||
sidebar-mode: true;
|
||
font: "NotoSans Nerd Font 12";
|
||
}
|
||
|
||
,* {
|
||
background-color: #282a36;
|
||
text-color: #f8f8f2;
|
||
selbg: #bd93f9;
|
||
actbg: #44475a;
|
||
urgbg: #ff5555;
|
||
winbg: #50fa7b;
|
||
|
||
selected-normal-foreground: @winbg;
|
||
normal-foreground: @text-color;
|
||
selected-normal-background: @actbg;
|
||
normal-background: @background-color;
|
||
|
||
selected-urgent-foreground: @background-color;
|
||
urgent-foreground: @text-color;
|
||
selected-urgent-background: @urgbg;
|
||
urgent-background: @background-color;
|
||
|
||
selected-active-foreground: @winbg;
|
||
active-foreground: @text-color;
|
||
selected-active-background: @actbg;
|
||
active-background: @selbg;
|
||
|
||
line-margin: 2;
|
||
line-padding: 2;
|
||
separator-style: "none";
|
||
hide-scrollbar: "true";
|
||
margin: 0;
|
||
padding: 0;
|
||
}
|
||
|
||
window {
|
||
location: west;
|
||
anchor: west;
|
||
height: 100%;
|
||
width: 25%;
|
||
orientation: horizontal;
|
||
children: [mainbox];
|
||
}
|
||
|
||
mainbox {
|
||
spacing: 0.8em;
|
||
children: [ entry, listview, mode-switcher ];
|
||
}
|
||
|
||
button {
|
||
padding: 5px 2px;
|
||
}
|
||
|
||
button selected {
|
||
background-color: @active-background;
|
||
text-color: @background-color;
|
||
}
|
||
|
||
inputbar {
|
||
padding: 5px;
|
||
spacing: 5px;
|
||
}
|
||
|
||
listview {
|
||
spacing: 0.5em;
|
||
dynamic: false;
|
||
cycle: true;
|
||
}
|
||
|
||
element {
|
||
padding: 10px;
|
||
}
|
||
|
||
entry {
|
||
expand: false;
|
||
text-color: @normal-foreground;
|
||
vertical-align: 1;
|
||
padding: 5px;
|
||
}
|
||
|
||
element normal.normal {
|
||
background-color: @normal-background;
|
||
text-color: @normal-foreground;
|
||
}
|
||
|
||
element normal.urgent {
|
||
background-color: @urgent-background;
|
||
text-color: @urgent-foreground;
|
||
}
|
||
|
||
element normal.active {
|
||
background-color: @active-background;
|
||
text-color: @active-foreground;
|
||
}
|
||
|
||
element selected.normal {
|
||
background-color: @selected-normal-background;
|
||
text-color: @selected-normal-foreground;
|
||
border: 0 5px solid 0 0;
|
||
border-color: @active-background;
|
||
}
|
||
|
||
element selected.urgent {
|
||
background-color: @selected-urgent-background;
|
||
text-color: @selected-urgent-foreground;
|
||
}
|
||
|
||
element selected.active {
|
||
background-color: @selected-active-background;
|
||
text-color: @selected-active-foreground;
|
||
}
|
||
|
||
element alternate.normal {
|
||
background-color: @normal-background;
|
||
text-color: @normal-foreground;
|
||
}
|
||
|
||
element alternate.urgent {
|
||
background-color: @urgent-background;
|
||
text-color: @urgent-foreground;
|
||
}
|
||
|
||
element alternate.active {
|
||
background-color: @active-background;
|
||
text-color: @active-foreground;
|
||
}
|
||
|
||
element-text {
|
||
background-color: inherit;
|
||
text-color: inherit;
|
||
}
|
||
|
||
element-icon {
|
||
background-color: inherit;
|
||
}
|
||
#+END_SRC
|
||
|
||
**** Slate Dracula
|
||
|
||
#+BEGIN_SRC css :tangle rofi/.config/rofi/themes/slate-dracula.rasi
|
||
/**
|
||
,* ROFI Color theme: slate-dracula
|
||
,* User: balajsra
|
||
,* Copyright: Sravan Balaji
|
||
,*/
|
||
|
||
,* {
|
||
background-color: #282a36;
|
||
border-color: #bd93f9;
|
||
text-color: #f8f8f2;
|
||
spacing: 0;
|
||
width: 1024px;
|
||
font: "NotoSans Nerd Font 12";
|
||
}
|
||
|
||
inputbar {
|
||
border: 0 0 1px 0; /* top right bottom left */
|
||
children: [prompt, entry];
|
||
}
|
||
|
||
prompt {
|
||
padding: 16px;
|
||
border: 2px 1px 0 2px; /* top right bottom left */
|
||
}
|
||
|
||
textbox {
|
||
background-color: #282a36;
|
||
border: 0 0 1px 0; /* top right bottom left */
|
||
border-color: #bd93f9;
|
||
padding: 8px 16px 8px 16px; /* top right bottom left */
|
||
}
|
||
|
||
entry {
|
||
border: 2px 2px 0px 0; /* top right bottom left */
|
||
padding: 16px;
|
||
}
|
||
|
||
listview {
|
||
cycle: true;
|
||
margin: 0 0 0px 0; /* top right bottom left */
|
||
scrollbar: true;
|
||
}
|
||
|
||
element {
|
||
border: 0 2px 1px 2px; /* top right bottom left */
|
||
padding: 16px;
|
||
}
|
||
|
||
element selected {
|
||
background-color: #44475a;
|
||
}
|
||
|
||
element-text {
|
||
background-color: inherit;
|
||
text-color: inherit;
|
||
}
|
||
|
||
element-icon {
|
||
background-color: inherit;
|
||
}
|
||
#+END_SRC
|
||
|
||
*** Greenclip Clipboard Manager
|
||
|
||
#+BEGIN_SRC toml :tangle rofi/.config/greenclip.toml
|
||
[greenclip]
|
||
history_file = "~/.cache/greenclip.history"
|
||
max_history_length = 50
|
||
max_selection_size_bytes = 0
|
||
trim_space_from_selection = true
|
||
use_primary_selection_as_input = false
|
||
blacklisted_applications = []
|
||
enable_image_support = true
|
||
image_cache_directory = "/tmp/greenclip"
|
||
static_history = [
|
||
'''¯\_(ツ)_/¯''',
|
||
]
|
||
#+END_SRC
|
||
|
||
** Fuzzel
|
||
|
||
*** Main
|
||
|
||
#+BEGIN_SRC conf :tangle fuzzel/.config/fuzzel/fuzzel.ini
|
||
[main]
|
||
# output=<not set>
|
||
font=NotoSans Nerd Font:size=14
|
||
dpi-aware=auto
|
||
prompt="> "
|
||
icon-theme=Papirus-Dark
|
||
icons-enabled=yes
|
||
fields=filename,name,generic,exec,categories,keywords,comment
|
||
password-character=*
|
||
filter-desktop=no
|
||
match-mode=fzf
|
||
show-actions=yes
|
||
terminal=kitty
|
||
# launch-prefix=<not set>
|
||
list-executables-in-path=no
|
||
|
||
anchor=left
|
||
lines=25
|
||
width=50
|
||
tabs=4
|
||
horizontal-pad=10
|
||
vertical-pad=10
|
||
inner-pad=10
|
||
|
||
image-size-ratio=0.25
|
||
|
||
# line-height=<use font metrics>
|
||
# letter-spacing=0
|
||
|
||
layer = overlay
|
||
exit-on-keyboard-focus-loss = yes
|
||
#+END_SRC
|
||
|
||
*** Colors
|
||
|
||
#+BEGIN_SRC conf :tangle fuzzel/.config/fuzzel/fuzzel.ini
|
||
[colors]
|
||
background=282a36ff
|
||
text=f8f8f2ff
|
||
prompt=8be9fdff
|
||
input=f8f8f2ff
|
||
match=8be9fdff
|
||
selection=44475aff
|
||
selection-text=f8f8f2ff
|
||
selection-match=8be9fdff
|
||
border=8be9fdff
|
||
#+END_SRC
|
||
|
||
*** Border
|
||
|
||
#+BEGIN_SRC conf :tangle fuzzel/.config/fuzzel/fuzzel.ini
|
||
[border]
|
||
width=2
|
||
radius=0
|
||
#+END_SRC
|
||
|
||
*** dmenu
|
||
|
||
#+BEGIN_SRC conf :tangle fuzzel/.config/fuzzel/fuzzel.ini
|
||
[dmenu]
|
||
mode=text # text|index
|
||
exit-immediately-if-empty=no
|
||
#+END_SRC
|
||
|
||
*** Key Bindings
|
||
|
||
#+BEGIN_SRC conf :tangle fuzzel/.config/fuzzel/fuzzel.ini
|
||
[key-bindings]
|
||
cancel=Escape
|
||
execute=Return KP_Enter
|
||
execute-or-next=none
|
||
execute-input=Shift+Return Shift+KP_Enter
|
||
cursor-left=Left Control+h
|
||
cursor-left-word=none
|
||
cursor-right=Right Control+l
|
||
cursor-right-word=none
|
||
cursor-home=none
|
||
cursor-end=none
|
||
delete-prev=BackSpace
|
||
delete-prev-word=none
|
||
delete-line-backward=Control+u
|
||
delete-next=Delete KP_Delete
|
||
delete-next-word=none
|
||
delete-line-forward=Control+k
|
||
prev=none
|
||
prev-with-wrap=Up Control+p
|
||
prev-page=Page_Up KP_Page_Up
|
||
next=none
|
||
next-with-wrap=Down Control+n
|
||
next-page=Page_Down KP_Page_Down
|
||
|
||
# custom-N: *dmenu mode only*. Like execute, but with a non-zero
|
||
# exit-code; custom-1 exits with code 10, custom-2 with 11, custom-3
|
||
# with 12, and so on.
|
||
|
||
# custom-1=Mod1+1
|
||
# custom-2=Mod1+2
|
||
# custom-3=Mod1+3
|
||
# custom-4=Mod1+4
|
||
# custom-5=Mod1+5
|
||
# custom-6=Mod1+6
|
||
# custom-7=Mod1+7
|
||
# custom-8=Mod1+8
|
||
# custom-9=Mod1+9
|
||
# custom-10=Mod1+0
|
||
# custom-11=Mod1+exclam
|
||
# custom-12=Mod1+at
|
||
# custom-13=Mod1+numbersign
|
||
# custom-14=Mod1+dollar
|
||
# custom-15=Mod1+percent
|
||
# custom-16=Mod1+dead_circumflex
|
||
# custom-17=Mod1+ampersand
|
||
# custom-18=Mod1+asterix
|
||
# custom-19=Mod1+parentleft
|
||
#+END_SRC
|
||
|
||
* Display Configuration & Effects
|
||
|
||
** X11 Monitor Setup
|
||
|
||
*** Xrandr
|
||
|
||
Below is an example script for setting up displays using ~xrandr~ with desired resolution, position, and refresh rate.
|
||
|
||
Use ~xrandr~ command to see available displays, resolutions, and refresh rates
|
||
|
||
| Flag | Description |
|
||
|-----------+--------------------------------------------------------------------------------------------------------------------------|
|
||
| ~--output~ | Specify which display to configure |
|
||
| ~--primary~ | Indicate which display is the primary display |
|
||
| ~--mode~ | Set display resolution (get available options from ~xrandr~ command) |
|
||
| ~--pos~ | Set display position (0x0 is top left, so 5120x1440 is an x-offset of 5120px to the right and a y-offset of 1440px down) |
|
||
| ~--rate~ | Set display refresh rate (get available options from ~xrandr~ command) |
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle xrandr/.scripts/monitor_setup.sh
|
||
xrandr \
|
||
--output DP-2 --primary --mode 2560x1440 --pos 0x0 --rate 164.96 \
|
||
--output DP-0 --mode 2560x1440 --pos 2560x0 --rate 164.96 \
|
||
--output eDP-1-1 --mode 1920x1080 --pos 5120x1440 --rate 144.00
|
||
#+END_SRC
|
||
|
||
*** Autorandr
|
||
|
||
See [[https://github.com/phillipberndt/autorandr#hook-scripts][autorandr hook scripts]] for more information.
|
||
|
||
**** Post Switch
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle autorandr/.config/autorandr/postswitch
|
||
# Check if screen is not currently locked
|
||
if ! pgrep -x "i3lock" > /dev/null
|
||
then
|
||
# Restart session
|
||
$HOME/.scripts/session.sh --restart &
|
||
fi
|
||
|
||
# Disable & Re-Enable Compositor
|
||
$HOME/.scripts/picom.sh --on &
|
||
|
||
# NVIDIA Force Composition Pipeline
|
||
/usr/bin/nvidia-force-comp-pipeline &
|
||
|
||
# Restore wallpaper
|
||
/usr/bin/nitrogen --restore &
|
||
|
||
# Update lock screen wallpaper
|
||
/usr/bin/betterlockscreen -u \
|
||
$HOME/Data/NextCloud/Wallpapers/Desktop/Solar_System.png &
|
||
#+END_SRC
|
||
|
||
*** Compositor
|
||
|
||
**** Picom
|
||
|
||
***** Shadows
|
||
|
||
#+BEGIN_SRC conf :tangle picom/.config/picom/picom.conf
|
||
# Enabled client-side shadows on windows. Note desktop windows
|
||
# (windows with '_NET_WM_WINDOW_TYPE_DESKTOP') never get shadow,
|
||
# unless explicitly requested using the wintypes option.
|
||
#
|
||
# shadow = false
|
||
shadow = false;
|
||
|
||
# The blur radius for shadows, in pixels. (defaults to 12)
|
||
# shadow-radius = 12
|
||
shadow-radius = 7;
|
||
|
||
# The opacity of shadows. (0.0 - 1.0, defaults to 0.75)
|
||
# shadow-opacity = .75
|
||
|
||
# The left offset for shadows, in pixels. (defaults to -15)
|
||
# shadow-offset-x = -15
|
||
shadow-offset-x = -7;
|
||
|
||
# The top offset for shadows, in pixels. (defaults to -15)
|
||
# shadow-offset-y = -15
|
||
shadow-offset-y = -7;
|
||
|
||
# Avoid drawing shadows on dock/panel windows. This option is deprecated,
|
||
# you should use the *wintypes* option in your config file instead.
|
||
#
|
||
# no-dock-shadow = false
|
||
|
||
# Don't draw shadows on drag-and-drop windows. This option is deprecated,
|
||
# you should use the *wintypes* option in your config file instead.
|
||
#
|
||
# no-dnd-shadow = false
|
||
|
||
# Red color value of shadow (0.0 - 1.0, defaults to 0).
|
||
# shadow-red = 0
|
||
|
||
# Green color value of shadow (0.0 - 1.0, defaults to 0).
|
||
# shadow-green = 0
|
||
|
||
# Blue color value of shadow (0.0 - 1.0, defaults to 0).
|
||
# shadow-blue = 0
|
||
|
||
# Do not paint shadows on shaped windows. Note shaped windows
|
||
# here means windows setting its shape through X Shape extension.
|
||
# Those using ARGB background is beyond our control.
|
||
# Deprecated, use
|
||
# shadow-exclude = 'bounding_shaped'
|
||
# or
|
||
# shadow-exclude = 'bounding_shaped && !rounded_corners'
|
||
# instead.
|
||
#
|
||
# shadow-ignore-shaped = ''
|
||
|
||
# Specify a list of conditions of windows that should have no shadow.
|
||
#
|
||
# examples:
|
||
# shadow-exclude = "n:e:Notification";
|
||
#
|
||
# shadow-exclude = []
|
||
shadow-exclude = [
|
||
# "name = 'Notification'",
|
||
# "class_g = 'Conky'",
|
||
# "class_g ?= 'Notify-osd'",
|
||
# "class_g = 'Cairo-clock'",
|
||
# "class_g = 'slop'",
|
||
# "class_g = 'Polybar'",
|
||
# "_GTK_FRAME_EXTENTS@:c"
|
||
];
|
||
|
||
# Specify a X geometry that describes the region in which shadow should not
|
||
# be painted in, such as a dock window region. Use
|
||
# shadow-exclude-reg = "x10+0+0"
|
||
# for example, if the 10 pixels on the bottom of the screen should not have shadows painted on.
|
||
#
|
||
# shadow-exclude-reg = ""
|
||
|
||
# Crop shadow of a window fully on a particular Xinerama screen to the screen.
|
||
# xinerama-shadow-crop = false
|
||
#+END_SRC
|
||
|
||
***** Fading
|
||
|
||
#+BEGIN_SRC conf :tangle picom/.config/picom/picom.conf
|
||
# Fade windows in/out when opening/closing and when opacity changes,
|
||
# unless no-fading-openclose is used.
|
||
fading = true;
|
||
|
||
# Opacity change between steps while fading in. (0.01 - 1.0, defaults to 0.028)
|
||
fade-in-step = 0.028;
|
||
|
||
# Opacity change between steps while fading out. (0.01 - 1.0, defaults to 0.03)
|
||
fade-out-step = 0.028;
|
||
|
||
# The time between steps in fade step, in milliseconds. (> 0, defaults to 10)
|
||
fade-delta = 3
|
||
|
||
# Specify a list of conditions of windows that should not be faded.
|
||
# don't need this, we disable fading for all normal windows with wintypes: {}
|
||
fade-exclude = [
|
||
# "class_g = 'slop'" # maim
|
||
]
|
||
|
||
# Do not fade on window open/close.
|
||
no-fading-openclose = false
|
||
|
||
# Do not fade destroyed ARGB windows with WM frame. Workaround of bugs in Openbox, Fluxbox, etc.
|
||
# no-fading-destroyed-argb = false
|
||
#+END_SRC
|
||
|
||
***** Transparency / Opacity
|
||
|
||
#+BEGIN_SRC conf :tangle picom/.config/picom/picom.conf
|
||
# Opacity of inactive windows. (0.1 - 1.0, defaults to 1.0)
|
||
inactive-opacity = 1.0
|
||
|
||
# Opacity of window titlebars and borders. (0.1 - 1.0, disabled by default)
|
||
frame-opacity = 1.0
|
||
|
||
# Let inactive opacity set by -i override the '_NET_WM_OPACITY' values of windows.
|
||
inactive-opacity-override = false;
|
||
|
||
# Default opacity for active windows. (0.0 - 1.0, defaults to 1.0)
|
||
active-opacity = 1.0;
|
||
|
||
# Dim inactive windows. (0.0 - 1.0, defaults to 0.0)
|
||
inactive-dim = 0.0
|
||
|
||
# Specify a list of conditions of windows that should always be considered focused.
|
||
focus-exclude = [
|
||
# "class_g = 'Cairo-clock'",
|
||
# "class_g = 'Bar'", # lemonbar
|
||
# "class_g = 'slop'" # maim
|
||
];
|
||
|
||
# Use fixed inactive dim value, instead of adjusting according to window opacity.
|
||
# inactive-dim-fixed = 1.0
|
||
|
||
# Specify a list of opacity rules, in the format `PERCENT:PATTERN`,
|
||
# like `50:name *= "Firefox"`. picom-trans is recommended over this.
|
||
# Note we don't make any guarantee about possible conflicts with other
|
||
# programs that set '_NET_WM_WINDOW_OPACITY' on frame or client windows.
|
||
# example:
|
||
# opacity-rule = [ "80:class_g = 'URxvt'" ];
|
||
#
|
||
# opacity-rule = []
|
||
opacity-rule = [
|
||
# "80:class_g = 'Bar'", # lemonbar
|
||
# "100:class_g = 'slop'", # maim
|
||
# "100:class_g = 'XTerm'",
|
||
# "100:class_g = 'URxvt'",
|
||
# "100:class_g = 'kitty'",
|
||
# "100:class_g = 'Alacritty'",
|
||
# "80:class_g = 'Polybar'",
|
||
# "100:class_g = 'code-oss'",
|
||
# "100:class_g = 'Meld'",
|
||
# "70:class_g = 'TelegramDesktop'",
|
||
# "90:class_g = 'Joplin'",
|
||
# "100:class_g = 'firefox'",
|
||
# "100:class_g = 'Thunderbird'"
|
||
];
|
||
#+END_SRC
|
||
|
||
***** Corners
|
||
|
||
#+BEGIN_SRC conf :tangle picom/.config/picom/picom.conf
|
||
# Sets the radius of rounded window corners. When > 0, the compositor will
|
||
# round the corners of windows. Does not interact well with
|
||
# `transparent-clipping`.
|
||
corner-radius = 10.0;
|
||
|
||
# Exclude conditions for rounded corners.
|
||
rounded-corners-exclude = [
|
||
"class_g = 'Polybar'",
|
||
"class_g = 'Rofi'",
|
||
"class_g = 'Deadd-notification-center'",
|
||
];
|
||
#+END_SRC
|
||
|
||
***** Background Blurring
|
||
|
||
#+BEGIN_SRC conf :tangle picom/.config/picom/picom.conf
|
||
# Parameters for background blurring, see the *BLUR* section for more information.
|
||
blur-method = "dual_kawase";
|
||
# blur-size = 12
|
||
# blur-deviation = false
|
||
blur-strength = 7;
|
||
|
||
# Blur background of semi-transparent / ARGB windows.
|
||
# Bad in performance, with driver-dependent behavior.
|
||
# The name of the switch may change without prior notifications.
|
||
blur-background = false;
|
||
|
||
# Blur background of windows when the window frame is not opaque.
|
||
# Implies:
|
||
# blur-background
|
||
# Bad in performance, with driver-dependent behavior. The name may change.
|
||
|
||
blur-background-frame = false;
|
||
|
||
|
||
# Use fixed blur strength rather than adjusting according to window opacity.
|
||
blur-background-fixed = false;
|
||
|
||
|
||
# Specify the blur convolution kernel, with the following format:
|
||
# example:
|
||
# blur-kern = "5,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1";
|
||
blur-kern = "3x3box";
|
||
|
||
|
||
# Exclude conditions for background blur.
|
||
blur-background-exclude = [
|
||
#"window_type = 'dock'",
|
||
#"window_type = 'desktop'",
|
||
#"class_g = 'URxvt'",
|
||
#
|
||
# prevents picom from blurring the background
|
||
# when taking selection screenshot with `main`
|
||
# https://github.com/naelstrof/maim/issues/130
|
||
"class_g = 'peek'",
|
||
"class_g = 'Peek'",
|
||
"class_g = 'slop'",
|
||
"class_g = 'zoom'",
|
||
"_GTK_FRAME_EXTENTS@:c"
|
||
];
|
||
#+END_SRC
|
||
|
||
***** General Settings
|
||
|
||
#+BEGIN_SRC conf :tangle picom/.config/picom/picom.conf
|
||
# Enable remote control via D-Bus. See the man page for more details.
|
||
# dbus = true
|
||
|
||
# Daemonize process. Fork to background after initialization. Causes issues with certain (badly-written) drivers.
|
||
# daemon = false
|
||
|
||
# Specify the backend to use: `xrender`, `glx`, `egl` or `xr_glx_hybrid`.
|
||
# `xrender` is the default one.
|
||
#
|
||
# backend = "glx"
|
||
backend = "glx";
|
||
|
||
# Use higher precision during rendering, and apply dither when presenting the
|
||
# rendered screen. Reduces banding artifacts, but might cause performance
|
||
# degradation. Only works with OpenGL.
|
||
dithered-present = false;
|
||
|
||
# Enable/disable VSync.
|
||
# vsync = false
|
||
vsync = true;
|
||
|
||
# Try to detect WM windows (a non-override-redirect window with no
|
||
# child that has 'WM_STATE') and mark them as active.
|
||
#
|
||
# mark-wmwin-focused = false
|
||
mark-wmwin-focused = true;
|
||
|
||
# Mark override-redirect windows that doesn't have a child window with 'WM_STATE' focused.
|
||
# mark-ovredir-focused = false
|
||
mark-ovredir-focused = true;
|
||
|
||
# Try to detect windows with rounded corners and don't consider them
|
||
# shaped windows. The accuracy is not very high, unfortunately.
|
||
#
|
||
# detect-rounded-corners = false
|
||
detect-rounded-corners = true;
|
||
|
||
# Detect '_NET_WM_WINDOW_OPACITY' on client windows, useful for window managers
|
||
# not passing '_NET_WM_WINDOW_OPACITY' of client windows to frame windows.
|
||
#
|
||
# detect-client-opacity = false
|
||
detect-client-opacity = true;
|
||
|
||
# Use EWMH '_NET_ACTIVE_WINDOW' to determine currently focused window,
|
||
# rather than listening to 'FocusIn'/'FocusOut' event. Might have more accuracy,
|
||
# provided that the WM supports it.
|
||
#
|
||
# use-ewmh-active-win = false
|
||
|
||
# Unredirect all windows if a full-screen opaque window is detected,
|
||
# to maximize performance for full-screen windows. Known to cause flickering
|
||
# when redirecting/unredirecting windows.
|
||
#
|
||
# unredir-if-possible = false
|
||
|
||
# Delay before unredirecting the window, in milliseconds. Defaults to 0.
|
||
# unredir-if-possible-delay = 0
|
||
|
||
# Conditions of windows that shouldn't be considered full-screen for unredirecting screen.
|
||
# unredir-if-possible-exclude = []
|
||
|
||
# Use 'WM_TRANSIENT_FOR' to group windows, and consider windows
|
||
# in the same group focused at the same time.
|
||
#
|
||
# detect-transient = false
|
||
detect-transient = true;
|
||
|
||
# Use 'WM_CLIENT_LEADER' to group windows, and consider windows in the same
|
||
# group focused at the same time. This usually means windows from the same application
|
||
# will be considered focused or unfocused at the same time.
|
||
# 'WM_TRANSIENT_FOR' has higher priority if detect-transient is enabled, too.
|
||
#
|
||
# detect-client-leader = false
|
||
|
||
# Resize damaged region by a specific number of pixels.
|
||
# A positive value enlarges it while a negative one shrinks it.
|
||
# If the value is positive, those additional pixels will not be actually painted
|
||
# to screen, only used in blur calculation, and such. (Due to technical limitations,
|
||
# with use-damage, those pixels will still be incorrectly painted to screen.)
|
||
# Primarily used to fix the line corruption issues of blur,
|
||
# in which case you should use the blur radius value here
|
||
# (e.g. with a 3x3 kernel, you should use `--resize-damage 1`,
|
||
# with a 5x5 one you use `--resize-damage 2`, and so on).
|
||
# May or may not work with *--glx-no-stencil*. Shrinking doesn't function correctly.
|
||
#
|
||
# resize-damage = 1
|
||
|
||
# Specify a list of conditions of windows that should be painted with inverted color.
|
||
# Resource-hogging, and is not well tested.
|
||
#
|
||
# invert-color-include = []
|
||
|
||
# GLX backend: Avoid using stencil buffer, useful if you don't have a stencil buffer.
|
||
# Might cause incorrect opacity when rendering transparent content (but never
|
||
# practically happened) and may not work with blur-background.
|
||
# My tests show a 15% performance boost. Recommended.
|
||
#
|
||
glx-no-stencil = true;
|
||
|
||
# GLX backend: Avoid rebinding pixmap on window damage.
|
||
# Probably could improve performance on rapid window content changes,
|
||
# but is known to break things on some drivers (LLVMpipe, xf86-video-intel, etc.).
|
||
# Recommended if it works.
|
||
#
|
||
# glx-no-rebind-pixmap = false
|
||
|
||
# Disable the use of damage information.
|
||
# This cause the whole screen to be redrawn every time, instead of the part of the screen
|
||
# has actually changed. Potentially degrades the performance, but might fix some artifacts.
|
||
# The opposing option is use-damage
|
||
#
|
||
# no-use-damage = false
|
||
use-damage = false;
|
||
|
||
# Use X Sync fence to sync clients' draw calls, to make sure all draw
|
||
# calls are finished before picom starts drawing. Needed on nvidia-drivers
|
||
# with GLX backend for some users.
|
||
#
|
||
# xrender-sync-fence = false
|
||
|
||
# GLX backend: Use specified GLSL fragment shader for rendering window
|
||
# contents. Read the man page for a detailed explanation of the interface.
|
||
#
|
||
# window-shader-fg = "default"
|
||
|
||
# Use rules to set per-window shaders. Syntax is SHADER_PATH:PATTERN, similar
|
||
# to opacity-rule. SHADER_PATH can be "default". This overrides window-shader-fg.
|
||
#
|
||
# window-shader-fg-rule = [
|
||
# "my_shader.frag:window_type != 'dock'"
|
||
# ]
|
||
|
||
# Force all windows to be painted with blending. Useful if you
|
||
# have a glx-fshader-win that could turn opaque pixels transparent.
|
||
#
|
||
# force-win-blend = false
|
||
|
||
# Do not use EWMH to detect fullscreen windows.
|
||
# Reverts to checking if a window is fullscreen based only on its size and coordinates.
|
||
#
|
||
# no-ewmh-fullscreen = false
|
||
|
||
# Dimming bright windows so their brightness doesn't exceed this set value.
|
||
# Brightness of a window is estimated by averaging all pixels in the window,
|
||
# so this could comes with a performance hit.
|
||
# Setting this to 1.0 disables this behaviour. Requires --use-damage to be disabled. (default: 1.0)
|
||
#
|
||
# max-brightness = 1.0
|
||
|
||
# Make transparent windows clip other windows like non-transparent windows do,
|
||
# instead of blending on top of them.
|
||
#
|
||
# transparent-clipping = false
|
||
|
||
# Specify a list of conditions of windows that should never have transparent
|
||
# clipping applied. Useful for screenshot tools, where you need to be able to
|
||
# see through transparent parts of the window.
|
||
#
|
||
# transparent-clipping-exclude = []
|
||
|
||
# Set the log level. Possible values are:
|
||
# "trace", "debug", "info", "warn", "error"
|
||
# in increasing level of importance. Case doesn't matter.
|
||
# If using the "TRACE" log level, it's better to log into a file
|
||
# using *--log-file*, since it can generate a huge stream of logs.
|
||
#
|
||
# log-level = "debug"
|
||
log-level = "warn";
|
||
|
||
# Set the log file.
|
||
# If *--log-file* is never specified, logs will be written to stderr.
|
||
# Otherwise, logs will to written to the given file, though some of the early
|
||
# logs might still be written to the stderr.
|
||
# When setting this option from the config file, it is recommended to use an absolute path.
|
||
#
|
||
# log-file = "/path/to/your/log/file"
|
||
|
||
# Show all X errors (for debugging)
|
||
# show-all-xerrors = false
|
||
|
||
# Write process ID to a file.
|
||
# write-pid-path = "/path/to/your/log/file"
|
||
|
||
# Window type settings
|
||
#
|
||
# 'WINDOW_TYPE' is one of the 15 window types defined in EWMH standard:
|
||
# "unknown", "desktop", "dock", "toolbar", "menu", "utility",
|
||
# "splash", "dialog", "normal", "dropdown_menu", "popup_menu",
|
||
# "tooltip", "notification", "combo", and "dnd".
|
||
#
|
||
# Following per window-type options are available: ::
|
||
#
|
||
# fade, shadow:::
|
||
# Controls window-type-specific shadow and fade settings.
|
||
#
|
||
# opacity:::
|
||
# Controls default opacity of the window type.
|
||
#
|
||
# focus:::
|
||
# Controls whether the window of this type is to be always considered focused.
|
||
# (By default, all window types except "normal" and "dialog" has this on.)
|
||
#
|
||
# full-shadow:::
|
||
# Controls whether shadow is drawn under the parts of the window that you
|
||
# normally won't be able to see. Useful when the window has parts of it
|
||
# transparent, and you want shadows in those areas.
|
||
#
|
||
# clip-shadow-above:::
|
||
# Controls whether shadows that would have been drawn above the window should
|
||
# be clipped. Useful for dock windows that should have no shadow painted on top.
|
||
#
|
||
# redir-ignore:::
|
||
# Controls whether this type of windows should cause screen to become
|
||
# redirected again after been unredirected. If you have unredir-if-possible
|
||
# set, and doesn't want certain window to cause unnecessary screen redirection,
|
||
# you can set this to `true`.
|
||
#
|
||
wintypes:
|
||
{
|
||
tooltip = { fade = true; shadow = true; opacity = 1.0; focus = true; full-shadow = false; };
|
||
dock = { shadow = false; clip-shadow-above = true; }
|
||
dnd = { shadow = false; }
|
||
popup_menu = { opacity = 1.0; }
|
||
dropdown_menu = { opacity = 1.0; }
|
||
};
|
||
#+END_SRC
|
||
|
||
***** Control Script
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle picom/.scripts/picom.sh
|
||
help_menu() {
|
||
echo "Script to interact with picom. Use only one argument at a time."
|
||
echo " - Toggle On/Off: picom.sh OR picom.sh --toggle OR picom.sh -t"
|
||
echo " - Turn On: picom.sh --on"
|
||
echo " - Turn Off: picom.sh --off"
|
||
echo " - Help: picom.sh --help OR picom.sh -h"
|
||
}
|
||
|
||
is_running() {
|
||
if pgrep -x picom >/dev/null; then
|
||
echo 1
|
||
else
|
||
echo 0
|
||
fi
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
"⏼ Toggle - toggle"
|
||
" Turn On - on"
|
||
" Turn Off - off"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--toggle)
|
||
if [ $(is_running) -eq '1' ]; then
|
||
main --off
|
||
else
|
||
main --on
|
||
fi
|
||
;;
|
||
--on)
|
||
if [ $(is_running) -eq '1' ]; then
|
||
pkill picom
|
||
fi
|
||
|
||
picom --config $HOME/.config/picom/picom.conf -b
|
||
|
||
notify-send "Turning Picom ON"
|
||
;;
|
||
--off)
|
||
if [ $(is_running) -eq '1' ]; then
|
||
pkill picom
|
||
fi
|
||
|
||
notify-send "Turning Picom OFF"
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
*** Night Light
|
||
|
||
**** Geoclue
|
||
|
||
***** Agent Service
|
||
|
||
#+BEGIN_SRC systemd :tangle geoclue/.config/systemd/user/geoclue-agent.service
|
||
[Unit]
|
||
Description=Night light applications need to get a (geo)clue
|
||
|
||
[Service]
|
||
ExecStart=/usr/libexec/geoclue-2.0/demos/agent
|
||
|
||
[Install]
|
||
WantedBy=default.target
|
||
#+END_SRC
|
||
|
||
**** Redshift
|
||
|
||
***** Configuration
|
||
|
||
#+BEGIN_SRC conf :tangle redshift/.config/redshift/redshift.conf
|
||
; Global settings for redshift
|
||
[redshift]
|
||
; Set the day and night screen temperatures
|
||
temp-day=6500
|
||
temp-night=3500
|
||
|
||
; Enable/Disable a smooth transition between day and night
|
||
; 0 will cause a direct change from day to night screen temperature.
|
||
; 1 will gradually increase or decrease the screen temperature.
|
||
transition=1
|
||
|
||
; Set the screen brightness. Default is 1.0.
|
||
;brightness=0.9
|
||
; It is also possible to use different settings for day and night
|
||
; since version 1.8.
|
||
;brightness-day=0.7
|
||
;brightness-night=0.4
|
||
; Set the screen gamma (for all colors, or each color channel
|
||
; individually)
|
||
; gamma=0.8
|
||
;gamma=0.8:0.7:0.8
|
||
; This can also be set individually for day and night since
|
||
; version 1.10.
|
||
;gamma-day=0.8:0.7:0.8
|
||
;gamma-night=0.6
|
||
|
||
; Set the location-provider: 'geoclue', 'geoclue2', 'manual'
|
||
; type 'redshift -l list' to see possible values.
|
||
; The location provider settings are in a different section.
|
||
location-provider=geoclue2
|
||
|
||
; Set the adjustment-method: 'randr', 'vidmode'
|
||
; type 'redshift -m list' to see all possible values.
|
||
; 'randr' is the preferred method, 'vidmode' is an older API.
|
||
; but works in some cases when 'randr' does not.
|
||
; The adjustment method settings are in a different section.
|
||
adjustment-method=randr
|
||
|
||
; Configuration of the location-provider:
|
||
; type 'redshift -l PROVIDER:help' to see the settings.
|
||
; ex: 'redshift -l manual:help'
|
||
; Keep in mind that longitudes west of Greenwich (e.g. the Americas)
|
||
; are negative numbers.
|
||
; [manual]
|
||
; lat=xxxx
|
||
; lon=xxx
|
||
|
||
; Configuration of the adjustment-method
|
||
; type 'redshift -m METHOD:help' to see the settings.
|
||
; ex: 'redshift -m randr:help'
|
||
; In this example, randr is configured to adjust screen 1.
|
||
; Note that the numbering starts from 0, so this is actually the
|
||
; second screen. If this option is not specified, Redshift will try
|
||
; to adjust _all_ screens.
|
||
; [randr]
|
||
; screen=1
|
||
#+END_SRC
|
||
|
||
**** Gammastep
|
||
|
||
***** Configuration
|
||
|
||
#+BEGIN_SRC conf :tangle gammastep/.config/gammastep/config.ini
|
||
; Global settings
|
||
[general]
|
||
; Set the day and night screen temperatures
|
||
temp-day=6500
|
||
temp-night=3500
|
||
|
||
; Disable the smooth fade between temperatures when Redshift starts and stops.
|
||
; 0 will cause an immediate change between screen temperatures.
|
||
; 1 will gradually apply the new screen temperature over a couple of seconds.
|
||
fade=1
|
||
|
||
; Solar elevation thresholds.
|
||
; By default, Redshift will use the current elevation of the sun to determine
|
||
; whether it is daytime, night or in transition (dawn/dusk). When the sun is
|
||
; above the degrees specified with elevation-high it is considered daytime and
|
||
; below elevation-low it is considered night.
|
||
;elevation-high=3
|
||
;elevation-low=-6
|
||
|
||
; Custom dawn/dusk intervals.
|
||
; Instead of using the solar elevation, the time intervals of dawn and dusk
|
||
; can be specified manually. The times must be specified as HH:MM in 24-hour
|
||
; format.
|
||
;dawn-time=6:00-7:45
|
||
;dusk-time=18:35-20:15
|
||
|
||
; Set the screen brightness. Default is 1.0.
|
||
;brightness=0.9
|
||
; It is also possible to use different settings for day and night
|
||
; since version 1.8.
|
||
;brightness-day=0.7
|
||
;brightness-night=0.4
|
||
; Set the screen gamma (for all colors, or each color channel
|
||
; individually)
|
||
;gamma=0.8
|
||
;gamma=0.8:0.7:0.8
|
||
; This can also be set individually for day and night since
|
||
; version 1.10.
|
||
;gamma-day=0.8:0.7:0.8
|
||
;gamma-night=0.6
|
||
|
||
; Set the location-provider: 'geoclue2', 'manual'.
|
||
; The location provider settings are in a different section.
|
||
location-provider=geoclue2
|
||
|
||
; Set the adjustment-method: 'randr', 'vidmode', 'drm', 'wayland'.
|
||
; 'randr' is the preferred X11 method, 'vidmode' is an older API
|
||
; that works in some cases when 'randr' does not.
|
||
; The adjustment method settings are in a different section.
|
||
adjustment-method=randr
|
||
|
||
; Configuration of the location-provider:
|
||
; type 'gammastep -l PROVIDER:help' to see the settings.
|
||
; ex: 'gammastep -l manual:help'
|
||
; Keep in mind that longitudes west of Greenwich (e.g. the Americas)
|
||
; are negative numbers.
|
||
;[manual]
|
||
;lat=48.1
|
||
;lon=11.6
|
||
|
||
; Configuration of the adjustment-method
|
||
; type 'gammastep -m METHOD:help' to see the settings.
|
||
; ex: 'gammastep -m randr:help'
|
||
; In this example, randr is configured to adjust only screen 0.
|
||
; Note that the numbering starts from 0, so this is actually the first screen.
|
||
; If this option is not specified, Redshift will try to adjust _all_ screens.
|
||
;[randr]
|
||
;screen=0
|
||
#+END_SRC
|
||
|
||
*** Lock Screen
|
||
|
||
**** Betterlockscreen
|
||
|
||
***** Default Options
|
||
|
||
#+BEGIN_SRC conf :tangle betterlockscreen/.config/betterlockscreen/betterlockscreenrc
|
||
display_on=0
|
||
span_image=false
|
||
lock_timeout=300
|
||
fx_list=(dim blur dimblur pixel dimpixel color)
|
||
dim_level=40
|
||
blur_level=1
|
||
pixel_scale=10,1000
|
||
solid_color=333333
|
||
wallpaper_cmd="feh --bg-fill"
|
||
# i3lockcolor_bin="i3lock-color" # Manually set command for i3lock-color
|
||
#+END_SRC
|
||
|
||
***** Theme Options
|
||
|
||
#+BEGIN_SRC conf :tangle betterlockscreen/.config/betterlockscreen/betterlockscreenrc
|
||
loginbox=282a36ff
|
||
loginshadow=282a36ff
|
||
locktext="Enter password to unlock..."
|
||
font="sans-serif"
|
||
ringcolor=44475aff
|
||
insidecolor=00000000
|
||
separatorcolor=00000000
|
||
ringvercolor=50fa7bff
|
||
insidevercolor=50fa7bff
|
||
ringwrongcolor=ff5555ff
|
||
insidewrongcolor=ff5555ff
|
||
timecolor=f8f8f2ff
|
||
time_format="%X"
|
||
greetercolor=f8f8f2ff
|
||
layoutcolor=f8f8f2ff
|
||
keyhlcolor=bd93f9ff
|
||
bshlcolor=8be9fdff
|
||
verifcolor=50fa7bff
|
||
wrongcolor=ff5555ff
|
||
modifcolor=ff5555ff
|
||
bgcolor=282a36ff
|
||
#+END_SRC
|
||
|
||
***** Pre-Lock
|
||
|
||
#+BEGIN_SRC conf :tangle betterlockscreen/.config/betterlockscreen/betterlockscreenrc
|
||
prelock() {
|
||
$HOME/.scripts/dunst.sh --pause
|
||
}
|
||
#+END_SRC
|
||
|
||
***** Post-Lock
|
||
|
||
#+BEGIN_SRC conf :tangle betterlockscreen/.config/betterlockscreen/betterlockscreenrc
|
||
# custom postlock
|
||
postlock() {
|
||
$HOME/.scripts/dunst.sh --unpause
|
||
}
|
||
#+END_SRC
|
||
|
||
** Wayland Monitor Setup
|
||
|
||
*** Shikane
|
||
|
||
**** Docked
|
||
|
||
#+BEGIN_SRC toml :tangle shikane/.config/shikane/config.toml
|
||
[[profile]]
|
||
name = "docked"
|
||
exec = ["notify-send shikane \"Profile $SHIKANE_PROFILE_NAME has been applied\""]
|
||
|
||
[[profile.output]]
|
||
enable = false
|
||
search = ["m=0x0625", "s=", "v=LG Display"]
|
||
|
||
[[profile.output]]
|
||
enable = true
|
||
search = ["m=LG ULTRAGEAR", "s=305MXUN80518", "v=LG Electronics"]
|
||
mode = "2560x1440@143.933Hz"
|
||
position = "0,0"
|
||
scale = 1.0
|
||
transform = "normal"
|
||
adaptive_sync = false
|
||
|
||
[[profile.output]]
|
||
enable = true
|
||
search = ["m=LG ULTRAGEAR", "s=112NTTQC0153", "v=LG Electronics"]
|
||
mode = "2560x1440@164.956Hz"
|
||
position = "2560,0"
|
||
scale = 1.0
|
||
transform = "normal"
|
||
adaptive_sync = false
|
||
|
||
[[profile.output]]
|
||
enable = true
|
||
search = ["m=LG ULTRAGEAR", "s=111NTUWM4574", "v=LG Electronics"]
|
||
mode = "2560x1440@164.956Hz"
|
||
position = "5120,0"
|
||
scale = 1.0
|
||
transform = "normal"
|
||
adaptive_sync = false
|
||
#+END_SRC
|
||
|
||
**** Mobile
|
||
|
||
#+BEGIN_SRC toml :tangle shikane/.config/shikane/config.toml
|
||
[[profile]]
|
||
name = "mobile"
|
||
exec = ["notify-send shikane \"Profile $SHIKANE_PROFILE_NAME has been applied\""]
|
||
|
||
[[profile.output]]
|
||
enable = true
|
||
search = ["m=0x0625", "s=", "v=LG Display"]
|
||
mode = "1920x1080@143.998Hz"
|
||
position = "0,0"
|
||
scale = 1.0
|
||
transform = "normal"
|
||
adaptive_sync = false
|
||
#+END_SRC
|
||
|
||
*** Lock Screen
|
||
|
||
**** Swaylock
|
||
|
||
#+BEGIN_SRC conf :tangle swaylock/.config/swaylock/config
|
||
ignore-empty-password
|
||
font=Ubuntu
|
||
|
||
clock
|
||
timestr=%T
|
||
datestr=%a, %x
|
||
|
||
screenshots
|
||
|
||
fade-in=0
|
||
|
||
effect-blur=20x3
|
||
effect-scale=1.0
|
||
|
||
indicator
|
||
indicator-radius=240
|
||
indicator-thickness=20
|
||
indicator-caps-lock
|
||
|
||
key-hl-color=bd93f9
|
||
|
||
separator-color=00000000
|
||
|
||
inside-color=44475aff
|
||
inside-clear-color=ffd20400
|
||
inside-caps-lock-color=009ddc00
|
||
inside-ver-color=d9d8d800
|
||
inside-wrong-color=ee2e2400
|
||
|
||
ring-color=282a36ff
|
||
ring-clear-color=231f20D9
|
||
ring-caps-lock-color=231f20D9
|
||
ring-ver-color=50fa7bff
|
||
ring-wrong-color=ff5555ff
|
||
|
||
line-color=282a36ff
|
||
line-clear-color=ffd204FF
|
||
line-caps-lock-color=009ddcFF
|
||
line-ver-color=50fa7bff
|
||
line-wrong-color=ff5555ff
|
||
|
||
text-color=8be9fdff
|
||
text-clear-color=ffd20400
|
||
text-ver-color=50fa7bff
|
||
text-wrong-color=ff5555ff
|
||
|
||
bs-hl-color=ee2e24FF
|
||
caps-lock-key-hl-color=ffd204FF
|
||
caps-lock-bs-hl-color=ee2e24FF
|
||
disable-caps-lock-text
|
||
text-caps-lock-color=009ddc
|
||
#+END_SRC
|
||
|
||
* Command Line Interface
|
||
|
||
** Multiplexer
|
||
|
||
*** Tmux
|
||
|
||
**** Default Shell
|
||
|
||
Change default shell for tmux to use
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g default-shell /bin/fish
|
||
#+END_SRC
|
||
|
||
**** Prefix Key
|
||
|
||
Remap prefix from 'C-b' to 'C-a'
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
unbind C-b
|
||
set-option -g prefix C-a
|
||
bind-key C-a send-prefix
|
||
#+END_SRC
|
||
|
||
**** Split Commands
|
||
|
||
Split panes using '|' and '-'
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
bind | split-window -h
|
||
bind - split-window -v
|
||
unbind '"'
|
||
unbind %
|
||
#+END_SRC
|
||
|
||
**** Configuration Reload
|
||
|
||
Reload config file
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
bind r source-file ~/.tmux.conf
|
||
#+END_SRC
|
||
|
||
**** Pane Switching
|
||
|
||
Switch panes using Alt-arrow or Alt-hjkl without prefix
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
bind -n M-Left select-pane -L
|
||
bind -n M-h select-pane -L
|
||
|
||
bind -n M-Right select-pane -R
|
||
bind -n M-l select-pane -R
|
||
|
||
bind -n M-Up select-pane -U
|
||
bind -n M-k select-pane -U
|
||
|
||
bind -n M-Down select-pane -D
|
||
bind -n M-j select-pane -D
|
||
#+END_SRC
|
||
|
||
**** Mouse Mode
|
||
|
||
Enable mouse control (clickable windows, panes, resizable panes)
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g mouse on
|
||
#+END_SRC
|
||
|
||
**** Stop Renaming Windows Automatically
|
||
|
||
Don't rename windows automatically
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set-option -g allow-rename off
|
||
#+END_SRC
|
||
|
||
**** Setup Tmux Plugin Manager
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g @plugin 'tmux-plugins/tpm'
|
||
set -g @plugin 'tmux-plugins/tmux-sensible'
|
||
set -g @plugin 'dracula/tmux'
|
||
#+END_SRC
|
||
|
||
**** Dracula Theme
|
||
|
||
Install theme plugin. See [[https://draculatheme.com/tmux][Dracula Theme - Tmux]] for all options.
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g @plugin 'dracula/tmux'
|
||
#+END_SRC
|
||
|
||
Configure status bar modules. Available plugins are ~battery~, ~cpu-usage~, ~git~, ~gpu-usage~, ~ram-usage~, ~tmux-ram-usage~, ~network~, ~network-bandwidth~, ~network-ping~, ~ssh-session~, ~attached-clients~, ~network-vpn~, ~weather~, ~time~, ~mpc~, ~spotify-tui~, ~playerctl~, ~kubernetes-context~, ~synchronize-panes~.
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g @dracula-plugins "git cpu-usage ram-usage battery time"
|
||
#+END_SRC
|
||
|
||
Enable powerline symbols.
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g @dracula-show-powerline true
|
||
#+END_SRC
|
||
|
||
Enable window flags.
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g @dracula-show-flags true
|
||
#+END_SRC
|
||
|
||
Adjust the refresh rate of the status bar.
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g @dracula-refresh-rate 5
|
||
#+END_SRC
|
||
|
||
Switch the left smiley icon. It can accept ~hostname~ (full hostname), ~session~, ~shortname~, ~smiley~, ~window~, or any character.
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g @dracula-show-left-icon session
|
||
#+END_SRC
|
||
|
||
Hide empty modules.
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
set -g @dracula-show-empty-plugins false
|
||
#+END_SRC
|
||
|
||
**** Run Tmux Plugin Manager
|
||
|
||
#+BEGIN_SRC conf :tangle tmux/.tmux.conf
|
||
run -b '~/.tmux/plugins/tpm/tpm'
|
||
#+END_SRC
|
||
|
||
** Prompt
|
||
|
||
*** Starship
|
||
|
||
#+BEGIN_SRC toml :tangle starship/.config/starship.toml
|
||
format = """
|
||
[](#44475A)\
|
||
$directory\
|
||
[](fg:#44475A bg:#6272a4)\
|
||
$git_branch\
|
||
$git_status\
|
||
[](fg:#6272a4 bg:#BD93F9)\
|
||
$c\
|
||
$elixir\
|
||
$elm\
|
||
$golang\
|
||
$haskell\
|
||
$java\
|
||
$julia\
|
||
$nodejs\
|
||
$nim\
|
||
$rust\
|
||
[](fg:#BD93F9 bg:#FF79C6)\
|
||
$docker_context\
|
||
[](fg:#FF79C6 bg:#FF5555)\
|
||
$cmd_duration\
|
||
[](fg:#FF5555)\
|
||
\n$character
|
||
"""
|
||
|
||
# Enable/disable the blank line at the start of the prompt
|
||
add_newline = false
|
||
|
||
# Set timeout for commands
|
||
command_timeout = 1000
|
||
|
||
[character]
|
||
format = "$symbol"
|
||
success_symbol = "[ ❯❯❯](bold green) "
|
||
error_symbol = "[ ❯❯❯](bold red) "
|
||
|
||
# You can also replace your username with a neat symbol like to save some space
|
||
[username]
|
||
show_always = true
|
||
style_user = "bg:#44475A"
|
||
style_root = "bg:#44475A"
|
||
format = '[ ]($style)'
|
||
|
||
[directory]
|
||
style = "bg:#44475A"
|
||
format = "[ $path ]($style)"
|
||
truncation_length = 4
|
||
truncate_to_repo = true
|
||
truncation_symbol = "…/"
|
||
read_only = ""
|
||
|
||
# Here is how you can shorten some long paths by text replacement
|
||
# similar to mapped_locations in Oh My Posh:
|
||
[directory.substitutions]
|
||
"~" = " "
|
||
".config" = " "
|
||
"config" = " "
|
||
"Config" = " "
|
||
"Books" = " "
|
||
"Data" = " "
|
||
"Desktop" = " "
|
||
"Documents" = " "
|
||
"Finances" = " "
|
||
"Downloads" = " "
|
||
"Games" = " "
|
||
"Git" = " "
|
||
"PrismLauncher" = " "
|
||
"Steam" = " "
|
||
"ISOs" = " "
|
||
"Music" = " "
|
||
"Spotify" = " "
|
||
"Pictures" = " "
|
||
"Personal" = " "
|
||
"System" = " "
|
||
"Videos" = " "
|
||
"dropbox" = " "
|
||
"google-drive" = " "
|
||
"onedrive" = " "
|
||
"Attachments" = " "
|
||
# Keep in mind that the order matters. For example:
|
||
# "Important Documents" = " "
|
||
# will not be replaced, because "Documents" was already substituted before.
|
||
# So either put "Important Documents" before "Documents" or use the substituted version:
|
||
# "Important " = " "
|
||
|
||
[c]
|
||
symbol = " "
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[cmd_duration]
|
||
min_time = 0
|
||
style = "bg:#FF5555"
|
||
format = '[[ $duration ](bg:#FF5555)]($style)'
|
||
show_notifications = true
|
||
min_time_to_notify = 5_000
|
||
|
||
[docker_context]
|
||
symbol = " "
|
||
style = "bg:#FF79C6"
|
||
format = '[[ $symbol $context ](bg:#FF79C6)]($style) $path'
|
||
|
||
[elixir]
|
||
symbol = " "
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[elm]
|
||
symbol = " "
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[git_branch]
|
||
symbol = ""
|
||
style = "bg:#6272a4"
|
||
format = '[[ $symbol $branch ](bg:#6272a4)]($style)'
|
||
|
||
[git_status]
|
||
style = "bg:#6272a4"
|
||
format = '[[($all_status$ahead_behind )](bg:#6272a4)]($style)'
|
||
|
||
[golang]
|
||
symbol = " "
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[haskell]
|
||
symbol = " "
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[java]
|
||
symbol = " "
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[julia]
|
||
symbol = " "
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[nodejs]
|
||
symbol = ""
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[nim]
|
||
symbol = " "
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[rust]
|
||
symbol = ""
|
||
style = "bg:#BD93F9"
|
||
format = '[[ $symbol ($version) ](bg:#BD93F9)]($style)'
|
||
|
||
[time]
|
||
disabled = false
|
||
time_format = "%X" # Hour:Minute Format
|
||
style = "bg:#FFB86C"
|
||
format = '[[ $time ](bg:#FFB86C)]($style)'
|
||
#+END_SRC
|
||
|
||
** Shell
|
||
|
||
*** Bash
|
||
|
||
#+BEGIN_SRC shell :tangle bash/.bashrc
|
||
# ~/.bashrc: executed by bash(1) for non-login shells.
|
||
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
|
||
# for examples
|
||
|
||
# If not running interactively, don't do anything
|
||
case $- in
|
||
,*i*) ;;
|
||
,*) return ;;
|
||
esac
|
||
|
||
# don't put duplicate lines or lines starting with space in the history.
|
||
# See bash(1) for more options
|
||
HISTCONTROL=ignoreboth
|
||
|
||
# append to the history file, don't overwrite it
|
||
shopt -s histappend
|
||
|
||
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
|
||
HISTSIZE=1000
|
||
HISTFILESIZE=2000
|
||
|
||
# check the window size after each command and, if necessary,
|
||
# update the values of LINES and COLUMNS.
|
||
shopt -s checkwinsize
|
||
|
||
# If set, the pattern "**" used in a pathname expansion context will
|
||
# match all files and zero or more directories and subdirectories.
|
||
#shopt -s globstar
|
||
|
||
# make less more friendly for non-text input files, see lesspipe(1)
|
||
[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
|
||
|
||
# set variable identifying the chroot you work in (used in the prompt below)
|
||
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
|
||
debian_chroot=$(cat /etc/debian_chroot)
|
||
fi
|
||
|
||
# set a fancy prompt (non-color, unless we know we "want" color)
|
||
case "$TERM" in
|
||
xterm-color | *-256color) color_prompt=yes ;;
|
||
esac
|
||
|
||
# uncomment for a colored prompt, if the terminal has the capability; turned
|
||
# off by default to not distract the user: the focus in a terminal window
|
||
# should be on the output of commands, not on the prompt
|
||
#force_color_prompt=yes
|
||
|
||
if [ -n "$force_color_prompt" ]; then
|
||
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
|
||
# We have color support; assume it's compliant with Ecma-48
|
||
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
|
||
# a case would tend to support setf rather than setaf.)
|
||
color_prompt=yes
|
||
else
|
||
color_prompt=
|
||
fi
|
||
fi
|
||
|
||
if [ "$color_prompt" = yes ]; then
|
||
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
|
||
else
|
||
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
|
||
fi
|
||
unset color_prompt force_color_prompt
|
||
|
||
# If this is an xterm set the title to user@host:dir
|
||
case "$TERM" in
|
||
xterm* | rxvt*)
|
||
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
|
||
;;
|
||
,*) ;;
|
||
|
||
esac
|
||
|
||
# enable color support of ls and also add handy aliases
|
||
if [ -x /usr/bin/dircolors ]; then
|
||
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
|
||
alias ls='ls --color=auto'
|
||
#alias dir='dir --color=auto'
|
||
#alias vdir='vdir --color=auto'
|
||
|
||
alias grep='grep --color=auto'
|
||
alias fgrep='fgrep --color=auto'
|
||
alias egrep='egrep --color=auto'
|
||
fi
|
||
|
||
# colored GCC warnings and errors
|
||
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
|
||
|
||
# some more ls aliases
|
||
alias ll='ls -alF'
|
||
alias la='ls -A'
|
||
alias l='ls -CF'
|
||
|
||
# Add an "alert" alias for long running commands. Use like so:
|
||
# sleep 10; alert
|
||
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
|
||
|
||
# Alias definitions.
|
||
# You may want to put all your additions into a separate file like
|
||
# ~/.bash_aliases, instead of adding them here directly.
|
||
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
|
||
|
||
if [ -f ~/.bash_aliases ]; then
|
||
. ~/.bash_aliases
|
||
fi
|
||
|
||
# enable programmable completion features (you don't need to enable
|
||
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
|
||
# sources /etc/bash.bashrc).
|
||
if ! shopt -oq posix; then
|
||
if [ -f /usr/share/bash-completion/bash_completion ]; then
|
||
. /usr/share/bash-completion/bash_completion
|
||
elif [ -f /etc/bash_completion ]; then
|
||
. /etc/bash_completion
|
||
fi
|
||
fi
|
||
|
||
# ENVIRONMENT VARIABLES
|
||
export EDITOR="emacs"
|
||
export TERM=xterm-256color
|
||
export QT_STYLE_OVERRIDE=kvantum
|
||
export XDG_CONFIG_HOME=$HOME/.config
|
||
|
||
# Greeting
|
||
clear
|
||
krabby random
|
||
echo "bash shell"
|
||
#+END_SRC
|
||
|
||
*** Zsh
|
||
|
||
#+BEGIN_SRC shell :tangle zsh/.zshrc
|
||
# If you come from bash you might have to change your $PATH.
|
||
# export PATH=$HOME/bin:/usr/local/bin:$PATH
|
||
|
||
# Set $PATH if ~/.local/bin exist
|
||
if [ -d "$HOME/.local/bin" ]; then
|
||
export PATH=$HOME/.local/bin:$PATH
|
||
fi
|
||
|
||
eval "$(starship init zsh)"
|
||
function set_win_title(){
|
||
echo -ne "\033]0; $USER@$HOST:${PWD/$HOME/~} \007"
|
||
}
|
||
precmd_functions+=(set_win_title)
|
||
|
||
## Plugins section: Enable fish style features
|
||
# Use syntax highlighting
|
||
source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
|
||
|
||
# Use autosuggestion
|
||
source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh
|
||
|
||
# Use history substring search
|
||
source /usr/share/zsh/plugins/zsh-history-substring-search/zsh-history-substring-search.zsh
|
||
|
||
# Use fzf
|
||
source /usr/share/fzf/key-bindings.zsh
|
||
source /usr/share/fzf/completion.zsh
|
||
|
||
# Arch Linux command-not-found support, you must have package pkgfile installed
|
||
# https://wiki.archlinux.org/index.php/Pkgfile#.22Command_not_found.22_hook
|
||
[[ -e /usr/share/doc/pkgfile/command-not-found.zsh ]] && source /usr/share/doc/pkgfile/command-not-found.zsh
|
||
|
||
|
||
## Options section
|
||
setopt correct # Auto correct mistakes
|
||
setopt extendedglob # Extended globbing. Allows using regular expressions with *
|
||
setopt nocaseglob # Case insensitive globbing
|
||
setopt rcexpandparam # Array expension with parameters
|
||
setopt nocheckjobs # Don't warn about running processes when exiting
|
||
setopt numericglobsort # Sort filenames numerically when it makes sense
|
||
setopt nobeep # No beep
|
||
setopt appendhistory # Immediately append history instead of overwriting
|
||
setopt histignorealldups # If a new command is a duplicate, remove the older one
|
||
setopt autocd # if only directory path is entered, cd there.
|
||
setopt auto_pushd
|
||
setopt pushd_ignore_dups
|
||
setopt pushdminus
|
||
|
||
# Completion.
|
||
autoload -Uz compinit
|
||
compinit
|
||
zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}' # Case insensitive tab completion
|
||
zstyle ':completion:*' rehash true # automatically find new executables in path
|
||
zstyle ':completion:*' list-colors "${(s.:.)LS_COLORS}" # Colored completion (different colors for dirs/files/etc)
|
||
zstyle ':completion:*' completer _expand _complete _ignored _approximate
|
||
zstyle ':completion:*' menu select=2
|
||
zstyle ':completion:*' select-prompt '%SScrolling active: current selection at %p%s'
|
||
zstyle ':completion:*:descriptions' format '%U%F{cyan}%d%f%u'
|
||
|
||
# Speed up completions
|
||
zstyle ':completion:*' accept-exact '*(N)'
|
||
zstyle ':completion:*' use-cache on
|
||
zstyle ':completion:*' cache-path ~/.cache/zcache
|
||
|
||
# automatically load bash completion functions
|
||
autoload -U +X bashcompinit && bashcompinit
|
||
|
||
HISTFILE=~/.zhistory
|
||
HISTSIZE=50000
|
||
SAVEHIST=10000
|
||
|
||
|
||
## Keys
|
||
# Use emacs key bindings
|
||
bindkey -e
|
||
|
||
# [PageUp] - Up a line of history
|
||
if [[ -n "${terminfo[kpp]}" ]]; then
|
||
bindkey -M emacs "${terminfo[kpp]}" up-line-or-history
|
||
bindkey -M viins "${terminfo[kpp]}" up-line-or-history
|
||
bindkey -M vicmd "${terminfo[kpp]}" up-line-or-history
|
||
fi
|
||
# [PageDown] - Down a line of history
|
||
if [[ -n "${terminfo[knp]}" ]]; then
|
||
bindkey -M emacs "${terminfo[knp]}" down-line-or-history
|
||
bindkey -M viins "${terminfo[knp]}" down-line-or-history
|
||
bindkey -M vicmd "${terminfo[knp]}" down-line-or-history
|
||
fi
|
||
|
||
# Start typing + [Up-Arrow] - fuzzy find history forward
|
||
if [[ -n "${terminfo[kcuu1]}" ]]; then
|
||
autoload -U up-line-or-beginning-search
|
||
zle -N up-line-or-beginning-search
|
||
|
||
bindkey -M emacs "${terminfo[kcuu1]}" up-line-or-beginning-search
|
||
bindkey -M viins "${terminfo[kcuu1]}" up-line-or-beginning-search
|
||
bindkey -M vicmd "${terminfo[kcuu1]}" up-line-or-beginning-search
|
||
fi
|
||
# Start typing + [Down-Arrow] - fuzzy find history backward
|
||
if [[ -n "${terminfo[kcud1]}" ]]; then
|
||
autoload -U down-line-or-beginning-search
|
||
zle -N down-line-or-beginning-search
|
||
|
||
bindkey -M emacs "${terminfo[kcud1]}" down-line-or-beginning-search
|
||
bindkey -M viins "${terminfo[kcud1]}" down-line-or-beginning-search
|
||
bindkey -M vicmd "${terminfo[kcud1]}" down-line-or-beginning-search
|
||
fi
|
||
|
||
# [Home] - Go to beginning of line
|
||
if [[ -n "${terminfo[khome]}" ]]; then
|
||
bindkey -M emacs "${terminfo[khome]}" beginning-of-line
|
||
bindkey -M viins "${terminfo[khome]}" beginning-of-line
|
||
bindkey -M vicmd "${terminfo[khome]}" beginning-of-line
|
||
fi
|
||
# [End] - Go to end of line
|
||
if [[ -n "${terminfo[kend]}" ]]; then
|
||
bindkey -M emacs "${terminfo[kend]}" end-of-line
|
||
bindkey -M viins "${terminfo[kend]}" end-of-line
|
||
bindkey -M vicmd "${terminfo[kend]}" end-of-line
|
||
fi
|
||
|
||
# [Shift-Tab] - move through the completion menu backwards
|
||
if [[ -n "${terminfo[kcbt]}" ]]; then
|
||
bindkey -M emacs "${terminfo[kcbt]}" reverse-menu-complete
|
||
bindkey -M viins "${terminfo[kcbt]}" reverse-menu-complete
|
||
bindkey -M vicmd "${terminfo[kcbt]}" reverse-menu-complete
|
||
fi
|
||
|
||
# [Backspace] - delete backward
|
||
bindkey -M emacs '^?' backward-delete-char
|
||
bindkey -M viins '^?' backward-delete-char
|
||
bindkey -M vicmd '^?' backward-delete-char
|
||
# [Delete] - delete forward
|
||
if [[ -n "${terminfo[kdch1]}" ]]; then
|
||
bindkey -M emacs "${terminfo[kdch1]}" delete-char
|
||
bindkey -M viins "${terminfo[kdch1]}" delete-char
|
||
bindkey -M vicmd "${terminfo[kdch1]}" delete-char
|
||
else
|
||
bindkey -M emacs "^[[3~" delete-char
|
||
bindkey -M viins "^[[3~" delete-char
|
||
bindkey -M vicmd "^[[3~" delete-char
|
||
|
||
bindkey -M emacs "^[3;5~" delete-char
|
||
bindkey -M viins "^[3;5~" delete-char
|
||
bindkey -M vicmd "^[3;5~" delete-char
|
||
fi
|
||
|
||
# Greeting
|
||
clear
|
||
krabby random
|
||
echo "zsh shell"
|
||
#+END_SRC
|
||
|
||
*** Fish
|
||
|
||
**** Theme Selection
|
||
|
||
#+BEGIN_SRC fish :tangle fish/.config/fish/config.fish
|
||
fish_config theme choose "Dracula_Official"
|
||
#+END_SRC
|
||
|
||
**** Greeting
|
||
|
||
#+BEGIN_SRC fish :tangle fish/.config/fish/config.fish
|
||
function fish_greeting
|
||
clear
|
||
krabby random
|
||
echo "¸.·´¯`·.´¯`·.¸¸.·´¯`·.¸><(((º>"
|
||
end
|
||
#+END_SRC
|
||
|
||
**** Variables
|
||
|
||
#+BEGIN_SRC fish :tangle fish/.config/fish/config.fish
|
||
set -U fish_user_paths $fish_user_paths $HOME/.local/bin/
|
||
#+END_SRC
|
||
|
||
**** Aliases
|
||
|
||
#+BEGIN_SRC fish :tangle fish/.config/fish/config.fish
|
||
# Colorize grep output (good for log files)
|
||
alias grep='grep --color=auto'
|
||
alias egrep='egrep --color=auto'
|
||
alias fgrep='fgrep --color=auto'
|
||
|
||
# confirm before overwriting something
|
||
alias cp="cp -i"
|
||
alias mv='mv -i'
|
||
alias rm='rm -i'
|
||
|
||
# Replace ls and tree with eza
|
||
alias ls="eza"
|
||
alias tree="eza -T"
|
||
#+END_SRC
|
||
|
||
**** TTY
|
||
|
||
#+BEGIN_SRC fish :tangle fish/.config/fish/config.fish
|
||
if [ "$TERM" = "linux" ]
|
||
then
|
||
printf %b '\e[40m' '\e[8]' # set default background to color 0 'dracula-bg'
|
||
printf %b '\e[37m' '\e[8]' # set default foreground to color 7 'dracula-fg'
|
||
printf %b '\e]P0282a36' # redefine 'black' as 'dracula-bg'
|
||
printf %b '\e]P86272a4' # redefine 'bright-black' as 'dracula-comment'
|
||
printf %b '\e]P1ff5555' # redefine 'red' as 'dracula-red'
|
||
printf %b '\e]P9ff7777' # redefine 'bright-red' as '#ff7777'
|
||
printf %b '\e]P250fa7b' # redefine 'green' as 'dracula-green'
|
||
printf %b '\e]PA70fa9b' # redefine 'bright-green' as '#70fa9b'
|
||
printf %b '\e]P3f1fa8c' # redefine 'brown' as 'dracula-yellow'
|
||
printf %b '\e]PBffb86c' # redefine 'bright-brown' as 'dracula-orange'
|
||
printf %b '\e]P4bd93f9' # redefine 'blue' as 'dracula-purple'
|
||
printf %b '\e]PCcfa9ff' # redefine 'bright-blue' as '#cfa9ff'
|
||
printf %b '\e]P5ff79c6' # redefine 'magenta' as 'dracula-pink'
|
||
printf %b '\e]PDff88e8' # redefine 'bright-magenta' as '#ff88e8'
|
||
printf %b '\e]P68be9fd' # redefine 'cyan' as 'dracula-cyan'
|
||
printf %b '\e]PE97e2ff' # redefine 'bright-cyan' as '#97e2ff'
|
||
printf %b '\e]P7f8f8f2' # redefine 'white' as 'dracula-fg'
|
||
printf %b '\e]PFffffff' # redefine 'bright-white' as '#ffffff'
|
||
clear
|
||
end
|
||
#+END_SRC
|
||
|
||
**** Prompt
|
||
|
||
#+BEGIN_SRC fish :tangle fish/.config/fish/config.fish
|
||
# Starship Prompt
|
||
starship init fish | source
|
||
#+END_SRC
|
||
|
||
**** Dracula Theme
|
||
|
||
#+BEGIN_SRC fish :tangle fish/.config/fish/themes/Dracula_Official.theme
|
||
# Dracula Color Palette
|
||
#
|
||
# Foreground: f8f8f2
|
||
# Selection: 44475a
|
||
# Comment: 6272a4
|
||
# Red: ff5555
|
||
# Orange: ffb86c
|
||
# Yellow: f1fa8c
|
||
# Green: 50fa7b
|
||
# Purple: bd93f9
|
||
# Cyan: 8be9fd
|
||
# Pink: ff79c6
|
||
|
||
# Syntax Highlighting Colors
|
||
fish_color_normal f8f8f2
|
||
fish_color_command 8be9fd
|
||
fish_color_keyword ff79c6
|
||
fish_color_quote f1fa8c
|
||
fish_color_redirection f8f8f2
|
||
fish_color_end ffb86c
|
||
fish_color_error ff5555
|
||
fish_color_param bd93f9
|
||
fish_color_comment 6272a4
|
||
fish_color_selection --background=44475a
|
||
fish_color_search_match --background=44475a
|
||
fish_color_operator 50fa7b
|
||
fish_color_escape ff79c6
|
||
fish_color_autosuggestion 6272a4
|
||
fish_color_cancel ff5555 --reverse
|
||
fish_color_option ffb86c
|
||
fish_color_history_current --bold
|
||
fish_color_status ff5555
|
||
fish_color_valid_path --underline
|
||
|
||
# Default Prompt Colors
|
||
fish_color_cwd 50fa7b
|
||
fish_color_cwd_root red
|
||
fish_color_host bd93f9
|
||
fish_color_host_remote bd93f9
|
||
fish_color_user 8be9fd
|
||
|
||
# Completion Pager Colors
|
||
fish_pager_color_progress 6272a4
|
||
fish_pager_color_background
|
||
fish_pager_color_prefix 8be9fd
|
||
fish_pager_color_completion f8f8f2
|
||
fish_pager_color_description 6272a4
|
||
fish_pager_color_selected_background --background=44475a
|
||
fish_pager_color_selected_prefix 8be9fd
|
||
fish_pager_color_selected_completion f8f8f2
|
||
fish_pager_color_selected_description 6272a4
|
||
fish_pager_color_secondary_background
|
||
fish_pager_color_secondary_prefix 8be9fd
|
||
fish_pager_color_secondary_completion f8f8f2
|
||
fish_pager_color_secondary_description 6272a4
|
||
#+END_SRC
|
||
|
||
**** Start Tmux
|
||
|
||
#+BEGIN_SRC fish :tangle fish/.config/fish/config.fish
|
||
if status is-interactive
|
||
and not set -q TMUX
|
||
tmux new-session
|
||
end
|
||
#+END_SRC
|
||
|
||
** Terminal
|
||
|
||
*** Kitty
|
||
|
||
**** Fonts
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Fonts {{{
|
||
|
||
#: kitty has very powerful font management. You can configure
|
||
#: individual font faces and even specify special fonts for particular
|
||
#: characters.
|
||
|
||
font_family MonaspiceNe NFM
|
||
bold_font MonaspiceNe NFM Bold
|
||
italic_font MonaspiceNe NFM Italic
|
||
bold_italic_font MonaspiceNe NFM Bold Italic
|
||
|
||
#: You can specify different fonts for the bold/italic/bold-italic
|
||
#: variants. To get a full list of supported fonts use the `kitty
|
||
#: list-fonts` command. By default they are derived automatically, by
|
||
#: the OSes font system. Setting them manually is useful for font
|
||
#: families that have many weight variants like Book, Medium, Thick,
|
||
#: etc. For example::
|
||
|
||
#: font_family Operator Mono Book
|
||
#: bold_font Operator Mono Medium
|
||
#: italic_font Operator Mono Book Italic
|
||
#: bold_italic_font Operator Mono Medium Italic
|
||
|
||
font_size 12.0
|
||
|
||
#: Font size (in pts)
|
||
|
||
force_ltr no
|
||
|
||
#: kitty does not support BIDI (bidirectional text), however, for RTL
|
||
#: scripts, words are automatically displayed in RTL. That is to say,
|
||
#: in an RTL script, the words "HELLO WORLD" display in kitty as
|
||
#: "WORLD HELLO", and if you try to select a substring of an RTL-
|
||
#: shaped string, you will get the character that would be there had
|
||
#: the the string been LTR. For example, assuming the Hebrew word
|
||
#: ירושלים, selecting the character that on the screen appears to be ם
|
||
#: actually writes into the selection buffer the character י.
|
||
|
||
#: kitty's default behavior is useful in conjunction with a filter to
|
||
#: reverse the word order, however, if you wish to manipulate RTL
|
||
#: glyphs, it can be very challenging to work with, so this option is
|
||
#: provided to turn it off. Furthermore, this option can be used with
|
||
#: the command line program GNU FriBidi
|
||
#: <https://github.com/fribidi/fribidi#executable> to get BIDI
|
||
#: support, because it will force kitty to always treat the text as
|
||
#: LTR, which FriBidi expects for terminals.
|
||
|
||
adjust_line_height 0
|
||
adjust_column_width 0
|
||
|
||
#: Change the size of each character cell kitty renders. You can use
|
||
#: either numbers, which are interpreted as pixels or percentages
|
||
#: (number followed by %), which are interpreted as percentages of the
|
||
#: unmodified values. You can use negative pixels or percentages less
|
||
#: than 100% to reduce sizes (but this might cause rendering
|
||
#: artifacts).
|
||
|
||
# symbol_map U+E0A0-U+E0A3,U+E0C0-U+E0C7 PowerlineSymbols
|
||
|
||
#: Map the specified unicode codepoints to a particular font. Useful
|
||
#: if you need special rendering for some symbols, such as for
|
||
#: Powerline. Avoids the need for patched fonts. Each unicode code
|
||
#: point is specified in the form U+<code point in hexadecimal>. You
|
||
#: can specify multiple code points, separated by commas and ranges
|
||
#: separated by hyphens. symbol_map itself can be specified multiple
|
||
#: times. Syntax is::
|
||
|
||
#: symbol_map codepoints Font Family Name
|
||
|
||
disable_ligatures never
|
||
|
||
#: Choose how you want to handle multi-character ligatures. The
|
||
#: default is to always render them. You can tell kitty to not render
|
||
#: them when the cursor is over them by using cursor to make editing
|
||
#: easier, or have kitty never render them at all by using always, if
|
||
#: you don't like them. The ligature strategy can be set per-window
|
||
#: either using the kitty remote control facility or by defining
|
||
#: shortcuts for it in kitty.conf, for example::
|
||
|
||
#: map alt+1 disable_ligatures_in active always
|
||
#: map alt+2 disable_ligatures_in all never
|
||
#: map alt+3 disable_ligatures_in tab cursor
|
||
|
||
#: Note that this refers to programming ligatures, typically
|
||
#: implemented using the calt OpenType feature. For disabling general
|
||
#: ligatures, use the font_features setting.
|
||
|
||
font_features none
|
||
|
||
#: Choose exactly which OpenType features to enable or disable. This
|
||
#: is useful as some fonts might have features worthwhile in a
|
||
#: terminal. For example, Fira Code Retina includes a discretionary
|
||
#: feature, zero, which in that font changes the appearance of the
|
||
#: zero (0), to make it more easily distinguishable from Ø. Fira Code
|
||
#: Retina also includes other discretionary features known as
|
||
#: Stylistic Sets which have the tags ss01 through ss20.
|
||
|
||
#: Note that this code is indexed by PostScript name, and not the font
|
||
#: family. This allows you to define very precise feature settings;
|
||
#: e.g. you can disable a feature in the italic font but not in the
|
||
#: regular font.
|
||
|
||
#: On Linux, these are read from the FontConfig database first and
|
||
#: then this, setting is applied, so they can be configured in a
|
||
#: single, central place.
|
||
|
||
#: To get the PostScript name for a font, use kitty + list-fonts
|
||
#: --psnames:
|
||
|
||
#: .. code-block:: sh
|
||
|
||
#: $ kitty + list-fonts --psnames | grep Fira
|
||
#: Fira Code
|
||
#: Fira Code Bold (FiraCode-Bold)
|
||
#: Fira Code Light (FiraCode-Light)
|
||
#: Fira Code Medium (FiraCode-Medium)
|
||
#: Fira Code Regular (FiraCode-Regular)
|
||
#: Fira Code Retina (FiraCode-Retina)
|
||
|
||
#: The part in brackets is the PostScript name.
|
||
|
||
#: Enable alternate zero and oldstyle numerals::
|
||
|
||
#: font_features FiraCode-Retina +zero +onum
|
||
|
||
#: Enable only alternate zero::
|
||
|
||
#: font_features FiraCode-Retina +zero
|
||
|
||
#: Disable the normal ligatures, but keep the calt feature which (in
|
||
#: this font) breaks up monotony::
|
||
|
||
#: font_features TT2020StyleB-Regular -liga +calt
|
||
|
||
#: In conjunction with force_ltr, you may want to disable Arabic
|
||
#: shaping entirely, and only look at their isolated forms if they
|
||
#: show up in a document. You can do this with e.g.::
|
||
|
||
#: font_features UnifontMedium +isol -medi -fina -init
|
||
|
||
box_drawing_scale 0.001, 1, 1.5, 2
|
||
|
||
#: Change the sizes of the lines used for the box drawing unicode
|
||
#: characters These values are in pts. They will be scaled by the
|
||
#: monitor DPI to arrive at a pixel value. There must be four values
|
||
#: corresponding to thin, normal, thick, and very thick lines.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Cursor Customization
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Cursor customization {{{
|
||
|
||
; cursor #cccccc
|
||
|
||
#: Default cursor color
|
||
|
||
; cursor_text_color #111111
|
||
|
||
#: Choose the color of text under the cursor. If you want it rendered
|
||
#: with the background color of the cell underneath instead, use the
|
||
#: special keyword: background
|
||
|
||
cursor_shape beam
|
||
|
||
#: The cursor shape can be one of (block, beam, underline)
|
||
|
||
cursor_beam_thickness 1.5
|
||
|
||
#: Defines the thickness of the beam cursor (in pts)
|
||
|
||
cursor_underline_thickness 2.0
|
||
|
||
#: Defines the thickness of the underline cursor (in pts)
|
||
|
||
cursor_blink_interval -1
|
||
|
||
#: The interval (in seconds) at which to blink the cursor. Set to zero
|
||
#: to disable blinking. Negative values mean use system default. Note
|
||
#: that numbers smaller than repaint_delay will be limited to
|
||
#: repaint_delay.
|
||
|
||
cursor_stop_blinking_after 15.0
|
||
|
||
#: Stop blinking cursor after the specified number of seconds of
|
||
#: keyboard inactivity. Set to zero to never stop blinking.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Scrollback
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Scrollback {{{
|
||
|
||
scrollback_lines 2000
|
||
|
||
#: Number of lines of history to keep in memory for scrolling back.
|
||
#: Memory is allocated on demand. Negative numbers are (effectively)
|
||
#: infinite scrollback. Note that using very large scrollback is not
|
||
#: recommended as it can slow down performance of the terminal and
|
||
#: also use large amounts of RAM. Instead, consider using
|
||
#: scrollback_pager_history_size.
|
||
|
||
scrollback_pager less --chop-long-lines --RAW-CONTROL-CHARS +INPUT_LINE_NUMBER
|
||
|
||
#: Program with which to view scrollback in a new window. The
|
||
#: scrollback buffer is passed as STDIN to this program. If you change
|
||
#: it, make sure the program you use can handle ANSI escape sequences
|
||
#: for colors and text formatting. INPUT_LINE_NUMBER in the command
|
||
#: line above will be replaced by an integer representing which line
|
||
#: should be at the top of the screen. Similarly CURSOR_LINE and
|
||
#: CURSOR_COLUMN will be replaced by the current cursor position.
|
||
|
||
scrollback_pager_history_size 0
|
||
|
||
#: Separate scrollback history size, used only for browsing the
|
||
#: scrollback buffer (in MB). This separate buffer is not available
|
||
#: for interactive scrolling but will be piped to the pager program
|
||
#: when viewing scrollback buffer in a separate window. The current
|
||
#: implementation stores the data in UTF-8, so approximatively 10000
|
||
#: lines per megabyte at 100 chars per line, for pure ASCII text,
|
||
#: unformatted text. A value of zero or less disables this feature.
|
||
#: The maximum allowed size is 4GB.
|
||
|
||
wheel_scroll_multiplier 5.0
|
||
|
||
#: Modify the amount scrolled by the mouse wheel. Note this is only
|
||
#: used for low precision scrolling devices, not for high precision
|
||
#: scrolling on platforms such as macOS and Wayland. Use negative
|
||
#: numbers to change scroll direction.
|
||
|
||
touch_scroll_multiplier 1.0
|
||
|
||
#: Modify the amount scrolled by a touchpad. Note this is only used
|
||
#: for high precision scrolling devices on platforms such as macOS and
|
||
#: Wayland. Use negative numbers to change scroll direction.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Mouse
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Mouse {{{
|
||
|
||
mouse_hide_wait 3.0
|
||
|
||
#: Hide mouse cursor after the specified number of seconds of the
|
||
#: mouse not being used. Set to zero to disable mouse cursor hiding.
|
||
#: Set to a negative value to hide the mouse cursor immediately when
|
||
#: typing text. Disabled by default on macOS as getting it to work
|
||
#: robustly with the ever-changing sea of bugs that is Cocoa is too
|
||
#: much effort.
|
||
|
||
; url_color #0087bd
|
||
url_style curly
|
||
|
||
#: The color and style for highlighting URLs on mouse-over. url_style
|
||
#: can be one of: none, single, double, curly
|
||
|
||
open_url_modifiers kitty_mod
|
||
|
||
#: The modifier keys to press when clicking with the mouse on URLs to
|
||
#: open the URL
|
||
|
||
open_url_with default
|
||
|
||
#: The program with which to open URLs that are clicked on. The
|
||
#: special value default means to use the operating system's default
|
||
#: URL handler.
|
||
|
||
url_prefixes http https file ftp
|
||
|
||
#: The set of URL prefixes to look for when detecting a URL under the
|
||
#: mouse cursor.
|
||
|
||
detect_urls yes
|
||
|
||
#: Detect URLs under the mouse. Detected URLs are highlighted with an
|
||
#: underline and the mouse cursor becomes a hand over them. Even if
|
||
#: this option is disabled, URLs are still clickable.
|
||
|
||
copy_on_select no
|
||
|
||
#: Copy to clipboard or a private buffer on select. With this set to
|
||
#: clipboard, simply selecting text with the mouse will cause the text
|
||
#: to be copied to clipboard. Useful on platforms such as macOS that
|
||
#: do not have the concept of primary selections. You can instead
|
||
#: specify a name such as a1 to copy to a private kitty buffer
|
||
#: instead. Map a shortcut with the paste_from_buffer action to paste
|
||
#: from this private buffer. For example::
|
||
|
||
#: map cmd+shift+v paste_from_buffer a1
|
||
|
||
#: Note that copying to the clipboard is a security risk, as all
|
||
#: programs, including websites open in your browser can read the
|
||
#: contents of the system clipboard.
|
||
|
||
strip_trailing_spaces never
|
||
|
||
#: Remove spaces at the end of lines when copying to clipboard. A
|
||
#: value of smart will do it when using normal selections, but not
|
||
#: rectangle selections. always will always do it.
|
||
|
||
rectangle_select_modifiers ctrl+alt
|
||
|
||
#: The modifiers to use rectangular selection (i.e. to select text in
|
||
#: a rectangular block with the mouse)
|
||
|
||
terminal_select_modifiers shift
|
||
|
||
#: The modifiers to override mouse selection even when a terminal
|
||
#: application has grabbed the mouse
|
||
|
||
select_by_word_characters @-./_~?&=%+#
|
||
|
||
#: Characters considered part of a word when double clicking. In
|
||
#: addition to these characters any character that is marked as an
|
||
#: alphanumeric character in the unicode database will be matched.
|
||
|
||
click_interval -1.0
|
||
|
||
#: The interval between successive clicks to detect double/triple
|
||
#: clicks (in seconds). Negative numbers will use the system default
|
||
#: instead, if available, or fallback to 0.5.
|
||
|
||
focus_follows_mouse no
|
||
|
||
#: Set the active window to the window under the mouse when moving the
|
||
#: mouse around
|
||
|
||
pointer_shape_when_grabbed arrow
|
||
|
||
#: The shape of the mouse pointer when the program running in the
|
||
#: terminal grabs the mouse. Valid values are: arrow, beam and hand
|
||
|
||
default_pointer_shape beam
|
||
|
||
#: The default shape of the mouse pointer. Valid values are: arrow,
|
||
#: beam and hand
|
||
|
||
pointer_shape_when_dragging beam
|
||
|
||
#: The default shape of the mouse pointer when dragging across text.
|
||
#: Valid values are: arrow, beam and hand
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Performance Tuning
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Performance tuning {{{
|
||
|
||
repaint_delay 10
|
||
|
||
#: Delay (in milliseconds) between screen updates. Decreasing it,
|
||
#: increases frames-per-second (FPS) at the cost of more CPU usage.
|
||
#: The default value yields ~100 FPS which is more than sufficient for
|
||
#: most uses. Note that to actually achieve 100 FPS you have to either
|
||
#: set sync_to_monitor to no or use a monitor with a high refresh
|
||
#: rate. Also, to minimize latency when there is pending input to be
|
||
#: processed, repaint_delay is ignored.
|
||
|
||
input_delay 3
|
||
|
||
#: Delay (in milliseconds) before input from the program running in
|
||
#: the terminal is processed. Note that decreasing it will increase
|
||
#: responsiveness, but also increase CPU usage and might cause flicker
|
||
#: in full screen programs that redraw the entire screen on each loop,
|
||
#: because kitty is so fast that partial screen updates will be drawn.
|
||
|
||
sync_to_monitor no
|
||
|
||
#: Sync screen updates to the refresh rate of the monitor. This
|
||
#: prevents tearing (https://en.wikipedia.org/wiki/Screen_tearing)
|
||
#: when scrolling. However, it limits the rendering speed to the
|
||
#: refresh rate of your monitor. With a very high speed mouse/high
|
||
#: keyboard repeat rate, you may notice some slight input latency. If
|
||
#: so, set this to no.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Terminal Bell
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Terminal bell {{{
|
||
|
||
enable_audio_bell yes
|
||
|
||
#: Enable/disable the audio bell. Useful in environments that require
|
||
#: silence.
|
||
|
||
visual_bell_duration 0.0
|
||
|
||
#: Visual bell duration. Flash the screen when a bell occurs for the
|
||
#: specified number of seconds. Set to zero to disable.
|
||
|
||
window_alert_on_bell yes
|
||
|
||
#: Request window attention on bell. Makes the dock icon bounce on
|
||
#: macOS or the taskbar flash on linux.
|
||
|
||
bell_on_tab yes
|
||
|
||
#: Show a bell symbol on the tab if a bell occurs in one of the
|
||
#: windows in the tab and the window is not the currently focused
|
||
#: window
|
||
|
||
command_on_bell none
|
||
|
||
#: Program to run when a bell occurs.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Window Layout
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Window layout {{{
|
||
|
||
remember_window_size yes
|
||
initial_window_width 640
|
||
initial_window_height 400
|
||
|
||
#: If enabled, the window size will be remembered so that new
|
||
#: instances of kitty will have the same size as the previous
|
||
#: instance. If disabled, the window will initially have size
|
||
#: configured by initial_window_width/height, in pixels. You can use a
|
||
#: suffix of "c" on the width/height values to have them interpreted
|
||
#: as number of cells instead of pixels.
|
||
|
||
enabled_layouts *
|
||
|
||
#: The enabled window layouts. A comma separated list of layout names.
|
||
#: The special value all means all layouts. The first listed layout
|
||
#: will be used as the startup layout. Default configuration is all
|
||
#: layouts in alphabetical order. For a list of available layouts, see
|
||
#: the https://sw.kovidgoyal.net/kitty/index.html#layouts.
|
||
|
||
window_resize_step_cells 2
|
||
window_resize_step_lines 2
|
||
|
||
#: The step size (in units of cell width/cell height) to use when
|
||
#: resizing windows. The cells value is used for horizontal resizing
|
||
#: and the lines value for vertical resizing.
|
||
|
||
window_border_width 0.5
|
||
|
||
#: The width of window borders. Can be either in pixels (px) or pts
|
||
#: (pt). Values in pts will be rounded to the nearest number of pixels
|
||
#: based on screen resolution. If not specified the unit is assumed to
|
||
#: be pts. Note that borders are displayed only when more than one
|
||
#: window is visible. They are meant to separate multiple windows.
|
||
|
||
draw_minimal_borders yes
|
||
|
||
#: Draw only the minimum borders needed. This means that only the
|
||
#: minimum needed borders for inactive windows are drawn. That is only
|
||
#: the borders that separate the inactive window from a neighbor. Note
|
||
#: that setting a non-zero window margin overrides this and causes all
|
||
#: borders to be drawn.
|
||
|
||
window_margin_width 0
|
||
|
||
#: The window margin (in pts) (blank area outside the border). A
|
||
#: single value sets all four sides. Two values set the vertical and
|
||
#: horizontal sides. Three values set top, horizontal and bottom. Four
|
||
#: values set top, right, bottom and left.
|
||
|
||
single_window_margin_width -1
|
||
|
||
#: The window margin (in pts) to use when only a single window is
|
||
#: visible. Negative values will cause the value of
|
||
#: window_margin_width to be used instead. A single value sets all
|
||
#: four sides. Two values set the vertical and horizontal sides. Three
|
||
#: values set top, horizontal and bottom. Four values set top, right,
|
||
#: bottom and left.
|
||
|
||
window_padding_width 5
|
||
|
||
#: The window padding (in pts) (blank area between the text and the
|
||
#: window border). A single value sets all four sides. Two values set
|
||
#: the vertical and horizontal sides. Three values set top, horizontal
|
||
#: and bottom. Four values set top, right, bottom and left.
|
||
|
||
placement_strategy center
|
||
|
||
#: When the window size is not an exact multiple of the cell size, the
|
||
#: cell area of the terminal window will have some extra padding on
|
||
#: the sides. You can control how that padding is distributed with
|
||
#: this option. Using a value of center means the cell area will be
|
||
#: placed centrally. A value of top-left means the padding will be on
|
||
#: only the bottom and right edges.
|
||
|
||
active_border_color #00ff00
|
||
|
||
#: The color for the border of the active window. Set this to none to
|
||
#: not draw borders around the active window.
|
||
|
||
inactive_border_color #cccccc
|
||
|
||
#: The color for the border of inactive windows
|
||
|
||
bell_border_color #ff5a00
|
||
|
||
#: The color for the border of inactive windows in which a bell has
|
||
#: occurred
|
||
|
||
inactive_text_alpha 1.0
|
||
|
||
#: Fade the text in inactive windows by the specified amount (a number
|
||
#: between zero and one, with zero being fully faded).
|
||
|
||
hide_window_decorations no
|
||
|
||
#: Hide the window decorations (title-bar and window borders) with
|
||
#: yes. On macOS, titlebar-only can be used to only hide the titlebar.
|
||
#: Whether this works and exactly what effect it has depends on the
|
||
#: window manager/operating system.
|
||
|
||
resize_debounce_time 0.1
|
||
|
||
#: The time (in seconds) to wait before redrawing the screen when a
|
||
#: resize event is received. On platforms such as macOS, where the
|
||
#: operating system sends events corresponding to the start and end of
|
||
#: a resize, this number is ignored.
|
||
|
||
resize_draw_strategy static
|
||
|
||
#: Choose how kitty draws a window while a resize is in progress. A
|
||
#: value of static means draw the current window contents, mostly
|
||
#: unchanged. A value of scale means draw the current window contents
|
||
#: scaled. A value of blank means draw a blank window. A value of size
|
||
#: means show the window size in cells.
|
||
|
||
resize_in_steps no
|
||
|
||
#: Resize the OS window in steps as large as the cells, instead of
|
||
#: with the usual pixel accuracy. Combined with an
|
||
#: initial_window_width and initial_window_height in number of cells,
|
||
#: this option can be used to keep the margins as small as possible
|
||
#: when resizing the OS window. Note that this does not currently work
|
||
#: on Wayland.
|
||
|
||
confirm_os_window_close 0
|
||
|
||
#: Ask for confirmation when closing an OS window or a tab that has at
|
||
#: least this number of kitty windows in it. A value of zero disables
|
||
#: confirmation. This confirmation also applies to requests to quit
|
||
#: the entire application (all OS windows, via the quit action).
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Tab Bar
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Tab bar {{{
|
||
|
||
tab_bar_edge top
|
||
|
||
#: Which edge to show the tab bar on, top or bottom
|
||
|
||
tab_bar_margin_width 0.0
|
||
|
||
#: The margin to the left and right of the tab bar (in pts)
|
||
|
||
tab_bar_style powerline
|
||
|
||
#: The tab bar style, can be one of: fade, separator, powerline, or
|
||
#: hidden. In the fade style, each tab's edges fade into the
|
||
#: background color, in the separator style, tabs are separated by a
|
||
#: configurable separator, and the powerline shows the tabs as a
|
||
#: continuous line. If you use the hidden style, you might want to
|
||
#: create a mapping for the select_tab action which presents you with
|
||
#: a list of tabs and allows for easy switching to a tab.
|
||
|
||
tab_bar_min_tabs 2
|
||
|
||
#: The minimum number of tabs that must exist before the tab bar is
|
||
#: shown
|
||
|
||
tab_switch_strategy previous
|
||
|
||
#: The algorithm to use when switching to a tab when the current tab
|
||
#: is closed. The default of previous will switch to the last used
|
||
#: tab. A value of left will switch to the tab to the left of the
|
||
#: closed tab. A value of right will switch to the tab to the right of
|
||
#: the closed tab. A value of last will switch to the right-most tab.
|
||
|
||
tab_fade 0.25 0.5 0.75 1
|
||
|
||
#: Control how each tab fades into the background when using fade for
|
||
#: the tab_bar_style. Each number is an alpha (between zero and one)
|
||
#: that controls how much the corresponding cell fades into the
|
||
#: background, with zero being no fade and one being full fade. You
|
||
#: can change the number of cells used by adding/removing entries to
|
||
#: this list.
|
||
|
||
tab_separator " ┇"
|
||
|
||
#: The separator between tabs in the tab bar when using separator as
|
||
#: the tab_bar_style.
|
||
|
||
tab_activity_symbol none
|
||
|
||
#: Some text or a unicode symbol to show on the tab if a window in the
|
||
#: tab that does not have focus has some activity.
|
||
|
||
tab_title_template "{index}: {title}"
|
||
|
||
#: A template to render the tab title. The default just renders the
|
||
#: title. If you wish to include the tab-index as well, use something
|
||
#: like: {index}: {title}. Useful if you have shortcuts mapped for
|
||
#: goto_tab N. In addition you can use {layout_name} for the current
|
||
#: layout name and {num_windows} for the number of windows in the tab.
|
||
#: Note that formatting is done by Python's string formatting
|
||
#: machinery, so you can use, for instance, {layout_name[:2].upper()}
|
||
#: to show only the first two letters of the layout name, upper-cased.
|
||
#: If you want to style the text, you can use styling directives, for
|
||
#: example: {fmt.fg.red}red{fmt.fg.default}normal{fmt.bg._00FF00}green
|
||
#: bg{fmt.bg.normal}. Similarly, for bold and italic:
|
||
#: {fmt.bold}bold{fmt.nobold}normal{fmt.italic}italic{fmt.noitalic}.
|
||
|
||
active_tab_title_template none
|
||
|
||
#: Template to use for active tabs, if not specified falls back to
|
||
#: tab_title_template.
|
||
|
||
; active_tab_foreground #000
|
||
; active_tab_background #eee
|
||
active_tab_font_style bold-italic
|
||
; inactive_tab_foreground #444
|
||
; inactive_tab_background #999
|
||
inactive_tab_font_style normal
|
||
|
||
#: Tab bar colors and styles
|
||
|
||
tab_bar_background none
|
||
|
||
#: Background color for the tab bar. Defaults to using the terminal
|
||
#: background color.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Color Scheme
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Color scheme {{{
|
||
|
||
; foreground #dddddd
|
||
; background #000000
|
||
|
||
#: The foreground and background colors
|
||
|
||
background_opacity 0.8
|
||
|
||
#: The opacity of the background. A number between 0 and 1, where 1 is
|
||
#: opaque and 0 is fully transparent. This will only work if
|
||
#: supported by the OS (for instance, when using a compositor under
|
||
#: X11). Note that it only sets the background color's opacity in
|
||
#: cells that have the same background color as the default terminal
|
||
#: background. This is so that things like the status bar in vim,
|
||
#: powerline prompts, etc. still look good. But it means that if you
|
||
#: use a color theme with a background color in your editor, it will
|
||
#: not be rendered as transparent. Instead you should change the
|
||
#: default background color in your kitty config and not use a
|
||
#: background color in the editor color scheme. Or use the escape
|
||
#: codes to set the terminals default colors in a shell script to
|
||
#: launch your editor. Be aware that using a value less than 1.0 is a
|
||
#: (possibly significant) performance hit. If you want to dynamically
|
||
#: change transparency of windows set dynamic_background_opacity to
|
||
#: yes (this is off by default as it has a performance cost)
|
||
|
||
background_image none
|
||
|
||
#: Path to a background image. Must be in PNG format.
|
||
|
||
background_image_layout tiled
|
||
|
||
#: Whether to tile or scale the background image.
|
||
|
||
background_image_linear no
|
||
|
||
#: When background image is scaled, whether linear interpolation
|
||
#: should be used.
|
||
|
||
dynamic_background_opacity no
|
||
|
||
#: Allow changing of the background_opacity dynamically, using either
|
||
#: keyboard shortcuts (increase_background_opacity and
|
||
#: decrease_background_opacity) or the remote control facility.
|
||
|
||
background_tint 0.0
|
||
|
||
#: How much to tint the background image by the background color. The
|
||
#: tint is applied only under the text area, not margin/borders. Makes
|
||
#: it easier to read the text. Tinting is done using the current
|
||
#: background color for each window. This setting applies only if
|
||
#: background_opacity is set and transparent windows are supported or
|
||
#: background_image is set.
|
||
|
||
dim_opacity 0.8
|
||
|
||
#: How much to dim text that has the DIM/FAINT attribute set. One
|
||
#: means no dimming and zero means fully dimmed (i.e. invisible).
|
||
|
||
; selection_foreground #000000
|
||
|
||
#: The foreground for text selected with the mouse. A value of none
|
||
#: means to leave the color unchanged.
|
||
|
||
; selection_background #fffacd
|
||
|
||
#: The background for text selected with the mouse.
|
||
|
||
|
||
#: The 16 terminal colors. There are 8 basic colors, each color has a
|
||
#: dull and bright version. You can also set the remaining colors from
|
||
#: the 256 color table as color16 to color255.
|
||
|
||
; color0 #000000
|
||
; color8 #767676
|
||
|
||
#: black
|
||
|
||
; color1 #cc0403
|
||
; color9 #f2201f
|
||
|
||
#: red
|
||
|
||
; color2 #19cb00
|
||
; color10 #23fd00
|
||
|
||
#: green
|
||
|
||
; color3 #cecb00
|
||
; color11 #fffd00
|
||
|
||
#: yellow
|
||
|
||
; color4 #0d73cc
|
||
; color12 #1a8fff
|
||
|
||
#: blue
|
||
|
||
; color5 #cb1ed1
|
||
; color13 #fd28ff
|
||
|
||
#: magenta
|
||
|
||
; color6 #0dcdcd
|
||
; color14 #14ffff
|
||
|
||
#: cyan
|
||
|
||
; color7 #dddddd
|
||
; color15 #ffffff
|
||
|
||
#: white
|
||
|
||
; mark1_foreground black
|
||
|
||
#: Color for marks of type 1
|
||
|
||
; mark1_background #98d3cb
|
||
|
||
#: Color for marks of type 1 (light steel blue)
|
||
|
||
mark2_foreground black
|
||
|
||
#: Color for marks of type 2
|
||
|
||
mark2_background #f2dcd3
|
||
|
||
#: Color for marks of type 1 (beige)
|
||
|
||
mark3_foreground black
|
||
|
||
#: Color for marks of type 3
|
||
|
||
mark3_background #f274bc
|
||
|
||
#: Color for marks of type 1 (violet)
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Advanced
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Advanced {{{
|
||
|
||
shell fish
|
||
|
||
#: The shell program to execute. The default value of . means to use
|
||
#: whatever shell is set as the default shell for the current user.
|
||
#: Note that on macOS if you change this, you might need to add
|
||
#: --login to ensure that the shell starts in interactive mode and
|
||
#: reads its startup rc files.
|
||
|
||
editor .
|
||
|
||
#: The console editor to use when editing the kitty config file or
|
||
#: similar tasks. A value of . means to use the environment variables
|
||
#: VISUAL and EDITOR in that order. Note that this environment
|
||
#: variable has to be set not just in your shell startup scripts but
|
||
#: system-wide, otherwise kitty will not see it.
|
||
|
||
close_on_child_death no
|
||
|
||
#: Close the window when the child process (shell) exits. If no (the
|
||
#: default), the terminal will remain open when the child exits as
|
||
#: long as there are still processes outputting to the terminal (for
|
||
#: example disowned or backgrounded processes). If yes, the window
|
||
#: will close as soon as the child process exits. Note that setting it
|
||
#: to yes means that any background processes still using the terminal
|
||
#: can fail silently because their stdout/stderr/stdin no longer work.
|
||
|
||
allow_remote_control no
|
||
|
||
#: Allow other programs to control kitty. If you turn this on other
|
||
#: programs can control all aspects of kitty, including sending text
|
||
#: to kitty windows, opening new windows, closing windows, reading the
|
||
#: content of windows, etc. Note that this even works over ssh
|
||
#: connections. You can chose to either allow any program running
|
||
#: within kitty to control it, with yes or only programs that connect
|
||
#: to the socket specified with the kitty --listen-on command line
|
||
#: option, if you use the value socket-only. The latter is useful if
|
||
#: you want to prevent programs running on a remote computer over ssh
|
||
#: from controlling kitty.
|
||
|
||
listen_on none
|
||
|
||
#: Tell kitty to listen to the specified unix/tcp socket for remote
|
||
#: control connections. Note that this will apply to all kitty
|
||
#: instances. It can be overridden by the kitty --listen-on command
|
||
#: line flag. This option accepts only UNIX sockets, such as
|
||
#: unix:${TEMP}/mykitty or (on Linux) unix:@mykitty. Environment
|
||
#: variables are expanded. If {kitty_pid} is present then it is
|
||
#: replaced by the PID of the kitty process, otherwise the PID of the
|
||
#: kitty process is appended to the value, with a hyphen. This option
|
||
#: is ignored unless you also set allow_remote_control to enable
|
||
#: remote control. See the help for kitty --listen-on for more
|
||
#: details.
|
||
|
||
# env
|
||
|
||
#: Specify environment variables to set in all child processes. Note
|
||
#: that environment variables are expanded recursively, so if you
|
||
#: use::
|
||
|
||
#: env MYVAR1=a
|
||
#: env MYVAR2=${MYVAR1}/${HOME}/b
|
||
|
||
#: The value of MYVAR2 will be a/<path to home directory>/b.
|
||
|
||
update_check_interval 0
|
||
|
||
#: Periodically check if an update to kitty is available. If an update
|
||
#: is found a system notification is displayed informing you of the
|
||
#: available update. The default is to check every 24 hrs, set to zero
|
||
#: to disable.
|
||
|
||
startup_session none
|
||
|
||
#: Path to a session file to use for all kitty instances. Can be
|
||
#: overridden by using the kitty --session command line option for
|
||
#: individual instances. See
|
||
#: https://sw.kovidgoyal.net/kitty/index.html#sessions in the kitty
|
||
#: documentation for details. Note that relative paths are interpreted
|
||
#: with respect to the kitty config directory. Environment variables
|
||
#: in the path are expanded.
|
||
|
||
clipboard_control write-clipboard write-primary
|
||
|
||
#: Allow programs running in kitty to read and write from the
|
||
#: clipboard. You can control exactly which actions are allowed. The
|
||
#: set of possible actions is: write-clipboard read-clipboard write-
|
||
#: primary read-primary. You can additionally specify no-append to
|
||
#: disable kitty's protocol extension for clipboard concatenation. The
|
||
#: default is to allow writing to the clipboard and primary selection
|
||
#: with concatenation enabled. Note that enabling the read
|
||
#: functionality is a security risk as it means that any program, even
|
||
#: one running on a remote server via SSH can read your clipboard.
|
||
|
||
allow_hyperlinks yes
|
||
|
||
#: Process hyperlink (OSC 8) escape sequences. If disabled OSC 8
|
||
#: escape sequences are ignored. Otherwise they become clickable
|
||
#: links, that you can click by holding down ctrl+shift and clicking
|
||
#: with the mouse. The special value of ``ask`` means that kitty will
|
||
#: ask before opening the link.
|
||
|
||
term xterm-kitty
|
||
|
||
#: The value of the TERM environment variable to set. Changing this
|
||
#: can break many terminal programs, only change it if you know what
|
||
#: you are doing, not because you read some advice on Stack Overflow
|
||
#: to change it. The TERM variable is used by various programs to get
|
||
#: information about the capabilities and behavior of the terminal. If
|
||
#: you change it, depending on what programs you run, and how
|
||
#: different the terminal you are changing it to is, various things
|
||
#: from key-presses, to colors, to various advanced features may not
|
||
#: work.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** OS Specific Tweaks
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: OS specific tweaks {{{
|
||
|
||
macos_titlebar_color system
|
||
|
||
#: Change the color of the kitty window's titlebar on macOS. A value
|
||
#: of system means to use the default system color, a value of
|
||
#: background means to use the background color of the currently
|
||
#: active window and finally you can use an arbitrary color, such as
|
||
#: #12af59 or red. WARNING: This option works by using a hack, as
|
||
#: there is no proper Cocoa API for it. It sets the background color
|
||
#: of the entire window and makes the titlebar transparent. As such it
|
||
#: is incompatible with background_opacity. If you want to use both,
|
||
#: you are probably better off just hiding the titlebar with
|
||
#: hide_window_decorations.
|
||
|
||
macos_option_as_alt no
|
||
|
||
#: Use the option key as an alt key. With this set to no, kitty will
|
||
#: use the macOS native Option+Key = unicode character behavior. This
|
||
#: will break any Alt+key keyboard shortcuts in your terminal
|
||
#: programs, but you can use the macOS unicode input technique. You
|
||
#: can use the values: left, right, or both to use only the left,
|
||
#: right or both Option keys as Alt, instead.
|
||
|
||
macos_hide_from_tasks no
|
||
|
||
#: Hide the kitty window from running tasks (Option+Tab) on macOS.
|
||
|
||
macos_quit_when_last_window_closed no
|
||
|
||
#: Have kitty quit when all the top-level windows are closed. By
|
||
#: default, kitty will stay running, even with no open windows, as is
|
||
#: the expected behavior on macOS.
|
||
|
||
macos_window_resizable yes
|
||
|
||
#: Disable this if you want kitty top-level (OS) windows to not be
|
||
#: resizable on macOS.
|
||
|
||
macos_thicken_font 0
|
||
|
||
#: Draw an extra border around the font with the given width, to
|
||
#: increase legibility at small font sizes. For example, a value of
|
||
#: 0.75 will result in rendering that looks similar to sub-pixel
|
||
#: antialiasing at common font sizes.
|
||
|
||
macos_traditional_fullscreen no
|
||
|
||
#: Use the traditional full-screen transition, that is faster, but
|
||
#: less pretty.
|
||
|
||
macos_show_window_title_in all
|
||
|
||
#: Show or hide the window title in the macOS window or menu-bar. A
|
||
#: value of window will show the title of the currently active window
|
||
#: at the top of the macOS window. A value of menubar will show the
|
||
#: title of the currently active window in the macOS menu-bar, making
|
||
#: use of otherwise wasted space. all will show the title everywhere
|
||
#: and none hides the title in the window and the menu-bar.
|
||
|
||
macos_custom_beam_cursor no
|
||
|
||
#: Enable/disable custom mouse cursor for macOS that is easier to see
|
||
#: on both light and dark backgrounds. WARNING: this might make your
|
||
#: mouse cursor invisible on dual GPU machines.
|
||
|
||
linux_display_server auto
|
||
|
||
#: Choose between Wayland and X11 backends. By default, an appropriate
|
||
#: backend based on the system state is chosen automatically. Set it
|
||
#: to x11 or wayland to force the choice.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Keyboard Shortcuts
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Keyboard shortcuts {{{
|
||
|
||
#: For a list of key names, see: the GLFW key macros
|
||
#: <https://github.com/kovidgoyal/kitty/blob/master/glfw/glfw3.h#L349>.
|
||
#: The name to use is the part after the GLFW_KEY_ prefix. For a list
|
||
#: of modifier names, see: GLFW mods
|
||
#: <https://www.glfw.org/docs/latest/group__mods.html>
|
||
|
||
#: On Linux you can also use XKB key names to bind keys that are not
|
||
#: supported by GLFW. See XKB keys
|
||
#: <https://github.com/xkbcommon/libxkbcommon/blob/master/xkbcommon/xkbcommon-
|
||
#: keysyms.h> for a list of key names. The name to use is the part
|
||
#: after the XKB_KEY_ prefix. Note that you can only use an XKB key
|
||
#: name for keys that are not known as GLFW keys.
|
||
|
||
#: Finally, you can use raw system key codes to map keys, again only
|
||
#: for keys that are not known as GLFW keys. To see the system key
|
||
#: code for a key, start kitty with the kitty --debug-keyboard option.
|
||
#: Then kitty will output some debug text for every key event. In that
|
||
#: text look for ``native_code`` the value of that becomes the key
|
||
#: name in the shortcut. For example:
|
||
|
||
#: .. code-block:: none
|
||
|
||
#: on_key_input: glfw key: 65 native_code: 0x61 action: PRESS mods: 0x0 text: 'a'
|
||
|
||
#: Here, the key name for the A key is 0x61 and you can use it with::
|
||
|
||
#: map ctrl+0x61 something
|
||
|
||
#: to map ctrl+a to something.
|
||
|
||
#: You can use the special action no_op to unmap a keyboard shortcut
|
||
#: that is assigned in the default configuration::
|
||
|
||
#: map kitty_mod+space no_op
|
||
|
||
#: You can combine multiple actions to be triggered by a single
|
||
#: shortcut, using the syntax below::
|
||
|
||
#: map key combine <separator> action1 <separator> action2 <separator> action3 ...
|
||
|
||
#: For example::
|
||
|
||
#: map kitty_mod+e combine : new_window : next_layout
|
||
|
||
#: this will create a new window and switch to the next available
|
||
#: layout
|
||
|
||
#: You can use multi-key shortcuts using the syntax shown below::
|
||
|
||
#: map key1>key2>key3 action
|
||
|
||
#: For example::
|
||
|
||
#: map ctrl+f>2 set_font_size 20
|
||
|
||
kitty_mod ctrl+shift
|
||
|
||
#: The value of kitty_mod is used as the modifier for all default
|
||
#: shortcuts, you can change it in your kitty.conf to change the
|
||
#: modifiers for all the default shortcuts.
|
||
|
||
clear_all_shortcuts no
|
||
|
||
#: You can have kitty remove all shortcut definition seen up to this
|
||
#: point. Useful, for instance, to remove the default shortcuts.
|
||
|
||
# kitten_alias hints hints --hints-offset=0
|
||
|
||
#: You can create aliases for kitten names, this allows overriding the
|
||
#: defaults for kitten options and can also be used to shorten
|
||
#: repeated mappings of the same kitten with a specific group of
|
||
#: options. For example, the above alias changes the default value of
|
||
#: kitty +kitten hints --hints-offset to zero for all mappings,
|
||
#: including the builtin ones.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Clipboard
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Clipboard {{{
|
||
|
||
map kitty_mod+c copy_to_clipboard
|
||
|
||
#: There is also a copy_or_interrupt action that can be optionally
|
||
#: mapped to Ctrl+c. It will copy only if there is a selection and
|
||
#: send an interrupt otherwise. Similarly, copy_and_clear_or_interrupt
|
||
#: will copy and clear the selection or send an interrupt if there is
|
||
#: no selection.
|
||
|
||
map kitty_mod+v paste_from_clipboard
|
||
map kitty_mod+s paste_from_selection
|
||
map shift+insert paste_from_selection
|
||
map kitty_mod+o pass_selection_to_program
|
||
|
||
#: You can also pass the contents of the current selection to any
|
||
#: program using pass_selection_to_program. By default, the system's
|
||
#: open program is used, but you can specify your own, the selection
|
||
#: will be passed as a command line argument to the program, for
|
||
#: example::
|
||
|
||
#: map kitty_mod+o pass_selection_to_program firefox
|
||
|
||
#: You can pass the current selection to a terminal program running in
|
||
#: a new kitty window, by using the @selection placeholder::
|
||
|
||
#: map kitty_mod+y new_window less @selection
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Scrolling
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Scrolling {{{
|
||
|
||
map kitty_mod+up scroll_line_up
|
||
map kitty_mod+k scroll_line_up
|
||
map kitty_mod+down scroll_line_down
|
||
map kitty_mod+j scroll_line_down
|
||
map kitty_mod+page_up scroll_page_up
|
||
map kitty_mod+page_down scroll_page_down
|
||
map kitty_mod+home scroll_home
|
||
map kitty_mod+end scroll_end
|
||
map kitty_mod+h show_scrollback
|
||
|
||
#: You can pipe the contents of the current screen + history buffer as
|
||
#: STDIN to an arbitrary program using the ``launch`` function. For
|
||
#: example, the following opens the scrollback buffer in less in an
|
||
#: overlay window::
|
||
|
||
#: map f1 launch --stdin-source=@screen_scrollback --stdin-add-formatting --type=overlay less +G -R
|
||
|
||
#: For more details on piping screen and buffer contents to external
|
||
#: programs, see launch.
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Window Management
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Window management {{{
|
||
|
||
map kitty_mod+enter new_window
|
||
|
||
#: You can open a new window running an arbitrary program, for
|
||
#: example::
|
||
|
||
#: map kitty_mod+y launch mutt
|
||
|
||
#: You can open a new window with the current working directory set to
|
||
#: the working directory of the current window using::
|
||
|
||
#: map ctrl+alt+enter launch --cwd=current
|
||
|
||
#: You can open a new window that is allowed to control kitty via the
|
||
#: kitty remote control facility by prefixing the command line with @.
|
||
#: Any programs running in that window will be allowed to control
|
||
#: kitty. For example::
|
||
|
||
#: map ctrl+enter launch --allow-remote-control some_program
|
||
|
||
#: You can open a new window next to the currently active window or as
|
||
#: the first window, with::
|
||
|
||
#: map ctrl+n launch --location=neighbor some_program
|
||
#: map ctrl+f launch --location=first some_program
|
||
|
||
#: For more details, see launch.
|
||
|
||
map kitty_mod+n new_os_window
|
||
|
||
#: Works like new_window above, except that it opens a top level OS
|
||
#: kitty window. In particular you can use new_os_window_with_cwd to
|
||
#: open a window with the current working directory.
|
||
|
||
map kitty_mod+w close_window
|
||
map kitty_mod+] next_window
|
||
map kitty_mod+[ previous_window
|
||
map kitty_mod+f move_window_forward
|
||
map kitty_mod+b move_window_backward
|
||
map kitty_mod+` move_window_to_top
|
||
map kitty_mod+r start_resizing_window
|
||
map kitty_mod+1 first_window
|
||
map kitty_mod+2 second_window
|
||
map kitty_mod+3 third_window
|
||
map kitty_mod+4 fourth_window
|
||
map kitty_mod+5 fifth_window
|
||
map kitty_mod+6 sixth_window
|
||
map kitty_mod+7 seventh_window
|
||
map kitty_mod+8 eighth_window
|
||
map kitty_mod+9 ninth_window
|
||
map kitty_mod+0 tenth_window
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Tab Management
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Tab management {{{
|
||
|
||
map kitty_mod+right next_tab
|
||
map kitty_mod+left previous_tab
|
||
map kitty_mod+t new_tab
|
||
map kitty_mod+q close_tab
|
||
map kitty_mod+. move_tab_forward
|
||
map kitty_mod+, move_tab_backward
|
||
map kitty_mod+alt+t set_tab_title
|
||
|
||
#: You can also create shortcuts to go to specific tabs, with 1 being
|
||
#: the first tab, 2 the second tab and -1 being the previously active
|
||
#: tab, and any number larger than the last tab being the last tab::
|
||
|
||
#: map ctrl+alt+1 goto_tab 1
|
||
#: map ctrl+alt+2 goto_tab 2
|
||
|
||
#: Just as with new_window above, you can also pass the name of
|
||
#: arbitrary commands to run when using new_tab and use
|
||
#: new_tab_with_cwd. Finally, if you want the new tab to open next to
|
||
#: the current tab rather than at the end of the tabs list, use::
|
||
|
||
#: map ctrl+t new_tab !neighbor [optional cmd to run]
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Layout Management
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Layout management {{{
|
||
|
||
map kitty_mod+l next_layout
|
||
|
||
#: You can also create shortcuts to switch to specific layouts::
|
||
|
||
#: map ctrl+alt+t goto_layout tall
|
||
#: map ctrl+alt+s goto_layout stack
|
||
|
||
#: Similarly, to switch back to the previous layout::
|
||
|
||
#: map ctrl+alt+p last_used_layout
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Font Sizes
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Font sizes {{{
|
||
|
||
#: You can change the font size for all top-level kitty OS windows at
|
||
#: a time or only the current one.
|
||
|
||
map kitty_mod+equal change_font_size all +2.0
|
||
map kitty_mod+minus change_font_size all -2.0
|
||
map kitty_mod+backspace change_font_size all 0
|
||
|
||
#: To setup shortcuts for specific font sizes::
|
||
|
||
#: map kitty_mod+f6 change_font_size all 10.0
|
||
|
||
#: To setup shortcuts to change only the current OS window's font
|
||
#: size::
|
||
|
||
#: map kitty_mod+f6 change_font_size current 10.0
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Select and Act on Visible Text
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Select and act on visible text {{{
|
||
|
||
#: Use the hints kitten to select text and either pass it to an
|
||
#: external program or insert it into the terminal or copy it to the
|
||
#: clipboard.
|
||
|
||
map kitty_mod+e kitten hints
|
||
|
||
#: Open a currently visible URL using the keyboard. The program used
|
||
#: to open the URL is specified in open_url_with.
|
||
|
||
map kitty_mod+p>f kitten hints --type path --program -
|
||
|
||
#: Select a path/filename and insert it into the terminal. Useful, for
|
||
#: instance to run git commands on a filename output from a previous
|
||
#: git command.
|
||
|
||
map kitty_mod+p>shift+f kitten hints --type path
|
||
|
||
#: Select a path/filename and open it with the default open program.
|
||
|
||
map kitty_mod+p>l kitten hints --type line --program -
|
||
|
||
#: Select a line of text and insert it into the terminal. Use for the
|
||
#: output of things like: ls -1
|
||
|
||
map kitty_mod+p>w kitten hints --type word --program -
|
||
|
||
#: Select words and insert into terminal.
|
||
|
||
map kitty_mod+p>h kitten hints --type hash --program -
|
||
|
||
#: Select something that looks like a hash and insert it into the
|
||
#: terminal. Useful with git, which uses sha1 hashes to identify
|
||
#: commits
|
||
|
||
map kitty_mod+p>n kitten hints --type linenum
|
||
|
||
#: Select something that looks like filename:linenum and open it in
|
||
#: vim at the specified line number.
|
||
|
||
map kitty_mod+p>y kitten hints --type hyperlink
|
||
|
||
#: Select a hyperlink (i.e. a URL that has been marked as such by the
|
||
#: terminal program, for example, by ls --hyperlink=auto).
|
||
|
||
|
||
#: The hints kitten has many more modes of operation that you can map
|
||
#: to different shortcuts. For a full description see kittens/hints.
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Miscellaneous
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
#: Miscellaneous {{{
|
||
|
||
map kitty_mod+f11 toggle_fullscreen
|
||
map kitty_mod+f10 toggle_maximized
|
||
map kitty_mod+u kitten unicode_input
|
||
map kitty_mod+f2 edit_config_file
|
||
map kitty_mod+escape kitty_shell window
|
||
|
||
#: Open the kitty shell in a new window/tab/overlay/os_window to
|
||
#: control kitty using commands.
|
||
|
||
map kitty_mod+a>m set_background_opacity +0.1
|
||
map kitty_mod+a>l set_background_opacity -0.1
|
||
map kitty_mod+a>1 set_background_opacity 1
|
||
map kitty_mod+a>d set_background_opacity default
|
||
map kitty_mod+delete clear_terminal reset active
|
||
|
||
#: You can create shortcuts to clear/reset the terminal. For example::
|
||
|
||
#: # Reset the terminal
|
||
#: map kitty_mod+f9 clear_terminal reset active
|
||
#: # Clear the terminal screen by erasing all contents
|
||
#: map kitty_mod+f10 clear_terminal clear active
|
||
#: # Clear the terminal scrollback by erasing it
|
||
#: map kitty_mod+f11 clear_terminal scrollback active
|
||
#: # Scroll the contents of the screen into the scrollback
|
||
#: map kitty_mod+f12 clear_terminal scroll active
|
||
|
||
#: If you want to operate on all windows instead of just the current
|
||
#: one, use all instead of active.
|
||
|
||
#: It is also possible to remap Ctrl+L to both scroll the current
|
||
#: screen contents into the scrollback buffer and clear the screen,
|
||
#: instead of just clearing the screen::
|
||
|
||
#: map ctrl+l combine : clear_terminal scroll active : send_text normal,application \x0c
|
||
|
||
|
||
#: You can tell kitty to send arbitrary (UTF-8) encoded text to the
|
||
#: client program when pressing specified shortcut keys. For example::
|
||
|
||
#: map ctrl+alt+a send_text all Special text
|
||
|
||
#: This will send "Special text" when you press the ctrl+alt+a key
|
||
#: combination. The text to be sent is a python string literal so you
|
||
#: can use escapes like \x1b to send control codes or \u21fb to send
|
||
#: unicode characters (or you can just input the unicode characters
|
||
#: directly as UTF-8 text). The first argument to send_text is the
|
||
#: keyboard modes in which to activate the shortcut. The possible
|
||
#: values are normal or application or kitty or a comma separated
|
||
#: combination of them. The special keyword all means all modes. The
|
||
#: modes normal and application refer to the DECCKM cursor key mode
|
||
#: for terminals, and kitty refers to the special kitty extended
|
||
#: keyboard protocol.
|
||
|
||
#: Another example, that outputs a word and then moves the cursor to
|
||
#: the start of the line (same as pressing the Home key)::
|
||
|
||
#: map ctrl+alt+a send_text normal Word\x1b[H
|
||
#: map ctrl+alt+a send_text application Word\x1bOH
|
||
|
||
#: }}}
|
||
#+END_SRC
|
||
|
||
**** Dracula Theme
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/kitty.conf
|
||
include dracula.conf
|
||
#+END_SRC
|
||
|
||
#+BEGIN_SRC conf :tangle kitty/.config/kitty/dracula.conf
|
||
# https://draculatheme.com/kitty
|
||
#
|
||
# Installation instructions:
|
||
#
|
||
# cp dracula.conf ~/.config/kitty/
|
||
# echo "include dracula.conf" >> ~/.config/kitty/kitty.conf
|
||
#
|
||
# Then reload kitty for the config to take affect.
|
||
# Alternatively copy paste below directly into kitty.conf
|
||
|
||
foreground #f8f8f2
|
||
background #282a36
|
||
selection_foreground #ffffff
|
||
selection_background #44475a
|
||
|
||
url_color #8be9fd
|
||
|
||
# black
|
||
color0 #21222c
|
||
color8 #6272a4
|
||
|
||
# red
|
||
color1 #ff5555
|
||
color9 #ff6e6e
|
||
|
||
# green
|
||
color2 #50fa7b
|
||
color10 #69ff94
|
||
|
||
# yellow
|
||
color3 #f1fa8c
|
||
color11 #ffffa5
|
||
|
||
# blue
|
||
color4 #bd93f9
|
||
color12 #d6acff
|
||
|
||
# magenta
|
||
color5 #ff79c6
|
||
color13 #ff92df
|
||
|
||
# cyan
|
||
color6 #8be9fd
|
||
color14 #a4ffff
|
||
|
||
# white
|
||
color7 #f8f8f2
|
||
color15 #ffffff
|
||
|
||
# Cursor colors
|
||
cursor #f8f8f2
|
||
cursor_text_color background
|
||
|
||
# Tab bar colors
|
||
active_tab_foreground #282a36
|
||
active_tab_background #f8f8f2
|
||
inactive_tab_foreground #282a36
|
||
inactive_tab_background #6272a4
|
||
|
||
# Marks
|
||
mark1_foreground #282a36
|
||
mark1_background #ff5555
|
||
|
||
# Splits/Windows
|
||
active_border_color #f8f8f2
|
||
inactive_border_color #6272a4
|
||
#+END_SRC
|
||
|
||
*** Alacritty
|
||
|
||
Configuration for Alacritty, the GPU enhanced terminal emulator.
|
||
|
||
**** Environment Variable
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Any items in the `env` entry below will be added as
|
||
# environment variables. Some entries may override variables
|
||
# set by alacritty itself.
|
||
#env:
|
||
# TERM variable
|
||
#
|
||
# This value is used to set the `$TERM` environment variable for
|
||
# each instance of Alacritty. If it is not present, alacritty will
|
||
# check the local terminfo database and use `alacritty` if it is
|
||
# available, otherwise `xterm-256color` is used.
|
||
#TERM: alacritty
|
||
#+END_SRC
|
||
|
||
**** Window
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
window:
|
||
# Window dimensions (changes require restart)
|
||
#
|
||
# Specified in number of columns/lines, not pixels.
|
||
# If both are `0`, this setting is ignored.
|
||
#dimensions:
|
||
# columns: 0
|
||
# lines: 0
|
||
|
||
# Window position (changes require restart)
|
||
#
|
||
# Specified in number of pixels.
|
||
# If the position is not set, the window manager will handle the placement.
|
||
#position:
|
||
# x: 0
|
||
# y: 0
|
||
|
||
# Window padding (changes require restart)
|
||
#
|
||
# Blank space added around the window in pixels. This padding is scaled
|
||
# by DPI and the specified value is always added at both opposing sides.
|
||
padding:
|
||
x: 5
|
||
y: 5
|
||
|
||
# Spread additional padding evenly around the terminal content.
|
||
#dynamic_padding: false
|
||
|
||
# Window decorations
|
||
#
|
||
# Values for `decorations`:
|
||
# - full: Borders and title bar
|
||
# - none: Neither borders nor title bar
|
||
#
|
||
# Values for `decorations` (macOS only):
|
||
# - transparent: Title bar, transparent background and title bar buttons
|
||
# - buttonless: Title bar, transparent background, but no title bar buttons
|
||
#decorations: full
|
||
|
||
# Startup Mode (changes require restart)
|
||
#
|
||
# Values for `startup_mode`:
|
||
# - Windowed
|
||
# - Maximized
|
||
# - Fullscreen
|
||
#
|
||
# Values for `startup_mode` (macOS only):
|
||
# - SimpleFullscreen
|
||
#startup_mode: Windowed
|
||
|
||
# Window title
|
||
#title: Alacritty
|
||
|
||
# Window class (Linux/BSD only):
|
||
# class:
|
||
# Application instance name
|
||
# instance: Alacritty
|
||
# General application class
|
||
# general: Alacritty
|
||
|
||
# GTK theme variant (Linux/BSD only)
|
||
#
|
||
# Override the variant of the GTK theme. Commonly supported values are `dark` and `light`.
|
||
# Set this to `None` to use the default theme variant.
|
||
#gtk_theme_variant: None
|
||
#+END_SRC
|
||
|
||
**** Scrolling
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
#scrolling:
|
||
# Maximum number of lines in the scrollback buffer.
|
||
# Specifying '0' will disable scrolling.
|
||
#history: 10000
|
||
|
||
# Number of lines the viewport will move for every line scrolled when
|
||
# scrollback is enabled (history > 0).
|
||
#multiplier: 3
|
||
#+END_SRC
|
||
|
||
**** Font
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Font configuration
|
||
font:
|
||
# Normal (roman) font face
|
||
normal:
|
||
# Font family
|
||
#
|
||
# Default:
|
||
# - (macOS) Menlo
|
||
# - (Linux/BSD) monospace
|
||
# - (Windows) Consolas
|
||
family: MonaspiceNe NF
|
||
|
||
# The `style` can be specified to pick a specific face.
|
||
style: Regular
|
||
|
||
# Bold font face
|
||
bold:
|
||
# Font family
|
||
#
|
||
# If the bold family is not specified, it will fall back to the
|
||
# value specified for the normal font.
|
||
family: MonaspiceNe NF
|
||
|
||
# The `style` can be specified to pick a specific face.
|
||
style: Bold
|
||
|
||
# Italic font face
|
||
#italic:
|
||
# Font family
|
||
#
|
||
# If the italic family is not specified, it will fall back to the
|
||
# value specified for the normal font.
|
||
#family: monospace
|
||
|
||
# The `style` can be specified to pick a specific face.
|
||
#style: Italic
|
||
|
||
# Bold italic font face
|
||
#bold_italic:
|
||
# Font family
|
||
#
|
||
# If the bold italic family is not specified, it will fall back to the
|
||
# value specified for the normal font.
|
||
#family: monospace
|
||
|
||
# The `style` can be specified to pick a specific face.
|
||
#style: Bold Italic
|
||
|
||
# Point size
|
||
size: 8.0
|
||
|
||
# Offset is the extra space around each character. `offset.y` can be thought of
|
||
# as modifying the line spacing, and `offset.x` as modifying the letter spacing.
|
||
#offset:
|
||
# x: 0
|
||
# y: 0
|
||
|
||
# Glyph offset determines the locations of the glyphs within their cells with
|
||
# the default being at the bottom. Increasing `x` moves the glyph to the right,
|
||
# increasing `y` moves the glyph upwards.
|
||
#glyph_offset:
|
||
# x: 0
|
||
# y: 0
|
||
|
||
# Thin stroke font rendering (macOS only)
|
||
#
|
||
# Thin strokes are suitable for retina displays, but for non-retina screens
|
||
# it is recommended to set `use_thin_strokes` to `false`
|
||
#
|
||
# macOS >= 10.14.x:
|
||
#
|
||
# If the font quality on non-retina display looks bad then set
|
||
# `use_thin_strokes` to `true` and enable font smoothing by running the
|
||
# following command:
|
||
# `defaults write -g CGFontRenderingFontSmoothingDisabled -bool NO`
|
||
#
|
||
# This is a global setting and will require a log out or restart to take
|
||
# effect.
|
||
#use_thin_strokes: true
|
||
#+END_SRC
|
||
|
||
**** Colors
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# If `true`, bold text is drawn using the bright color variants.
|
||
#draw_bold_text_with_bright_colors: false
|
||
#+END_SRC
|
||
|
||
***** Tomorrow Night Bright
|
||
|
||
*NOT IN USE*
|
||
#+BEGIN_SRC conf :tangle no
|
||
colors:
|
||
# Default colors
|
||
primary:
|
||
background: '#000000'
|
||
foreground: '#eaeaea'
|
||
|
||
# Bright and dim foreground colors
|
||
|
||
# The dimmed foreground color is calculated automatically if it is not present.
|
||
# If the bright foreground color is not set, or `draw_bold_text_with_bright_colors`
|
||
# is `false`, the normal foreground color will be used.
|
||
# dim_foreground: '#9a9a9a'
|
||
# bright_foreground: '#ffffff'
|
||
|
||
# Cursor colors
|
||
|
||
# Colors which should be used to draw the terminal cursor. If these are unset,
|
||
# the cursor color will be the inverse of the cell color.
|
||
cursor:
|
||
text: '#000000'
|
||
cursor: '#ffffff'
|
||
|
||
# Selection colors
|
||
|
||
# Colors which should be used to draw the selection area. If selection
|
||
# background is unset, selection color will be the inverse of the cell colors.
|
||
# If only text is unset the cell text color will remain the same.
|
||
selection:
|
||
text: '#eaeaea'
|
||
background: '#404040'
|
||
|
||
# Normal colors
|
||
normal:
|
||
black: '#000000'
|
||
red: '#d54e53'
|
||
green: '#b9ca4a'
|
||
yellow: '#e6c547'
|
||
blue: '#7aa6da'
|
||
magenta: '#c397d8'
|
||
cyan: '#70c0ba'
|
||
white: '#eaeaea'
|
||
|
||
# Bright colors
|
||
bright:
|
||
black: '#666666'
|
||
red: '#ff3334'
|
||
green: '#9ec400'
|
||
yellow: '#e7c547'
|
||
blue: '#7aa6da'
|
||
magenta: '#b77ee0'
|
||
cyan: '#54ced6'
|
||
white: '#ffffff'
|
||
|
||
# Dim colors
|
||
|
||
# If the dim colors are not set, they will be calculated automatically based
|
||
# on the `normal` colors.
|
||
dim:
|
||
black: '#000000'
|
||
red: '#8c3336'
|
||
green: '#7a8530'
|
||
yellow: '#97822e'
|
||
blue: '#506d8f'
|
||
magenta: '#80638e'
|
||
cyan: '#497e7a'
|
||
white: '#9a9a9a'
|
||
#+END_SRC
|
||
|
||
***** Dracula
|
||
|
||
*NOT IN USE*
|
||
#+BEGIN_SRC conf :tangle no
|
||
colors:
|
||
# Default colors
|
||
primary:
|
||
background: "0x282a36"
|
||
foreground: "0xf8f8f2"
|
||
|
||
# Bright and dim foreground colors
|
||
#
|
||
# The dimmed foreground color is calculated automatically if it is not present.
|
||
# If the bright foreground color is not set, or `draw_bold_text_with_bright_colors`
|
||
# is `false`, the normal foreground color will be used.
|
||
#dim_foreground: '0x9a9a9a'
|
||
#bright_foreground: '0xffffff'
|
||
|
||
# Cursor colors
|
||
#
|
||
# Colors which should be used to draw the terminal cursor. If these are unset,
|
||
# the cursor color will be the inverse of the cell color.
|
||
cursor:
|
||
text: "0x44475a"
|
||
cursor: "0xf8f8f2"
|
||
|
||
# Normal colors
|
||
normal:
|
||
black: "0x000000"
|
||
red: "0xff5555"
|
||
green: "0x50fa7b"
|
||
yellow: "0xf1fa8c"
|
||
blue: "0xbd93f9"
|
||
magenta: "0xff79c6"
|
||
cyan: "0x8be9fd"
|
||
white: "0xbfbfbf"
|
||
|
||
# Bright colors
|
||
bright:
|
||
black: "0x4d4d4d"
|
||
red: "0xff6e67"
|
||
green: "0x5af78e"
|
||
yellow: "0xf4f99d"
|
||
blue: "0xcaa9fa"
|
||
magenta: "0xff92d0"
|
||
cyan: "0x9aedfe"
|
||
white: "0xe6e6e6"
|
||
|
||
# Dim colors
|
||
#
|
||
# If the dim colors are not set, they will be calculated automatically based
|
||
# on the `normal` colors.
|
||
dim:
|
||
black: "0x14151b"
|
||
red: "0xff2222"
|
||
green: "0x1ef956"
|
||
yellow: "0xebf85b"
|
||
blue: "0x4d5b86"
|
||
magenta: "0xff46b0"
|
||
cyan: "0x59dffc"
|
||
white: "0xe6e6d1"
|
||
#+END_SRC
|
||
|
||
***** Dracula PRO
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
colors:
|
||
# Default colors
|
||
primary:
|
||
background: "0x22212c"
|
||
foreground: "0xf8f8f2"
|
||
|
||
# Bright and dim foreground colors
|
||
#
|
||
# The dimmed foreground color is calculated automatically if it is not present.
|
||
# If the bright foreground color is not set, or `draw_bold_text_with_bright_colors`
|
||
# is `false`, the normal foreground color will be used.
|
||
#dim_foreground: '0x9a9a9a'
|
||
#bright_foreground: '0xffffff'
|
||
|
||
# Cursor colors
|
||
#
|
||
# Colors which should be used to draw the terminal cursor. If these are unset,
|
||
# the cursor color will be the inverse of the cell color.
|
||
cursor:
|
||
text: "0x454158"
|
||
cursor: "0xf8f8f2"
|
||
|
||
# Selection colors
|
||
#
|
||
# Colors which should be used to draw the selection area. If selection
|
||
# background is unset, selection color will be the inverse of the cell colors.
|
||
# If only text is unset the cell text color will remain the same.
|
||
selection:
|
||
text: "0xf8f8f2"
|
||
background: "0x454158"
|
||
|
||
# Normal colors
|
||
normal:
|
||
black: "0x22212c"
|
||
red: "0xff9580"
|
||
green: "0x8aff80"
|
||
yellow: "0xffff80"
|
||
blue: "0x9580ff"
|
||
magenta: "0xff80bf"
|
||
cyan: "0x80ffea"
|
||
white: "0xf8f8f2"
|
||
|
||
# Bright colors
|
||
bright:
|
||
black: "0x22212c"
|
||
red: "0xffaa99"
|
||
green: "0xa2ff99"
|
||
yellow: "0xffff99"
|
||
blue: "0xaa99ff"
|
||
magenta: "0xff99cc"
|
||
cyan: "0x99ffee"
|
||
white: "0xffffff"
|
||
|
||
# Indexed Colors
|
||
#
|
||
# The indexed colors include all colors from 16 to 256.
|
||
# When these are not set, they're filled with sensible defaults.
|
||
#
|
||
# Example:
|
||
# `- { index: 16, color: '0xff00ff' }`
|
||
#
|
||
indexed_colors: []
|
||
#+END_SRC
|
||
|
||
**** Visual Bell
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Bell
|
||
#
|
||
# The bell is rung every time the BEL control character is received.
|
||
#bell:
|
||
# Visual Bell Animation
|
||
#
|
||
# Animation effect for flashing the screen when the visual bell is rung.
|
||
#
|
||
# Values for `animation`:
|
||
# - Ease
|
||
# - EaseOut
|
||
# - EaseOutSine
|
||
# - EaseOutQuad
|
||
# - EaseOutCubic
|
||
# - EaseOutQuart
|
||
# - EaseOutQuint
|
||
# - EaseOutExpo
|
||
# - EaseOutCirc
|
||
# - Linear
|
||
#animation: EaseOutExpo
|
||
|
||
# Duration of the visual bell flash in milliseconds. A `duration` of `0` will
|
||
# disable the visual bell animation.
|
||
#duration: 0
|
||
|
||
# Visual bell animation color.
|
||
#color: '#ffffff'
|
||
|
||
# Bell Command
|
||
#
|
||
# This program is executed whenever the bell is rung.
|
||
#
|
||
# When set to `command: None`, no command will be executed.
|
||
#
|
||
# Example:
|
||
# command:
|
||
# program: notify-send
|
||
# args: ["Hello, World!"]
|
||
#
|
||
#command: None
|
||
#+END_SRC
|
||
|
||
**** Background Opacity
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Background opacity
|
||
#
|
||
# Window opacity as a floating point number from `0.0` to `1.0`.
|
||
# The value `0.0` is completely transparent and `1.0` is opaque.
|
||
# background_opacity: 1.0
|
||
background_opacity: 0.8
|
||
#+END_SRC
|
||
|
||
**** Selection
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
#selection:
|
||
#semantic_escape_chars: ",│`|:\"' ()[]{}<>\t"
|
||
|
||
# When set to `true`, selected text will be copied to the primary clipboard.
|
||
#save_to_clipboard: false
|
||
#+END_SRC
|
||
|
||
**** Window Title
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Allow terminal applications to change Alacritty's window title.
|
||
#dynamic_title: true
|
||
#+END_SRC
|
||
|
||
**** Cursor
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
cursor:
|
||
# Cursor style
|
||
#
|
||
# Values for `style`:
|
||
# - ▇ Block
|
||
# - _ Underline
|
||
# - | Beam
|
||
style: Beam
|
||
|
||
# If this is `true`, the cursor will be rendered as a hollow box when the
|
||
# window is not focused.
|
||
#unfocused_hollow: true
|
||
#+END_SRC
|
||
|
||
**** Live Config Reload
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Live config reload (changes require restart)
|
||
live_config_reload: true
|
||
#+END_SRC
|
||
|
||
**** Shell
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Shell
|
||
#
|
||
# You can set `shell.program` to the path of your favorite shell, e.g. `/bin/fish`.
|
||
# Entries in `shell.args` are passed unmodified as arguments to the shell.
|
||
#
|
||
# Default:
|
||
# - (macOS) /bin/bash --login
|
||
# - (Linux/BSD) user login shell
|
||
# - (Windows) powershell
|
||
shell:
|
||
program: /usr/bin/fish
|
||
# args:
|
||
# - -l
|
||
# - -c
|
||
# - "tmux attach || tmux"
|
||
#+END_SRC
|
||
|
||
**** Startup Directory
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Startup directory
|
||
#
|
||
# Directory the shell is started in. If this is unset, or `None`, the working
|
||
# directory of the parent process will be used.
|
||
#working_directory: None
|
||
#+END_SRC
|
||
|
||
**** WinPTY Backend (Windows Only)
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# WinPTY backend (Windows only)
|
||
#
|
||
# Alacritty defaults to using the newer ConPTY backend if it is available,
|
||
# since it resolves a lot of bugs and is quite a bit faster. If it is not
|
||
# available, the the WinPTY backend will be used instead.
|
||
#
|
||
# Setting this option to `true` makes Alacritty use the legacy WinPTY backend,
|
||
# even if the ConPTY backend is available.
|
||
#winpty_backend: false
|
||
#+END_SRC
|
||
|
||
**** Alt Send Escape
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Send ESC (\x1b) before characters when alt is pressed.
|
||
#alt_send_esc: true
|
||
#+END_SRC
|
||
|
||
**** Mouse
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# mouse:
|
||
# Click settings
|
||
#
|
||
# The `double_click` and `triple_click` settings control the time
|
||
# alacritty should wait for accepting multiple clicks as one double
|
||
# or triple click.
|
||
#double_click: { threshold: 300 }
|
||
#triple_click: { threshold: 300 }
|
||
|
||
# If this is `true`, the cursor is temporarily hidden when typing.
|
||
#hide_when_typing: false
|
||
#+END_SRC
|
||
|
||
**** Hints
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Regex hints
|
||
#
|
||
# Terminal hints can be used to find text in the visible part of the terminal
|
||
# and pipe it to other applications.
|
||
#hints:
|
||
# Keys used for the hint labels.
|
||
#alphabet: "jfkdls;ahgurieowpq"
|
||
|
||
# List with all available hints
|
||
#
|
||
# Each hint must have a `regex` and either an `action` or a `command` field.
|
||
# The fields `mouse`, `binding` and `post_processing` are optional.
|
||
#
|
||
# The fields `command`, `binding.key`, `binding.mods` and `mouse.mods` accept
|
||
# the same values as they do in the `key_bindings` section.
|
||
#
|
||
# The `mouse.enabled` field controls if the hint should be underlined while
|
||
# the mouse with all `mouse.mods` keys held or the vi mode cursor is above it.
|
||
#
|
||
# If the `post_processing` field is set to `true`, heuristics will be used to
|
||
# shorten the match if there are characters likely not to be part of the hint
|
||
# (e.g. a trailing `.`). This is most useful for URIs.
|
||
#
|
||
# Values for `action`:
|
||
# - Copy
|
||
# Copy the hint's text to the clipboard.
|
||
# - Paste
|
||
# Paste the hint's text to the terminal or search.
|
||
# - Select
|
||
# Select the hint's text.
|
||
# - MoveViModeCursor
|
||
# Move the vi mode cursor to the beginning of the hint.
|
||
#enabled:
|
||
# - regex: "(mailto:|gemini:|gopher:|https:|http:|news:|file:|git:|ssh:|ftp:)\
|
||
# [^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+"
|
||
# command: xdg-open
|
||
# post_processing: true
|
||
# mouse:
|
||
# enabled: true
|
||
# mods: None
|
||
# binding:
|
||
# key: U
|
||
# mods: Control|Shift
|
||
#+END_SRC
|
||
|
||
**** Mouse Bindings
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Mouse bindings
|
||
#
|
||
# Mouse bindings are specified as a list of objects, much like the key
|
||
# bindings further below.
|
||
#
|
||
# To trigger mouse bindings when an application running within Alacritty captures the mouse, the
|
||
# `Shift` modifier is automatically added as a requirement.
|
||
#
|
||
# Each mouse binding will specify a:
|
||
#
|
||
# - `mouse`:
|
||
#
|
||
# - Middle
|
||
# - Left
|
||
# - Right
|
||
# - Numeric identifier such as `5`
|
||
#
|
||
# - `action` (see key bindings)
|
||
#
|
||
# And optionally:
|
||
#
|
||
# - `mods` (see key bindings)
|
||
#mouse_bindings:
|
||
# - { mouse: Middle, action: PasteSelection }
|
||
#+END_SRC
|
||
|
||
**** Key Bindings
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
# Key bindings
|
||
#
|
||
# Key bindings are specified as a list of objects. For example, this is the
|
||
# default paste binding:
|
||
#
|
||
# `- { key: V, mods: Control|Shift, action: Paste }`
|
||
#
|
||
# Each key binding will specify a:
|
||
#
|
||
# - `key`: Identifier of the key pressed
|
||
#
|
||
# - A-Z
|
||
# - F1-F24
|
||
# - Key0-Key9
|
||
#
|
||
# A full list with available key codes can be found here:
|
||
# https://docs.rs/glutin/*/glutin/event/enum.VirtualKeyCode.html#variants
|
||
#
|
||
# Instead of using the name of the keys, the `key` field also supports using
|
||
# the scancode of the desired key. Scancodes have to be specified as a
|
||
# decimal number. This command will allow you to display the hex scancodes
|
||
# for certain keys:
|
||
#
|
||
# `showkey --scancodes`.
|
||
#
|
||
# Then exactly one of:
|
||
#
|
||
# - `chars`: Send a byte sequence to the running application
|
||
#
|
||
# The `chars` field writes the specified string to the terminal. This makes
|
||
# it possible to pass escape sequences. To find escape codes for bindings
|
||
# like `PageUp` (`"\x1b[5~"`), you can run the command `showkey -a` outside
|
||
# of tmux. Note that applications use terminfo to map escape sequences back
|
||
# to keys. It is therefore required to update the terminfo when changing an
|
||
# escape sequence.
|
||
#
|
||
# - `action`: Execute a predefined action
|
||
#
|
||
# - Copy
|
||
# - Paste
|
||
# - PasteSelection
|
||
# - IncreaseFontSize
|
||
# - DecreaseFontSize
|
||
# - ResetFontSize
|
||
# - ScrollPageUp
|
||
# - ScrollPageDown
|
||
# - ScrollLineUp
|
||
# - ScrollLineDown
|
||
# - ScrollToTop
|
||
# - ScrollToBottom
|
||
# - ClearHistory
|
||
# - Hide
|
||
# - Minimize
|
||
# - Quit
|
||
# - ToggleFullscreen
|
||
# - SpawnNewInstance
|
||
# - ClearLogNotice
|
||
# - ReceiveChar
|
||
# - None
|
||
#
|
||
# (macOS only):
|
||
# - ToggleSimpleFullscreen: Enters fullscreen without occupying another space
|
||
#
|
||
# - `command`: Fork and execute a specified command plus arguments
|
||
#
|
||
# The `command` field must be a map containing a `program` string and an
|
||
# `args` array of command line parameter strings. For example:
|
||
# `{ program: "alacritty", args: ["-e", "vttest"] }`
|
||
#
|
||
# And optionally:
|
||
#
|
||
# - `mods`: Key modifiers to filter binding actions
|
||
#
|
||
# - Command
|
||
# - Control
|
||
# - Option
|
||
# - Super
|
||
# - Shift
|
||
# - Alt
|
||
#
|
||
# Multiple `mods` can be combined using `|` like this:
|
||
# `mods: Control|Shift`.
|
||
# Whitespace and capitalization are relevant and must match the example.
|
||
#
|
||
# - `mode`: Indicate a binding for only specific terminal reported modes
|
||
#
|
||
# This is mainly used to send applications the correct escape sequences
|
||
# when in different modes.
|
||
#
|
||
# - AppCursor
|
||
# - AppKeypad
|
||
# - Alt
|
||
#
|
||
# A `~` operator can be used before a mode to apply the binding whenever
|
||
# the mode is *not* active, e.g. `~Alt`.
|
||
#
|
||
# Bindings are always filled by default, but will be replaced when a new
|
||
# binding with the same triggers is defined. To unset a default binding, it can
|
||
# be mapped to the `ReceiveChar` action. Alternatively, you can use `None` for
|
||
# a no-op if you do not wish to receive input characters for that binding.
|
||
#
|
||
# If the same trigger is assigned to multiple actions, all of them are executed
|
||
# at once.
|
||
#key_bindings:
|
||
# (Windows, Linux, and BSD only)
|
||
#- { key: V, mods: Control|Shift, action: Paste }
|
||
#- { key: C, mods: Control|Shift, action: Copy }
|
||
#- { key: Insert, mods: Shift, action: PasteSelection }
|
||
#- { key: Key0, mods: Control, action: ResetFontSize }
|
||
#- { key: Equals, mods: Control, action: IncreaseFontSize }
|
||
#- { key: Add, mods: Control, action: IncreaseFontSize }
|
||
#- { key: Subtract, mods: Control, action: DecreaseFontSize }
|
||
#- { key: Minus, mods: Control, action: DecreaseFontSize }
|
||
|
||
# (Windows only)
|
||
#- { key: Return, mods: Alt, action: ToggleFullscreen }
|
||
|
||
# (macOS only)
|
||
#- { key: Key0, mods: Command, action: ResetFontSize }
|
||
#- { key: Equals, mods: Command, action: IncreaseFontSize }
|
||
#- { key: Add, mods: Command, action: IncreaseFontSize }
|
||
#- { key: Minus, mods: Command, action: DecreaseFontSize }
|
||
#- { key: K, mods: Command, action: ClearHistory }
|
||
#- { key: K, mods: Command, chars: "\x0c" }
|
||
#- { key: V, mods: Command, action: Paste }
|
||
#- { key: C, mods: Command, action: Copy }
|
||
#- { key: H, mods: Command, action: Hide }
|
||
#- { key: M, mods: Command, action: Minimize }
|
||
#- { key: Q, mods: Command, action: Quit }
|
||
#- { key: W, mods: Command, action: Quit }
|
||
#- { key: F, mods: Command|Control, action: ToggleFullscreen }
|
||
|
||
#- { key: Paste, action: Paste }
|
||
#- { key: Copy, action: Copy }
|
||
#- { key: L, mods: Control, action: ClearLogNotice }
|
||
#- { key: L, mods: Control, chars: "\x0c" }
|
||
#- { key: PageUp, mods: Shift, action: ScrollPageUp, mode: ~Alt }
|
||
#- { key: PageDown, mods: Shift, action: ScrollPageDown, mode: ~Alt }
|
||
#- { key: Home, mods: Shift, action: ScrollToTop, mode: ~Alt }
|
||
#- { key: End, mods: Shift, action: ScrollToBottom, mode: ~Alt }
|
||
#+END_SRC
|
||
|
||
**** Debug & Logging
|
||
|
||
#+BEGIN_SRC conf :tangle alacritty/.config/alacritty/alacritty.yml
|
||
#debug:
|
||
# Display the time it takes to redraw each frame.
|
||
#render_timer: false
|
||
|
||
# Keep the log file after quitting Alacritty.
|
||
#persistent_logging: false
|
||
|
||
# Log level
|
||
#
|
||
# Values for `log_level`:
|
||
# - None
|
||
# - Error
|
||
# - Warn
|
||
# - Info
|
||
# - Debug
|
||
# - Trace
|
||
#log_level: Warn
|
||
|
||
# Print all received window events.
|
||
#print_events: false
|
||
#+END_SRC
|
||
|
||
* Text Editor
|
||
|
||
** Vim
|
||
|
||
#+BEGIN_SRC vimrc :tangle vim/.vimrc
|
||
" Don't try to be vi compatible
|
||
set nocompatible
|
||
|
||
" Syntax Highlighting
|
||
syntax on
|
||
|
||
" Pick a leader key
|
||
let mapleader = "\\"
|
||
|
||
" Security
|
||
set modelines=0
|
||
|
||
" Show line numbers
|
||
set number relativenumber
|
||
|
||
" Show file stats
|
||
set ruler
|
||
|
||
" Blink cursors on error instead of beeping
|
||
set visualbell
|
||
|
||
" Encoding
|
||
set encoding=utf-8
|
||
|
||
" Whitespace
|
||
set wrap
|
||
set textwidth=110
|
||
set formatoptions=tcqrn1
|
||
set tabstop=4
|
||
set shiftwidth=4
|
||
set softtabstop=4
|
||
set expandtab
|
||
set noshiftround
|
||
set smarttab
|
||
set autoindent
|
||
|
||
" Cursor Motion
|
||
set scrolloff=3
|
||
set backspace=indent,eol,start
|
||
set matchpairs+=<:> " use % to jumb between pairs
|
||
|
||
" Allow hidden buffers
|
||
set hidden
|
||
|
||
" Rendering
|
||
set ttyfast
|
||
|
||
" Status bar
|
||
set laststatus=2
|
||
|
||
" Last line
|
||
set showmode
|
||
set showcmd
|
||
|
||
" Searching
|
||
nnoremap / /\v
|
||
vnoremap / /\v
|
||
set hlsearch
|
||
set incsearch
|
||
set ignorecase
|
||
set smartcase
|
||
set showmatch
|
||
map <leader><space> :let @/=''<cr> " clear search
|
||
|
||
" Formatting
|
||
map <leader>q gqip
|
||
|
||
" Visualize tabs and newlines
|
||
set listchars=tab:▸\ ,eol:¬
|
||
map <leader>l :set list!<CR> " Toggle tabs and EOL
|
||
|
||
" Exit Inser Mode Easily
|
||
:inoremap jk <esc>
|
||
|
||
" UI Config
|
||
set cursorline
|
||
filetype indent on
|
||
set wildmenu
|
||
set lazyredraw
|
||
set showmatch
|
||
|
||
" Add Dracula Themes
|
||
packadd! dracula
|
||
packadd! dracula_pro
|
||
|
||
" Enable Dracula Pro Theme
|
||
syntax enable
|
||
let g:dracula_colorterm = 0
|
||
colorscheme dracula_pro
|
||
#+END_SRC
|
||
|
||
** Emacs
|
||
|
||
*** Chemacs2
|
||
|
||
**** Configurations
|
||
|
||
Define emacs configurations with chemacs2.
|
||
|
||
#+BEGIN_SRC emacs-lisp :tangle emacs/.emacs-profiles.el
|
||
(
|
||
("personal" . ((user-emacs-directory . "~/.config/personal-emacs")))
|
||
("doom" . ((user-emacs-directory . "~/.config/doom-emacs")
|
||
(env . (("DOOMDIR" . "~/.config/doom-emacs-config")))))
|
||
)
|
||
#+END_SRC
|
||
|
||
**** Selected Configuration
|
||
|
||
Select the emacs configuration to use by default.
|
||
|
||
#+BEGIN_SRC text :tangle emacs/.emacs-profile
|
||
doom
|
||
#+END_SRC
|
||
|
||
** VS Code
|
||
|
||
*** Settings
|
||
|
||
**** Open Braces
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
{
|
||
#+END_SRC
|
||
|
||
**** Workbench
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"workbench.colorTheme": "Dracula Pro",
|
||
"workbench.iconTheme": "vscode-icons",
|
||
"workbench.productIconTheme": "fluent-icons",
|
||
"workbench.editorAssociations": {
|
||
"*.ipynb": "jupyter.notebook.ipynb"
|
||
},
|
||
"workbench.sideBar.location": "left",
|
||
"workbench.panel.defaultLocation": "bottom",
|
||
"workbench.editor.highlightModifiedTabs": true,
|
||
"workbench.settings.enableNaturalLanguageSearch": false,
|
||
#+END_SRC
|
||
|
||
**** Editor
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"editor.fontFamily": "'MonaspiceNe NF'",
|
||
"editor.fontSize": 14,
|
||
"editor.fontLigatures": "'ss01', 'ss02', 'ss03', 'ss04', 'ss05', 'ss06', 'ss07', 'ss08', 'calt', 'dlig'",
|
||
"editor.formatOnSave": true,
|
||
"editor.formatOnSaveMode": "modifications",
|
||
"editor.formatOnPaste": true,
|
||
"editor.linkedEditing": true,
|
||
"editor.lineNumbers": "on",
|
||
"editor.cursorBlinking": "phase",
|
||
"editor.cursorSmoothCaretAnimation": "on",
|
||
"editor.quickSuggestionsDelay": 0,
|
||
"editor.quickSuggestions": {
|
||
"other": true,
|
||
"comments": true,
|
||
"strings": true
|
||
},
|
||
"editor.suggestSelection": "first",
|
||
"editor.rulers": [
|
||
110
|
||
],
|
||
"editor.wordWrap": "on",
|
||
"editor.minimap.enabled": false,
|
||
"editor.smoothScrolling": true,
|
||
"editor.tabSize": 4,
|
||
"editor.insertSpaces": true,
|
||
"editor.renderWhitespace": "all",
|
||
"editor.bracketPairColorization.enabled": true,
|
||
"editor.guides.bracketPairs": "active",
|
||
"editor.tokenColorCustomizations": {
|
||
"textMateRules": [
|
||
{
|
||
"scope": [
|
||
//following will be in italic (=FlottFlott)
|
||
"comment",
|
||
"entity.name.type.class", //class names
|
||
"keyword", //import, export, return…
|
||
"constant", //String, Number, Boolean…, this, super
|
||
"storage.modifier", //static keyword
|
||
"storage.type.class.js", //class keyword
|
||
],
|
||
"settings": {
|
||
"fontStyle": "italic"
|
||
}
|
||
},
|
||
{
|
||
"scope": [
|
||
//following will be excluded from italics (VSCode has some defaults for italics)
|
||
"invalid",
|
||
"keyword.operator",
|
||
"constant.numeric.css",
|
||
"keyword.other.unit.px.css",
|
||
"constant.numeric.decimal.js",
|
||
"constant.numeric.json"
|
||
],
|
||
"settings": {
|
||
"fontStyle": ""
|
||
}
|
||
}
|
||
]
|
||
},
|
||
#+END_SRC
|
||
|
||
**** Explorer
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"explorer.autoReveal": false,
|
||
"explorer.confirmDelete": false,
|
||
"explorer.confirmDragAndDrop": false,
|
||
#+END_SRC
|
||
|
||
**** Files
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"files.trimTrailingWhitespace": true,
|
||
"files.insertFinalNewline": true,
|
||
"files.trimFinalNewlines": true,
|
||
"files.associations": {
|
||
"*.rasi": "css"
|
||
},
|
||
#+END_SRC
|
||
|
||
**** Vim
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"vim.insertModeKeyBindings": [
|
||
{
|
||
// easier insert mode exit
|
||
"before": ["j", "k"],
|
||
"after": ["<Esc>"]
|
||
},
|
||
],
|
||
"vim.normalModeKeyBindings": [
|
||
{
|
||
// go to definition
|
||
"before": ["g", "D"],
|
||
"commands": ["editor.action.revealDefintionsAside"],
|
||
},
|
||
],
|
||
"vim.normalModeKeyBindingsNonRecursive": [
|
||
{
|
||
// open sidebar
|
||
"before": ["<leader>", "t"],
|
||
"commands": ["workbench.action.toggleSidebarVisibility"],
|
||
},
|
||
{
|
||
// show current file in explorer
|
||
"before": ["<leader>", "f"],
|
||
"commands": ["revealInExplorer"],
|
||
},
|
||
{
|
||
// toggle comment on current line
|
||
"before": ["<leader>", "c"],
|
||
"commands": [
|
||
"editor.action.commentLine",
|
||
"extension.vim_escape"
|
||
],
|
||
},
|
||
{
|
||
// rename symbol
|
||
"before": ["<leader>", "r", "e"],
|
||
"commands": ["editor.action.rename"],
|
||
},
|
||
{
|
||
// show all symbols
|
||
"before": ["<leader>", "o", "g"],
|
||
"commands": ["workbench.action.showAllSymbols"],
|
||
},
|
||
{
|
||
// show editors in active group
|
||
"before": ["<leader>", "o", "o"],
|
||
"commands": ["workbench.action.showEditorsInActiveGroup"],
|
||
},
|
||
{
|
||
// quick open a file
|
||
"before": ["<leader>", "o", "p"],
|
||
"commands": ["workbench.action.quickOpen"],
|
||
},
|
||
],
|
||
"vim.visualModeKeyBindings": [
|
||
{
|
||
"before": ["<leader>", "c"],
|
||
"commands": ["editor.action.commentLine"],
|
||
"when": "editorTextFocus && !editorReadonly"
|
||
}
|
||
],
|
||
"vim.hlsearch": true,
|
||
"vim.leader": "\\",
|
||
"vim.easymotion": true,
|
||
"vim.surround": true,
|
||
"vim.useSystemClipboard": true,
|
||
#+END_SRC
|
||
|
||
**** Terminal
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"terminal.integrated.cursorStyle": "line",
|
||
"terminal.integrated.cursorBlinking": true,
|
||
"terminal.integrated.fontFamily": "'MonaspiceNe NF'",
|
||
"terminal.integrated.defaultProfile.linux": "bash",
|
||
#+END_SRC
|
||
|
||
**** Language Specific
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"[javascript]": {
|
||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||
},
|
||
"[html]": {
|
||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||
},
|
||
"[latex]": {
|
||
"editor.defaultFormatter": "James-Yu.latex-workshop"
|
||
},
|
||
"[cpp]": {
|
||
"editor.defaultFormatter": "ms-vscode.cpptools"
|
||
},
|
||
"[python]": {
|
||
"editor.defaultFormatter": "ms-python.python"
|
||
},
|
||
"python.linting.pylintEnabled": true,
|
||
"python.linting.enabled": true,
|
||
"python.languageServer": "Pylance",
|
||
#+END_SRC
|
||
|
||
**** Todo Tree
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"todo-tree.regex.regex": "(//|#|<!--|;|/\\*|^|^\\s*(-|\\d+.))\\s*($TAGS)",
|
||
"todo-tree.tree.showScanModeButton": false,
|
||
"todo-tree.general.tags": [
|
||
"BUG",
|
||
"HACK",
|
||
"FIXME",
|
||
"TODO",
|
||
"XXX",
|
||
"DONE",
|
||
"[ ]",
|
||
"[x]"
|
||
],
|
||
#+END_SRC
|
||
|
||
**** Prettier
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"prettier.endOfLine": "auto",
|
||
"prettier.proseWrap": "always",
|
||
"prettier.tabWidth": 4,
|
||
"prettier.useTabs": true,
|
||
#+END_SRC
|
||
|
||
**** Live Server
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"liveServer.settings.donotVerifyTags": true,
|
||
"liveServer.settings.donotShowInfoMsg": true,
|
||
#+END_SRC
|
||
|
||
**** Latex Workshop
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"latex-workshop.view.pdf.viewer": "tab",
|
||
#+END_SRC
|
||
|
||
**** Jupyter
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"jupyter.sendSelectionToInteractiveWindow": false,
|
||
"jupyter.alwaysTrustNotebooks": true,
|
||
#+END_SRC
|
||
|
||
**** Git
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"git.autofetch": true,
|
||
#+END_SRC
|
||
|
||
**** CMake
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"cmake.configureOnOpen": false,
|
||
#+END_SRC
|
||
|
||
**** Diff Editor
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"diffEditor.ignoreTrimWhitespace": false,
|
||
#+END_SRC
|
||
|
||
**** Project Manager
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"projectManager.git.baseFolders": [
|
||
"/home/sravan/Git",
|
||
"/home/sravan/.config"
|
||
],
|
||
#+END_SRC
|
||
|
||
**** VS Icons
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"vsicons.dontShowNewVersionMessage": true,
|
||
#+END_SRC
|
||
|
||
**** Telemetry
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"telemetry.enableTelemetry": false,
|
||
"telemetry.enableCrashReporter": false,
|
||
#+END_SRC
|
||
|
||
**** Security
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"security.workspace.trust.untrustedFiles": "open",
|
||
#+END_SRC
|
||
|
||
**** Peacock
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"peacock.favoriteColors": [
|
||
{
|
||
"name": "Dark",
|
||
"value": "#44475a"
|
||
},
|
||
{
|
||
"name": "Light",
|
||
"value": "#f8f8f2"
|
||
},
|
||
{
|
||
"name": "Purple",
|
||
"value": "#6272a4"
|
||
},
|
||
{
|
||
"name": "Cyan",
|
||
"value": "#8be9fd"
|
||
},
|
||
{
|
||
"name": "Green",
|
||
"value": "#50fa7b"
|
||
},
|
||
{
|
||
"name": "Orange",
|
||
"value": "#ffb86c"
|
||
},
|
||
{
|
||
"name": "Pink",
|
||
"value": "#ff79c6"
|
||
},
|
||
{
|
||
"name": "Purple",
|
||
"value": "#bd93f9"
|
||
},
|
||
{
|
||
"name": "Red",
|
||
"value": "#ff5555"
|
||
},
|
||
{
|
||
"name": "Yellow",
|
||
"value": "#f1fa8c"
|
||
},
|
||
{
|
||
"name": "Purple",
|
||
"value": "#6272a4"
|
||
}
|
||
],
|
||
"peacock.affectTabActiveBorder": true,
|
||
#+END_SRC
|
||
|
||
**** Auto Build Marlin
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
"auto-build.defaultEnv.name": "STM32F103RE_creality",
|
||
"auto-build.build.reveal": false,
|
||
"auto-build.build.silent": false,
|
||
"platformio-ide.autoOpenPlatformIOIniFile": false,
|
||
#+END_SRC
|
||
|
||
**** Close Braces
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/settings.json
|
||
}
|
||
#+END_SRC
|
||
|
||
*** Keybindings
|
||
|
||
#+BEGIN_SRC json :tangle vscode/.config/Code/User/keybindings.json
|
||
[
|
||
{
|
||
// restore indenting functionality in normal mode
|
||
"key": "tab",
|
||
"command": "tab",
|
||
"when": "editorTextFocus && !editorTabMovesFocus"
|
||
},
|
||
{
|
||
// restore indenting functionality in normal mode
|
||
"key": "shift+tab",
|
||
"command": "outdent",
|
||
"when": "editorTextFocus && !editorTabMovesFocus"
|
||
},
|
||
{
|
||
// switch to left window
|
||
"key": "ctrl+h",
|
||
"command": "workbench.action.focusLeftGroup",
|
||
"when": "editorTextFocus && vim.active && vim.mode != 'Insert'"
|
||
},
|
||
{
|
||
// switch to right window
|
||
"key": "ctrl+l",
|
||
"command": "workbench.action.focusRightGroup",
|
||
"when": "editorTextFocus && vim.active && vim.mode != 'Insert'"
|
||
},
|
||
{
|
||
// switch to above window
|
||
"key": "ctrl+k",
|
||
"command": "workbench.action.focusAboveGroup",
|
||
"when": "editorTextFocus && vim.active && vim.mode != 'Insert'"
|
||
},
|
||
{
|
||
// switch to below window
|
||
"key": "ctrl+j",
|
||
"command": "workbench.action.focusBelowGroup",
|
||
"when": "editorTextFocus && vim.active && vim.mode != 'Insert'"
|
||
},
|
||
{
|
||
// toggle sidebar when in sidebar
|
||
"key": "\\ t",
|
||
"command": "workbench.action.toggleSidebarVisibility",
|
||
"when": "!editorTextFocus"
|
||
},
|
||
{
|
||
// collapse list in sidebar
|
||
"key": "ctrl+h",
|
||
"command": "list.collapse",
|
||
"when": "listFocus && !inputFocus"
|
||
},
|
||
{
|
||
// expand list in sidebar
|
||
"key": "ctrl+l",
|
||
"command": "list.expand",
|
||
"when": "listFocus && !inputFocus"
|
||
},
|
||
{
|
||
// move up list
|
||
"key": "ctrl+k",
|
||
"command": "list.focusUp",
|
||
"when": "listFocus && !inputFocus"
|
||
},
|
||
{
|
||
// move down list
|
||
"key": "ctrl+j",
|
||
"command": "list.focusDown",
|
||
"when": "listFocus && !inputFocus"
|
||
},
|
||
{
|
||
// next item in suggestion widget
|
||
"key": "ctrl+j",
|
||
"command": "selectNextSuggestion",
|
||
"when": "suggestWidgetVisible"
|
||
},
|
||
{
|
||
// previous item in suggestion widget
|
||
"key": "ctrl+k",
|
||
"command": "selectPrevSuggestion",
|
||
"when": "suggestWidgetVisible"
|
||
},
|
||
{
|
||
// next item in quick open
|
||
"key": "ctrl+j",
|
||
"command": "workbench.action.quickOpenSelectNext",
|
||
"when": "inQuickOpen"
|
||
},
|
||
{
|
||
// previous item in quick open
|
||
"key": "ctrl+k",
|
||
"command": "workbench.action.quickOpenSelectPrevious",
|
||
"when": "inQuickOpen"
|
||
}
|
||
]
|
||
#+END_SRC
|
||
|
||
* Gaming
|
||
|
||
** Scripts
|
||
|
||
These are scripts that should be run from Lutris when launching or exiting a game.
|
||
|
||
*** Pre-Launch Script
|
||
|
||
*Preferences > System options > Pre-launch script*
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle gaming/.scripts/game_launch.sh
|
||
if [ $XDG_SESSION_DESKTOP == "dwm" ]; then
|
||
$HOME/.scripts/picom.sh --off &
|
||
/usr/bin/xfconf-query -c xfce4-power-manager -p /xfce4-power-manager/presentation-mode -s true &
|
||
fi
|
||
|
||
$HOME/.scripts/cpu-gpu.sh --cpu-profile-performance &
|
||
$HOME/.scripts/cpu-gpu.sh --gpu-profile-performance &
|
||
$HOME/.scripts/dunst.sh --pause &
|
||
#+END_SRC
|
||
|
||
*** Post-Exit Script
|
||
|
||
*Preferences > System options > Post-exit script*
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle gaming/.scripts/game_exit.sh
|
||
if [ $XDG_SESSION_DESKTOP == "dwm" ]; then
|
||
$HOME/.scripts/picom.sh --on &
|
||
/usr/bin/xfconf-query -c xfce4-power-manager -p /xfce4-power-manager/presentation-mode -s false &
|
||
fi
|
||
|
||
$HOME/.scripts/dunst.sh --unpause &
|
||
$HOME/.scripts/cpu-gpu.sh --cpu-profile-balanced &
|
||
$HOME/.scripts/cpu-gpu.sh --gpu-profile-adaptive &
|
||
#+END_SRC
|
||
|
||
*** PlayStation 5 (DualSense) to Xbox 360 Controller Button Mapping
|
||
|
||
Emulate DualSense controller as an Xbox 360 controller.
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle gaming/.scripts/dualsense_to_xbox_360_controller.sh
|
||
xboxdrv \
|
||
--evdev /dev/input/by-id/usb-Sony_Interactive_Entertainment_Wireless_Controller-if03-event-joystick \
|
||
--evdev-absmap ABS_HAT0X=dpad_x,ABS_HAT0Y=dpad_y,ABS_X=X1,ABS_Y=Y1,ABS_RX=X2,ABS_RY=Y2,ABS_Z=LT,ABS_RZ=RT \
|
||
--evdev-keymap BTN_SOUTH=A,BTN_EAST=B,BTN_NORTH=Y,BTN_WEST=X,BTN_START=start,BTN_MODE=guide,BTN_SELECT=back \
|
||
--evdev-keymap BTN_TL=LB,BTN_TR=RB,BTN_TL2=LT,BTN_TR2=RT,BTN_THUMBL=TL,BTN_THUMBR=TR \
|
||
--axismap -y1=y1,-y2=y2 \
|
||
--mimic-xpad \
|
||
--silent
|
||
#+END_SRC
|
||
|
||
** Gamemode
|
||
|
||
*** General
|
||
|
||
#+BEGIN_SRC conf :tangle gaming/.config/gamemode.ini
|
||
[general]
|
||
; The reaper thread will check every 5 seconds for exited clients, for config file changes, and for the CPU/iGPU power balance
|
||
reaper_freq=5
|
||
|
||
; The desired governor is used when entering GameMode instead of "performance"
|
||
desiredgov=performance
|
||
; The default governor is used when leaving GameMode instead of restoring the original value
|
||
;defaultgov=powersave
|
||
|
||
; The iGPU desired governor is used when the integrated GPU is under heavy load
|
||
igpu_desiredgov=powersave
|
||
; Threshold to use to decide when the integrated GPU is under heavy load.
|
||
; This is a ratio of iGPU Watts / CPU Watts which is used to determine when the
|
||
; integraged GPU is under heavy enough load to justify switching to
|
||
; igpu_desiredgov. Set this to -1 to disable all iGPU checking and always
|
||
; use desiredgov for games.
|
||
igpu_power_threshold=0.3
|
||
|
||
; GameMode can change the scheduler policy to SCHED_ISO on kernels which support it (currently
|
||
; not supported by upstream kernels). Can be set to "auto", "on" or "off". "auto" will enable
|
||
; with 4 or more CPU cores. "on" will always enable. Defaults to "off".
|
||
softrealtime=off
|
||
|
||
; GameMode can renice game processes. You can put any value between 0 and 20 here, the value
|
||
; will be negated and applied as a nice value (0 means no change). Defaults to 0.
|
||
; To use this feature, the user must be added to the gamemode group (and then rebooted):
|
||
; sudo usermod -aG gamemode $(whoami)
|
||
renice=10
|
||
|
||
; By default, GameMode adjusts the iopriority of clients to BE/0, you can put any value
|
||
; between 0 and 7 here (with 0 being highest priority), or one of the special values
|
||
; "off" (to disable) or "reset" (to restore Linux default behavior based on CPU priority),
|
||
; currently, only the best-effort class is supported thus you cannot set it here
|
||
ioprio=0
|
||
|
||
; Sets whether gamemode will inhibit the screensaver when active
|
||
; Defaults to 1
|
||
inhibit_screensaver=1
|
||
|
||
; Sets whether gamemode will disable split lock mitigation when active
|
||
; Defaults to 1
|
||
disable_splitlock=1
|
||
#+END_SRC
|
||
|
||
*** Filter
|
||
|
||
#+BEGIN_SRC conf :tangle gaming/.config/gamemode.ini
|
||
[filter]
|
||
; If "whitelist" entry has a value(s)
|
||
; gamemode will reject anything not in the whitelist
|
||
;whitelist=RiseOfTheTombRaider
|
||
|
||
; Gamemode will always reject anything in the blacklist
|
||
;blacklist=HalfLife3
|
||
; glxgears
|
||
#+END_SRC
|
||
|
||
*** GPU
|
||
|
||
#+BEGIN_SRC conf :tangle gaming/.config/gamemode.ini
|
||
[gpu]
|
||
; Here Be Dragons!
|
||
; Warning: Use these settings at your own risk
|
||
; Any damage to hardware incurred due to this feature is your responsibility and yours alone
|
||
; It is also highly recommended you try these settings out first manually to find the sweet spots
|
||
|
||
; Setting this to the keyphrase "accept-responsibility" will allow gamemode to apply GPU optimisations such as overclocks
|
||
;apply_gpu_optimisations=0
|
||
|
||
; The DRM device number on the system (usually 0), ie. the number in /sys/class/drm/card0/
|
||
;gpu_device=0
|
||
|
||
; Nvidia specific settings
|
||
; Requires the coolbits extension activated in nvidia-xconfig
|
||
; This corresponds to the desired GPUPowerMizerMode
|
||
; "Adaptive"=0 "Prefer Maximum Performance"=1 and "Auto"=2
|
||
; See NV_CTRL_GPU_POWER_MIZER_MODE and friends in https://github.com/NVIDIA/nvidia-settings/blob/master/src/libXNVCtrl/NVCtrl.h
|
||
;nv_powermizer_mode=1
|
||
|
||
; These will modify the core and mem clocks of the highest perf state in the Nvidia PowerMizer
|
||
; They are measured as Mhz offsets from the baseline, 0 will reset values to default, -1 or unset will not modify values
|
||
;nv_core_clock_mhz_offset=0
|
||
;nv_mem_clock_mhz_offset=0
|
||
|
||
; AMD specific settings
|
||
; Requires a relatively up to date AMDGPU kernel module
|
||
; See: https://dri.freedesktop.org/docs/drm/gpu/amdgpu.html#gpu-power-thermal-controls-and-monitoring
|
||
; It is also highly recommended you use lm-sensors (or other available tools) to verify card temperatures
|
||
; This corresponds to power_dpm_force_performance_level, "manual" is not supported for now
|
||
;amd_performance_level=high
|
||
#+END_SRC
|
||
|
||
*** CPU
|
||
|
||
#+BEGIN_SRC conf :tangle gaming/.config/gamemode.ini
|
||
[cpu]
|
||
; Parking or Pinning can be enabled with either "yes", "true" or "1" and disabled with "no", "false" or "0".
|
||
; Either can also be set to a specific list of cores to park or pin, comma separated list where "-" denotes
|
||
; a range. E.g "park_cores=1,8-15" would park cores 1 and 8 to 15.
|
||
; The default is uncommented is to disable parking but enable pinning. If either is enabled the code will
|
||
; currently only properly autodetect Ryzen 7900x3d, 7950x3d and Intel CPU:s with E- and P-cores.
|
||
;park_cores=no
|
||
;pin_cores=yes
|
||
#+END_SRC
|
||
|
||
*** Supervisor
|
||
|
||
#+BEGIN_SRC conf :tangle gaming/.config/gamemode.ini
|
||
[supervisor]
|
||
; This section controls the new gamemode functions gamemode_request_start_for and gamemode_request_end_for
|
||
; The whilelist and blacklist control which supervisor programs are allowed to make the above requests
|
||
;supervisor_whitelist=
|
||
;supervisor_blacklist=
|
||
|
||
; In case you want to allow a supervisor to take full control of gamemode, this option can be set
|
||
; This will only allow gamemode clients to be registered by using the above functions by a supervisor client
|
||
;require_supervisor=0
|
||
#+END_SRC
|
||
|
||
*** Custom
|
||
|
||
#+BEGIN_SRC conf :tangle gaming/.config/gamemode.ini
|
||
[custom]
|
||
; Custom scripts (executed using the shell) when gamemode starts and ends
|
||
;start=notify-send "GameMode started"
|
||
; /home/me/bin/stop_foldingathome.sh
|
||
|
||
;end=notify-send "GameMode ended"
|
||
; /home/me/bin/start_foldingathome.sh
|
||
|
||
; Timeout for scripts (seconds). Scripts will be killed if they do not complete within this time.
|
||
;script_timeout=10
|
||
#+END_SRC
|
||
|
||
* Media
|
||
|
||
** mpv
|
||
|
||
*** General Settings
|
||
|
||
The commented example options usually do _not_ set the default values. Call mpv with ~--list-options~ to see the default values for most options. There is no builtin or example mpv.conf with all the defaults.
|
||
|
||
|
||
Configuration files are read system-wide from ~/usr/local/etc/mpv.conf~ and per-user from ~~/.config/mpv/mpv.conf~, where per-user settings override system-wide settings, all of which are overridden by the command line.
|
||
|
||
Configuration file settings and the command line options use the same underlying mechanisms. Most options can be put into the configuration file by dropping the preceding '--'. See the man page for a complete list of options.
|
||
|
||
Lines starting with '#' are comments and are ignored.
|
||
|
||
See the CONFIGURATION FILES section in the man page for a detailed description of the syntax.
|
||
|
||
Profiles should be placed at the bottom of the configuration file to ensure that settings wanted as defaults are not restricted to specific profiles.
|
||
|
||
**** Video Settings
|
||
|
||
#+BEGIN_SRC conf :tangle mpv/.config/mpv/mpv.conf
|
||
# Start in fullscreen mode by default.
|
||
#fs=yes
|
||
|
||
# force starting with centered window
|
||
#geometry=50%:50%
|
||
|
||
# don't allow a new window to have a size larger than 90% of the screen size
|
||
#autofit-larger=90%x90%
|
||
|
||
# Do not close the window on exit.
|
||
#keep-open=yes
|
||
|
||
# Do not wait with showing the video window until it has loaded. (This will
|
||
# resize the window once video is loaded. Also always shows a window with
|
||
# audio.)
|
||
#force-window=immediate
|
||
|
||
# Disable the On Screen Controller (OSC).
|
||
#osc=no
|
||
|
||
# Keep the player window on top of all other windows.
|
||
#ontop=yes
|
||
|
||
# Specify fast video rendering preset (for --vo=<gpu|gpu-next> only)
|
||
# Recommended for mobile devices or older hardware with limited processing power
|
||
#profile=fast
|
||
|
||
# Specify high quality video rendering preset (for --vo=<gpu|gpu-next> only)
|
||
# Offers superior image fidelity and visual quality for an enhanced viewing
|
||
# experience on capable hardware
|
||
profile=gpu-hq
|
||
|
||
# Force video to lock on the display's refresh rate, and change video and audio
|
||
# speed to some degree to ensure synchronous playback - can cause problems
|
||
# with some drivers and desktop environments.
|
||
#video-sync=display-resample
|
||
|
||
# Enable hardware decoding if available. Often, this does not work with all
|
||
# video outputs, but should work well with default settings on most systems.
|
||
# If performance or energy usage is an issue, forcing the vdpau or vaapi VOs
|
||
# may or may not help.
|
||
hwdec=auto
|
||
#+END_SRC
|
||
|
||
**** Audio Settings
|
||
|
||
#+BEGIN_SRC conf :tangle mpv/.config/mpv/mpv.conf
|
||
# Specify default audio device. You can list devices with: --audio-device=help
|
||
# The option takes the device string (the stuff between the '...').
|
||
#audio-device=alsa/default
|
||
|
||
# Do not filter audio to keep pitch when changing playback speed.
|
||
#audio-pitch-correction=no
|
||
|
||
# Output 5.1 audio natively, and upmix/downmix audio with a different format.
|
||
#audio-channels=5.1
|
||
# Disable any automatic remix, _if_ the audio output accepts the audio format.
|
||
# of the currently played file. See caveats mentioned in the manpage.
|
||
# (The default is "auto-safe", see manpage.)
|
||
#audio-channels=auto
|
||
#+END_SRC
|
||
|
||
**** Other Settings
|
||
|
||
#+BEGIN_SRC conf :tangle mpv/.config/mpv/mpv.conf
|
||
# Pretend to be a web browser. Might fix playback with some streaming sites,
|
||
# but also will break with shoutcast streams.
|
||
#user-agent="Mozilla/5.0"
|
||
|
||
# cache settings
|
||
#
|
||
# Use a large seekable RAM cache even for local input.
|
||
#cache=yes
|
||
#
|
||
# Use extra large RAM cache (needs cache=yes to make it useful).
|
||
#demuxer-max-bytes=500M
|
||
#demuxer-max-back-bytes=100M
|
||
#
|
||
# Disable the behavior that the player will pause if the cache goes below a
|
||
# certain fill size.
|
||
#cache-pause=no
|
||
#
|
||
# Store cache payload on the hard disk instead of in RAM. (This may negatively
|
||
# impact performance unless used for slow input such as network.)
|
||
#cache-dir=~/.cache/
|
||
#cache-on-disk=yes
|
||
|
||
# Display English subtitles if available.
|
||
#slang=en
|
||
|
||
# Play Finnish audio if available, fall back to English otherwise.
|
||
#alang=fi,en
|
||
|
||
# Change subtitle encoding. For Arabic subtitles use 'cp1256'.
|
||
# If the file seems to be valid UTF-8, prefer UTF-8.
|
||
# (You can add '+' in front of the codepage to force it.)
|
||
#sub-codepage=cp1256
|
||
|
||
# You can also include other configuration files.
|
||
#include=/path/to/the/file/you/want/to/include
|
||
|
||
# Enable fuzzy searching
|
||
sub-auto=fuzzy
|
||
|
||
# Change font
|
||
# sub-font="fontName"
|
||
|
||
# Bold the subtitles to increase readability
|
||
sub-bold=yes
|
||
#+END_SRC
|
||
|
||
**** Profiles
|
||
|
||
#+BEGIN_SRC conf :tangle mpv/.config/mpv/mpv.conf
|
||
# The options declared as part of profiles override global default settings,
|
||
# but only take effect when the profile is active.
|
||
|
||
# The following profile can be enabled on the command line with: --profile=eye-cancer
|
||
|
||
#[eye-cancer]
|
||
#sharpen=5
|
||
|
||
[gpu-hq]
|
||
scale=ewa_lanczossharp
|
||
cscale=ewa_lanczossharp
|
||
video-sync=display-resample
|
||
interpolation
|
||
tscale=oversample
|
||
#+END_SRC
|
||
|
||
*** Key Bindings
|
||
|
||
Lines starting with # are comments. Use SHARP to assign the # key. Copy this file and uncomment and edit the bindings you want to change.
|
||
|
||
List of commands and further details: DOCS/man/input.rst
|
||
List of special keys: --input-keylist
|
||
Keybindings testing mode: mpv --input-test --force-window --idle
|
||
|
||
Use 'ignore' to unbind a key fully (e.g. 'ctrl+a ignore').
|
||
|
||
Strings need to be quoted and escaped:
|
||
KEY show-text "This is a single backslash: \\ and a quote: \" !"
|
||
|
||
You can use modifier-key combinations like Shift+Left or Ctrl+Alt+x with
|
||
the modifiers Shift, Ctrl, Alt and Meta (may not work on the terminal).
|
||
|
||
The default keybindings are hardcoded into the mpv binary. You can disable them completely with: --no-input-default-bindings
|
||
|
||
Developer note:
|
||
On compilation, this file is baked into the mpv binary, and all lines are uncommented (unless '#' is followed by a space) - thus this file defines the default key bindings.
|
||
|
||
#+BEGIN_SRC conf :tangle mpv/.config/mpv/mpv.conf
|
||
# If this is enabled, treat all the following bindings as default.
|
||
#default-bindings start
|
||
|
||
#MBTN_LEFT ignore # don't do anything
|
||
#MBTN_LEFT_DBL cycle fullscreen # toggle fullscreen
|
||
#MBTN_RIGHT cycle pause # toggle pause/playback mode
|
||
#MBTN_BACK playlist-prev # skip to the previous file
|
||
#MBTN_FORWARD playlist-next # skip to the next file
|
||
|
||
# Mouse wheels, touchpad or other input devices that have axes
|
||
# if the input devices supports precise scrolling it will also scale the
|
||
# numeric value accordingly
|
||
#WHEEL_UP add volume 2
|
||
#WHEEL_DOWN add volume -2
|
||
#WHEEL_LEFT seek -10 # seek 10 seconds backward
|
||
#WHEEL_RIGHT seek 10 # seek 10 seconds forward
|
||
|
||
## Seek units are in seconds, but note that these are limited by keyframes
|
||
#RIGHT seek 5 # seek 5 seconds forward
|
||
#LEFT seek -5 # seek 5 seconds backward
|
||
#UP seek 60 # seek 1 minute forward
|
||
#DOWN seek -60 # seek 1 minute backward
|
||
# Do smaller, always exact (non-keyframe-limited), seeks with shift.
|
||
# Don't show them on the OSD (no-osd).
|
||
#Shift+RIGHT no-osd seek 1 exact # seek exactly 1 second forward
|
||
#Shift+LEFT no-osd seek -1 exact # seek exactly 1 second backward
|
||
#Shift+UP no-osd seek 5 exact # seek exactly 5 seconds forward
|
||
#Shift+DOWN no-osd seek -5 exact # seek exactly 5 seconds backward
|
||
#Ctrl+LEFT no-osd sub-seek -1 # seek to the previous subtitle
|
||
#Ctrl+RIGHT no-osd sub-seek 1 # seek to the next subtitle
|
||
#Ctrl+Shift+LEFT sub-step -1 # change subtitle timing such that the previous subtitle is displayed
|
||
#Ctrl+Shift+RIGHT sub-step 1 # change subtitle timing such that the next subtitle is displayed
|
||
#Alt+left add video-pan-x 0.1 # move the video right
|
||
#Alt+right add video-pan-x -0.1 # move the video left
|
||
#Alt+up add video-pan-y 0.1 # move the video down
|
||
#Alt+down add video-pan-y -0.1 # move the video up
|
||
#Alt++ add video-zoom 0.1 # zoom in
|
||
#ZOOMIN add video-zoom 0.1 # zoom in
|
||
#Alt+- add video-zoom -0.1 # zoom out
|
||
#ZOOMOUT add video-zoom -0.1 # zoom out
|
||
#Alt+BS set video-zoom 0 ; set video-pan-x 0 ; set video-pan-y 0 # reset zoom and pan settings
|
||
#PGUP add chapter 1 # seek to the next chapter
|
||
#PGDWN add chapter -1 # seek to the previous chapter
|
||
#Shift+PGUP seek 600 # seek 10 minutes forward
|
||
#Shift+PGDWN seek -600 # seek 10 minutes backward
|
||
#[ multiply speed 1/1.1 # decrease the playback speed
|
||
#] multiply speed 1.1 # increase the playback speed
|
||
#{ multiply speed 0.5 # halve the playback speed
|
||
#} multiply speed 2.0 # double the playback speed
|
||
#BS set speed 1.0 # reset the speed to normal
|
||
#Shift+BS revert-seek # undo the previous (or marked) seek
|
||
#Shift+Ctrl+BS revert-seek mark # mark the position for revert-seek
|
||
#q quit
|
||
#Q quit-watch-later # exit and remember the playback position
|
||
#q {encode} quit 4
|
||
#ESC set fullscreen no # leave fullscreen
|
||
#ESC {encode} quit 4
|
||
#p cycle pause # toggle pause/playback mode
|
||
#. frame-step # advance one frame and pause
|
||
#, frame-back-step # go back by one frame and pause
|
||
#SPACE cycle pause # toggle pause/playback mode
|
||
#> playlist-next # skip to the next file
|
||
#ENTER playlist-next # skip to the next file
|
||
#< playlist-prev # skip to the previous file
|
||
#O no-osd cycle-values osd-level 3 1 # toggle displaying the OSD on user interaction or always
|
||
#o show-progress # show playback progress
|
||
#P show-progress # show playback progress
|
||
#i script-binding stats/display-stats # display information and statistics
|
||
#I script-binding stats/display-stats-toggle # toggle displaying information and statistics
|
||
#` script-binding console/enable # open the console
|
||
#z add sub-delay -0.1 # shift subtitles 100 ms earlier
|
||
#Z add sub-delay +0.1 # delay subtitles by 100 ms
|
||
#x add sub-delay +0.1 # delay subtitles by 100 ms
|
||
#ctrl++ add audio-delay 0.100 # change audio/video sync by delaying the audio
|
||
#ctrl+- add audio-delay -0.100 # change audio/video sync by shifting the audio earlier
|
||
#Shift+g add sub-scale +0.1 # increase the subtitle font size
|
||
#Shift+f add sub-scale -0.1 # decrease the subtitle font size
|
||
#9 add volume -2
|
||
#/ add volume -2
|
||
#0 add volume 2
|
||
#* add volume 2
|
||
#m cycle mute # toggle mute
|
||
#1 add contrast -1
|
||
#2 add contrast 1
|
||
#3 add brightness -1
|
||
#4 add brightness 1
|
||
#5 add gamma -1
|
||
#6 add gamma 1
|
||
#7 add saturation -1
|
||
#8 add saturation 1
|
||
#Alt+0 set current-window-scale 0.5 # halve the window size
|
||
#Alt+1 set current-window-scale 1.0 # reset the window size
|
||
#Alt+2 set current-window-scale 2.0 # double the window size
|
||
#d cycle deinterlace # toggle the deinterlacing filter
|
||
#r add sub-pos -1 # move subtitles up
|
||
#R add sub-pos +1 # move subtitles down
|
||
#t add sub-pos +1 # move subtitles down
|
||
#v cycle sub-visibility # hide or show the subtitles
|
||
#Alt+v cycle secondary-sub-visibility # hide or show the secondary subtitles
|
||
#V cycle sub-ass-vsfilter-aspect-compat # toggle stretching SSA/ASS subtitles with anamorphic videos to match the historical renderer
|
||
#u cycle-values sub-ass-override "force" "yes" # toggle overriding SSA/ASS subtitle styles with the normal styles
|
||
#j cycle sub # switch subtitle track
|
||
#J cycle sub down # switch subtitle track backwards
|
||
#SHARP cycle audio # switch audio track
|
||
#_ cycle video # switch video track
|
||
#T cycle ontop # toggle placing the video on top of other windows
|
||
#f cycle fullscreen # toggle fullscreen
|
||
#s screenshot # take a screenshot of the video in its original resolution with subtitles
|
||
#S screenshot video # take a screenshot of the video in its original resolution without subtitles
|
||
#Ctrl+s screenshot window # take a screenshot of the window with OSD and subtitles
|
||
#Alt+s screenshot each-frame # automatically screenshot every frame; issue this command again to stop taking screenshots
|
||
#w add panscan -0.1 # decrease panscan
|
||
#W add panscan +0.1 # shrink black bars by cropping the video
|
||
#e add panscan +0.1 # shrink black bars by cropping the video
|
||
#A cycle-values video-aspect-override "16:9" "4:3" "2.35:1" "-1" # cycle the video aspect ratio ("-1" is the container aspect)
|
||
#POWER quit
|
||
#PLAY cycle pause # toggle pause/playback mode
|
||
#PAUSE cycle pause # toggle pause/playback mode
|
||
#PLAYPAUSE cycle pause # toggle pause/playback mode
|
||
#PLAYONLY set pause no # unpause
|
||
#PAUSEONLY set pause yes # pause
|
||
#STOP quit
|
||
#FORWARD seek 60 # seek 1 minute forward
|
||
#REWIND seek -60 # seek 1 minute backward
|
||
#NEXT playlist-next # skip to the next file
|
||
#PREV playlist-prev # skip to the previous file
|
||
#VOLUME_UP add volume 2
|
||
#VOLUME_DOWN add volume -2
|
||
#MUTE cycle mute # toggle mute
|
||
#CLOSE_WIN quit
|
||
#CLOSE_WIN {encode} quit 4
|
||
#ctrl+w quit
|
||
#E cycle edition # switch edition
|
||
#l ab-loop # set/clear A-B loop points
|
||
#L cycle-values loop-file "inf" "no" # toggle infinite looping
|
||
#ctrl+c quit 4
|
||
#DEL script-binding osc/visibility # cycle OSC visibility between never, auto (mouse-move) and always
|
||
#ctrl+h cycle-values hwdec "auto-safe" "no" # toggle hardware decoding
|
||
#F8 show-text ${playlist} # show the playlist
|
||
#F9 show-text ${track-list} # show the list of video, audio and sub tracks
|
||
|
||
#
|
||
# Legacy bindings (may or may not be removed in the future)
|
||
#
|
||
#! add chapter -1 # seek to the previous chapter
|
||
#@ add chapter 1 # seek to the next chapter
|
||
|
||
#
|
||
# Not assigned by default
|
||
# (not an exhaustive list of unbound commands)
|
||
#
|
||
|
||
# ? cycle sub-forced-events-only # display only DVD/PGS forced subtitle events
|
||
# ? stop # stop playback (quit or enter idle mode)
|
||
#+END_SRC
|
||
|
||
* Backups & Syncing
|
||
|
||
** Backups
|
||
|
||
*** Rsync Options
|
||
|
||
| Option | Description |
|
||
| ------ | ----------- |
|
||
| -a | quick way of saying you want recursion and want to perserve almost everything |
|
||
| -v | increases the amount of information you are given during the transfer |
|
||
| -L | transform symlink into referent file/dir |
|
||
| --progress | show progress during transfer |
|
||
| --delete | delete extraneous files from dest dirs |
|
||
|
||
*** HDD
|
||
|
||
**** Root
|
||
|
||
#+BEGIN_SRC yaml :tangle snapborg/.config/snapborg/root_hdd_config.yaml
|
||
configs:
|
||
# MANDATORY: name of the snapper config
|
||
- name: root
|
||
# MANDATORY: borg repo target, e. g. backupuser@backuphost:reponame
|
||
repo: /mnt/5TB_HDD/Backups/oryp7/root
|
||
# if this is set to true, borg does not neccessarily fail when a backup fails
|
||
fault_tolerant_mode: true
|
||
# snapborg fails when the most recent snapshot transferred successfully is
|
||
# older than the time period given here. Set to '0d' to disable this behaviour
|
||
last_backup_max_age: 0d
|
||
# archive creation/storage options
|
||
storage:
|
||
# use either none or repokey encryption, defaults to none
|
||
encryption: none
|
||
# MANDATORY when using repokey: literal key passphrase or path to file
|
||
# containing the key passphrase. Ignored when using none encryption
|
||
encryption_passphrase: ~
|
||
# compression configuration, see borg manual
|
||
compression: auto,zstd,4
|
||
retention:
|
||
keep_last: 15
|
||
keep_hourly: 0
|
||
keep_daily: 7
|
||
keep_weekly: 4
|
||
keep_monthly: 1
|
||
keep_yearly: 1
|
||
# exclude patterns (see borg help patterns)
|
||
exclude_patterns: []
|
||
#+END_SRC
|
||
|
||
**** Home
|
||
|
||
#+BEGIN_SRC yaml :tangle snapborg/.config/snapborg/home_hdd_config.yaml
|
||
configs:
|
||
- name: home
|
||
# MANDATORY: borg repo target, e. g. backupuser@backuphost:reponame
|
||
repo: /mnt/5TB_HDD/Backups/oryp7/home
|
||
# if this is set to true, borg does not neccessarily fail when a backup fails
|
||
fault_tolerant_mode: true
|
||
# snapborg fails when the most recent snapshot transferred successfully is
|
||
# older than the time period given here. Set to '0d' to disable this behaviour
|
||
last_backup_max_age: 0d
|
||
# archive creation/storage options
|
||
storage:
|
||
# use either none or repokey encryption, defaults to none
|
||
encryption: none
|
||
# MANDATORY when using repokey: literal key passphrase or path to file
|
||
# containing the key passphrase. Ignored when using none encryption
|
||
encryption_passphrase: ~
|
||
# compression configuration, see borg manual
|
||
compression: auto,zstd,4
|
||
|
||
# define retention settings for borg independently from snapper
|
||
retention:
|
||
keep_last: 15
|
||
keep_hourly: 0
|
||
keep_daily: 7
|
||
keep_weekly: 4
|
||
keep_monthly: 1
|
||
keep_yearly: 1
|
||
# exclude patterns (see borg help patterns)
|
||
exclude_patterns: []
|
||
#+END_SRC
|
||
|
||
*** Fileserver
|
||
|
||
**** Root
|
||
|
||
#+BEGIN_SRC yaml :tangle snapborg/.config/snapborg/root_fileserver_config.yaml
|
||
configs:
|
||
# MANDATORY: name of the snapper config
|
||
- name: root
|
||
# MANDATORY: borg repo target, e. g. backupuser@backuphost:reponame
|
||
repo: /mnt/fileserver/Backups/oryp7/root
|
||
# if this is set to true, borg does not neccessarily fail when a backup fails
|
||
fault_tolerant_mode: true
|
||
# snapborg fails when the most recent snapshot transferred successfully is
|
||
# older than the time period given here. Set to '0d' to disable this behaviour
|
||
last_backup_max_age: 0d
|
||
# archive creation/storage options
|
||
storage:
|
||
# use either none or repokey encryption, defaults to none
|
||
encryption: none
|
||
# MANDATORY when using repokey: literal key passphrase or path to file
|
||
# containing the key passphrase. Ignored when using none encryption
|
||
encryption_passphrase: ~
|
||
# compression configuration, see borg manual
|
||
compression: auto,zstd,4
|
||
|
||
# define retention settings for borg independently from snapper
|
||
retention:
|
||
keep_last: 15
|
||
keep_hourly: 0
|
||
keep_daily: 7
|
||
keep_weekly: 4
|
||
keep_monthly: 1
|
||
keep_yearly: 1
|
||
# exclude patterns (see borg help patterns)
|
||
exclude_patterns: []
|
||
#+END_SRC
|
||
|
||
**** Home
|
||
|
||
#+BEGIN_SRC yaml :tangle snapborg/.config/snapborg/home_fileserver_config.yaml
|
||
configs:
|
||
- name: home
|
||
# MANDATORY: borg repo target, e. g. backupuser@backuphost:reponame
|
||
repo: /mnt/fileserver/Backups/oryp7/home
|
||
# if this is set to true, borg does not neccessarily fail when a backup fails
|
||
fault_tolerant_mode: true
|
||
# snapborg fails when the most recent snapshot transferred successfully is
|
||
# older than the time period given here. Set to '0d' to disable this behaviour
|
||
last_backup_max_age: 0d
|
||
# archive creation/storage options
|
||
storage:
|
||
# use either none or repokey encryption, defaults to none
|
||
encryption: none
|
||
# MANDATORY when using repokey: literal key passphrase or path to file
|
||
# containing the key passphrase. Ignored when using none encryption
|
||
encryption_passphrase: ~
|
||
# compression configuration, see borg manual
|
||
compression: auto,zstd,4
|
||
|
||
# define retention settings for borg independently from snapper
|
||
retention:
|
||
keep_last: 15
|
||
keep_hourly: 0
|
||
keep_daily: 7
|
||
keep_weekly: 4
|
||
keep_monthly: 1
|
||
keep_yearly: 1
|
||
# exclude patterns (see borg help patterns)
|
||
exclude_patterns: []
|
||
#+END_SRC
|
||
|
||
*** Rofi Menu
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle snapborg/.scripts/backup.sh
|
||
help_menu() {
|
||
echo "Main menu to launch backup scripts. Use only one argument at a time."
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" - backup-root-to-hdd"
|
||
" - backup-home-to-hdd"
|
||
" - backup-root-to-fileserver"
|
||
" - backup-home-to-fileserver"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && pkill rofi
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--backup-root-to-hdd)
|
||
kitty --hold bash -c "sudo systemctl start snapborg-backup-hdd@root.service && journalctl -f -u snapborg-backup-hdd@root.service"
|
||
;;
|
||
--backup-home-to-hdd)
|
||
kitty --hold bash -c "sudo systemctl start snapborg-backup-hdd@home.service && journalctl -f -u snapborg-backup-hdd@home.service"
|
||
;;
|
||
--backup-root-to-fileserver)
|
||
kitty --hold bash -c "sudo systemctl start snapborg-backup-fileserver@root.service && journalctl -f -u snapborg-backup-fileserver@root.service"
|
||
;;
|
||
--backup-home-to-fileserver)
|
||
kitty --hold bash -c "sudo systemctl start snapborg-backup-fileserver@home.service && journalctl -f -u snapborg-backup-fileserver@home.service"
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Syncthing
|
||
|
||
#+BEGIN_SRC systemd :tangle syncthing/.config/systemd/user/syncthing.service
|
||
[Unit]
|
||
Description=Syncthing
|
||
|
||
[Service]
|
||
Type=simple
|
||
ExecStart=/usr/bin/syncthing
|
||
Restart=on-failure
|
||
RestartSec=1
|
||
SuccessExitStatus=3 4
|
||
|
||
[Install]
|
||
WantedBy=default.target
|
||
#+END_SRC
|
||
|
||
* Hotkey Daemon
|
||
|
||
** swhkd
|
||
|
||
#+BEGIN_SRC sxhkd :tangle swhkd/.config/swhkd/swhkdrc
|
||
# Rofi Menus
|
||
super + ctrl + p
|
||
~/.scripts/control-center.sh --rofi
|
||
|
||
super + ctrl + c
|
||
cliphist list | rofi -dmenu | cliphist decode | wl-copy
|
||
|
||
super + ctrl + d
|
||
~/.scripts/brightness.sh --rofi
|
||
|
||
super + ctrl + v
|
||
~/.scripts/pactl.sh --rofi
|
||
|
||
super + ctrl + m
|
||
~/.scripts/playerctl.sh --rofi
|
||
|
||
super + ctrl + n
|
||
~/.scripts/dunst.sh --rofi
|
||
|
||
super + ctrl + q
|
||
~/.scripts/session.sh --rofi
|
||
|
||
# Volume Controls
|
||
xf86audioraisevolume
|
||
~/.scripts/pactl.sh --raise
|
||
|
||
xf86audiolowervolume
|
||
~/.scripts/pactl.sh --lower
|
||
|
||
xf86audiomute
|
||
~/.scripts/pactl.sh --mute
|
||
|
||
# Media Controls
|
||
xf86audioplay
|
||
~/.scripts/playerctl.sh --play-pause
|
||
|
||
xf86audioprev
|
||
~/.scripts/playerctl.sh --prev
|
||
|
||
xf86audionext
|
||
~/.scripts/playerctl.sh --next
|
||
|
||
# Screenshot
|
||
print
|
||
grim -g "$(slurp)" - | swappy -f -
|
||
|
||
# Brightness Controls
|
||
xf86monbrightnessup
|
||
~/.scripts/brightness.sh --raise
|
||
|
||
xf86monbrightnessdown
|
||
~/.scripts/brightness.sh --lower
|
||
#+END_SRC
|
||
|
||
* User Programs
|
||
|
||
** Mangal
|
||
|
||
#+BEGIN_SRC toml :tangle mangal/.config/mangal/mangal.toml
|
||
[anilist]
|
||
# Anilist code to use for authentication (string)
|
||
code = ""
|
||
|
||
# Enable Anilist integration (bool)
|
||
enable = false
|
||
|
||
# Anilist ID to use for authentication (string)
|
||
id = ""
|
||
|
||
# Show link to Anilist on manga select (bool)
|
||
link_on_manga_select = true
|
||
|
||
# Anilist secret to use for authentication (string)
|
||
secret = ""
|
||
|
||
[downloader]
|
||
# Use asynchronous downloader (faster)
|
||
# Do no turn it off unless you have some issues (bool)
|
||
async = true
|
||
|
||
# Key template of the downloaded chapters (string)
|
||
# Path forbidden symbols will be replaced with "_"
|
||
# Available variables:
|
||
# {index} - index of the chapters
|
||
# {padded-index} - same as index but padded with leading zeros
|
||
# {chapters-count} - total number of chapters
|
||
# {chapter} - name of the chapter
|
||
# {manga} - name of the manga
|
||
# {volume} - volume of the chapter
|
||
# {source} - name of the source
|
||
chapter_name_template = "{padded-index}_{manga}_{chapter}"
|
||
|
||
# Create a subdirectory for each manga (bool)
|
||
create_manga_dir = true
|
||
|
||
# Create a subdirectory for each volume (bool)
|
||
create_volume_dir = false
|
||
|
||
# Default sources to use. (string array)
|
||
# Will prompt if not set.
|
||
# Type "mangal sources list" to show available sources
|
||
default_sources = []
|
||
|
||
# Whether to download manga cover or not (bool)
|
||
download_cover = true
|
||
|
||
# Where to download manga (string)
|
||
# Absolute or relative.
|
||
# You can also use tilde (~) to refer to your home directory or use env variables.
|
||
# Examples: ~/... or $HOME/... or ${MANGA_PATH}-mangal
|
||
path = "~/Downloads"
|
||
|
||
# If chapter is already downloaded, read it instead of downloading it to temp (bool)
|
||
read_downloaded = false
|
||
|
||
# Redownload chapters that already exist (bool)
|
||
redownload_existing = false
|
||
|
||
# Stop downloading other chapters on error (bool)
|
||
stop_on_error = true
|
||
|
||
[formats]
|
||
# Will skip images that can't be converted to the specified format (bool)
|
||
# Example: if you want to export to pdf, but some images are gifs, they will be skipped
|
||
skip_unsupported_images = true
|
||
|
||
# Default format to export chapters (string)
|
||
# Available options are: pdf, zip, cbz, plain
|
||
use = "pdf"
|
||
|
||
[gen]
|
||
# Key to use in generated scrapers as author (string)
|
||
gen.author = "Sravan Balaji"
|
||
|
||
[history]
|
||
# Save history on chapter download (bool)
|
||
save_on_download = false
|
||
|
||
# Save history on chapter read (bool)
|
||
save_on_read = true
|
||
|
||
[icons]
|
||
# Icons variant. (string)
|
||
# Available options are: emoji, kaomoji, plain, squares, nerd (nerd-font required)
|
||
variant = "nerd"
|
||
|
||
[installer]
|
||
# Custom scrapers repository branch (string)
|
||
branch = "main"
|
||
|
||
# Custom scrapers repository name (string)
|
||
repo = "mangal-scrapers"
|
||
|
||
# Custom scrapers repository owner (string)
|
||
user = "metafates"
|
||
|
||
[logs]
|
||
# Use json format for logs (bool)
|
||
json = true
|
||
|
||
# Available options are: (from less to most verbose) (string)
|
||
# panic, fatal, error, warn, info, debug, trace
|
||
level = "info"
|
||
|
||
# Write logs (bool)
|
||
write = false
|
||
|
||
[mangadex]
|
||
# Preferred language for mangadex (string)
|
||
# Use "any" to show all languages
|
||
language = "en"
|
||
|
||
# Show NSFW content (bool)
|
||
nsfw = true
|
||
|
||
# Show chapters that cannot be downloaded (bool)
|
||
show_unavailable_chapters = false
|
||
|
||
[metadata]
|
||
# Generate ComicInfo.xml file for each chapter (bool)
|
||
comic_info_xml = false
|
||
|
||
# Add series release date to each chapter in ComicInfo.xml file (bool)
|
||
comic_info_xml_add_date = true
|
||
|
||
# Use download date instead of series release date in ComicInfo.xml file (bool)
|
||
comic_info_xml_alternative_date = false
|
||
|
||
# Minimum relevance of a tag to be added to ComicInfo.xml file. From 0 to 100 (int)
|
||
comic_info_xml_tag_relevance_threshold = 60
|
||
|
||
# Fetch metadata from Anilist (bool)
|
||
# It will also cache the results to not spam the API
|
||
fetch_anilist = true
|
||
|
||
# Generate series.json file for each manga (bool)
|
||
series_json = true
|
||
|
||
[mini]
|
||
# Limit of search results to show (int)
|
||
search_limit = 50
|
||
|
||
[reader]
|
||
# What browser to use to open webpages (string)
|
||
browser = ""
|
||
|
||
# What app to use to open cbz files (string)
|
||
cbz = ""
|
||
|
||
# What app to use to open folders (string)
|
||
folder = ""
|
||
|
||
# What app to use to open pdf files (string)
|
||
pdf = "okular"
|
||
|
||
# What app to use to open folders (string)
|
||
plain = ""
|
||
|
||
# Open chapter url in browser instead of downloading it (bool)
|
||
read_in_browser = false
|
||
|
||
# What app to use to open zip files (string)
|
||
zip = ""
|
||
|
||
[search]
|
||
# Show query suggestions in when searching (bool)
|
||
show_query_suggestions = true
|
||
|
||
[tui]
|
||
# Spacing between items in the TUI (int)
|
||
item_spacing = 1
|
||
|
||
# Read chapter on enter if other chapters aren't selected (bool)
|
||
read_on_enter = false
|
||
|
||
# Reverse chapters order (bool)
|
||
reverse_chapters = false
|
||
|
||
# Search prompt string to use (string)
|
||
search_prompt = "> "
|
||
|
||
# Show path where chapters were downloaded (bool)
|
||
show_downloaded_path = true
|
||
|
||
# Show URLs under list items (bool)
|
||
show_urls = true
|
||
#+END_SRC
|
||
|
||
** Trackma
|
||
|
||
*** Config
|
||
|
||
#+BEGIN_SRC json :tangle trackma/.config/trackma/config.json
|
||
{
|
||
"auto_date_change": true,
|
||
"auto_status_change": true,
|
||
"auto_status_change_if_scored": true,
|
||
"autoretrieve": "always",
|
||
"autoretrieve_days": 3,
|
||
"autosend": "off",
|
||
"autosend_at_exit": true,
|
||
"autosend_minutes": 60,
|
||
"autosend_size": 5,
|
||
"debug_disable_lock": true,
|
||
"jellyfin_api_key": "",
|
||
"jellyfin_host": "localhost",
|
||
"jellyfin_port": "8096",
|
||
"jellyfin_user": "",
|
||
"kodi_host": "localhost",
|
||
"kodi_obey_update_wait_s": false,
|
||
"kodi_passwd": "",
|
||
"kodi_port": "8080",
|
||
"kodi_user": "",
|
||
"library_autoscan": true,
|
||
"library_full_path": false,
|
||
"player": "/bin/vlc",
|
||
"plex_host": "localhost",
|
||
"plex_obey_update_wait_s": false,
|
||
"plex_passwd": "",
|
||
"plex_port": "32400",
|
||
"plex_user": "",
|
||
"plex_uuid": "f420e4d0-05b4-11ed-bf19-18cc189cc368",
|
||
"redirections_time": 1,
|
||
"redirections_url": "https://raw.githubusercontent.com/erengy/anime-relations/master/anime-relations.txt",
|
||
"scan_whole_list": true,
|
||
"searchdir": [
|
||
],
|
||
"tracker_enabled": true,
|
||
"tracker_ignore_not_next": true,
|
||
"tracker_interval": 10,
|
||
"tracker_not_found_prompt": true,
|
||
"tracker_process": "mplayer|mplayer2|mpv|vlc",
|
||
"tracker_type": "local",
|
||
"tracker_update_close": true,
|
||
"tracker_update_prompt": true,
|
||
"tracker_update_wait_s": 300,
|
||
"use_hooks": true
|
||
}
|
||
#+END_SRC
|
||
|
||
*** Gtk
|
||
|
||
#+BEGIN_SRC json :tangle trackma/.config/trackma/ui-Gtk.json
|
||
{
|
||
"close_to_tray": false,
|
||
"colors": {
|
||
"is_airing": "#0099cc",
|
||
"is_playing": "#6c2dc7",
|
||
"is_queued": "#54c571",
|
||
"new_episode": "#fbb917",
|
||
"not_aired": "#999900",
|
||
"progress_bg": "#e5e5e5",
|
||
"progress_complete": "#99ccb3",
|
||
"progress_fg": "#99b3cc",
|
||
"progress_sub_bg": "#b3b3b3",
|
||
"progress_sub_fg": "#668099"
|
||
},
|
||
"episodebar_style": 1,
|
||
"last_height": 480,
|
||
"last_width": 740,
|
||
"remember_geometry": false,
|
||
"show_tray": true,
|
||
"start_in_tray": false,
|
||
"tray_api_icon": true,
|
||
"visible_columns": [
|
||
"Title",
|
||
"Progress",
|
||
"Score",
|
||
"Percent"
|
||
]
|
||
}
|
||
#+END_SRC
|
||
|
||
*** Qt
|
||
|
||
#+BEGIN_SRC json :tangle trackma/.config/trackma/ui-qt.json
|
||
{
|
||
"close_to_tray": false,
|
||
"colors": {
|
||
"is_airing": "#D2FAFA",
|
||
"is_playing": "#9696FA",
|
||
"is_queued": "#D2FAD2",
|
||
"new_episode": "#FAFA82",
|
||
"not_aired": "#FAFAD2",
|
||
"progress_bg": "#F5F5F5",
|
||
"progress_complete": "#00D200",
|
||
"progress_fg": "#74C0FA",
|
||
"progress_sub_bg": "#D2D2D2",
|
||
"progress_sub_fg": "#5187B1"
|
||
},
|
||
"columns_per_api": false,
|
||
"columns_state": null,
|
||
"episodebar_style": 1,
|
||
"episodebar_text": false,
|
||
"filter_bar_position": 2,
|
||
"filter_global": false,
|
||
"inline_edit": true,
|
||
"last_height": 480,
|
||
"last_width": 740,
|
||
"last_x": 0,
|
||
"last_y": 0,
|
||
"notifications": true,
|
||
"remember_columns": false,
|
||
"remember_geometry": false,
|
||
"show_tray": true,
|
||
"sort_index": 1,
|
||
"sort_order": 0,
|
||
"start_in_tray": false,
|
||
"tray_api_icon": true,
|
||
"visible_columns": [
|
||
"Title",
|
||
"Progress",
|
||
"Score",
|
||
"Percent"
|
||
]
|
||
}
|
||
#+END_SRC
|
||
|
||
** Swappy
|
||
|
||
#+BEGIN_SRC conf :tangle swappy/.config/swappy/config
|
||
[Default]
|
||
save_dir=$HOME/Downloads
|
||
save_filename_format=swappy-%Y%m%d-%H%M%S.png
|
||
show_panel=false
|
||
line_size=5
|
||
text_size=20
|
||
text_font=sans-serif
|
||
paint_mode=brush
|
||
early_exit=false
|
||
fill_shape=false
|
||
#+END_SRC
|
||
|
||
* SSH
|
||
|
||
** Config
|
||
|
||
#+BEGIN_SRC conf :tangle ssh/.ssh/config
|
||
# Arch User Repository (AUR)
|
||
Host aur.archlinux.org
|
||
IdentityFile ~/.ssh/aur
|
||
User aur
|
||
|
||
# Gitea
|
||
Host gitea.sravanbalaji.com
|
||
IdentityFile ~/.ssh/id_ed25519
|
||
User gitea
|
||
Port 2222
|
||
#+END_SRC
|
||
|
||
* System Settings
|
||
|
||
** X11
|
||
|
||
*** Xinit
|
||
|
||
**** Environment Variables
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwm/.xinitrc
|
||
export TERM=xterm-256color # Sets the terminal type
|
||
export SHELL=/bin/fish # Preferred shell
|
||
export EDITOR="emacs" # Default editor
|
||
export GIT_EDITOR="emacs" # Default git editor
|
||
export BROWSER=vivaldi-stable # Web Browser
|
||
export XDG_CONFIG_HOME=$HOME/.config # Set Config directory
|
||
export QT_QPA_PLATFORMTHEME=qt6ct # QGtkStyle
|
||
export _JAVA_AWT_WM_NONREPARENTING=1 # Java fix for Window Managers
|
||
#+END_SRC
|
||
|
||
**** Load Xresources
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwm/.xinitrc
|
||
xrdb ~/.Xresources
|
||
#+END_SRC
|
||
|
||
**** Startup Applications & Processes
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwm/.xinitrc
|
||
# Startup Applications
|
||
$HOME/.scripts/x11-startup.sh --kill-startup &&
|
||
$HOME/.scripts/x11-startup.sh --startup
|
||
|
||
# Delayed Startup Applications
|
||
(sleep 5 &&
|
||
$HOME/.scripts/x11-startup.sh --kill-delay &&
|
||
$HOME/.scripts/x11-startup.sh --delay) &
|
||
#+END_SRC
|
||
|
||
**** Launch Environment
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwm/.xinitrc
|
||
exec dwm
|
||
#+END_SRC
|
||
|
||
*** Xresources
|
||
|
||
**** Colors
|
||
|
||
#+BEGIN_SRC conf :tangle dwm/.Xresources
|
||
! Colors
|
||
#define FOREGROUND #F8F8F2
|
||
#define BACKGROUND #282A36
|
||
#define BLACK1 #000000
|
||
#define BLACK2 #4D4D4D
|
||
#define WHITE1 #E6E6E6
|
||
#define WHITE2 #BFBFBF
|
||
#define RED1 #FF5555
|
||
#define RED2 #FF6E67
|
||
#define GREEN1 #50FA7B
|
||
#define GREEN2 #5AF78E
|
||
#define YELLOW1 #F1FA8C
|
||
#define YELLOW2 #F4F99D
|
||
#define PURPLE1 #BD93F9
|
||
#define PURPLE2 #CAA9FA
|
||
#define PINK1 #FF79C6
|
||
#define PINK2 #FF92D0
|
||
#define CYAN1 #8BE9FD
|
||
#define CYAN2 #9AEDFE
|
||
#define ORANGE #FFB86C
|
||
|
||
! Dracula Xresources Palette
|
||
,*.foreground: FOREGROUND
|
||
,*.background: BACKGROUND
|
||
,*.color0: BLACK1
|
||
,*.color8: BLACK2
|
||
,*.color1: RED1
|
||
,*.color9: RED2
|
||
,*.color2: GREEN1
|
||
,*.color10: GREEN2
|
||
,*.color3: YELLOW1
|
||
,*.color11: YELLOW2
|
||
,*.color4: PURPLE1
|
||
,*.color12: PURPLE2
|
||
,*.color5: PINK1
|
||
,*.color13: PINK2
|
||
,*.color6: CYAN1
|
||
,*.color14: CYAN2
|
||
,*.color7: WHITE2
|
||
,*.color15: WHITE1
|
||
,*.color16: ORANGE
|
||
#+END_SRC
|
||
|
||
**** Sizes
|
||
|
||
*NOT IN USE*
|
||
#+BEGIN_SRC conf :tangle no
|
||
! Regular DPI Parameters
|
||
#define DPI 96
|
||
#define BAR_HEIGHT 25
|
||
#define MODULE_MARGIN 0
|
||
#define MODULE_PADDING 0
|
||
#define MODULE_DWM_PADDING 2
|
||
#define TRAY_MAXSIZE 20
|
||
#define TRAY_SCALE 1
|
||
#define BORDER_SIZE 2
|
||
#define INNER_GAPS 20
|
||
#define OUTER_GAPS 10
|
||
#define MAXLEN 75
|
||
#define CURSOR_SIZE 16
|
||
#+END_SRC
|
||
|
||
#+BEGIN_SRC conf :tangle dwm/.Xresources
|
||
! System76 Oryx Pro 7 DPI Parameters
|
||
#define DPI 96
|
||
#define BAR_HEIGHT 25
|
||
#define MODULE_MARGIN 0
|
||
#define MODULE_PADDING 0
|
||
#define MODULE_DWM_PADDING 2
|
||
#define TRAY_MAXSIZE 25
|
||
#define TRAY_SCALE 1
|
||
#define BORDER_SIZE 2
|
||
#define INNER_GAPS 20
|
||
#define OUTER_GAPS 10
|
||
#define MAXLEN 25
|
||
#define CURSOR_SIZE 16
|
||
#+END_SRC
|
||
|
||
*NOT IN USE*
|
||
#+BEGIN_SRC conf :tangle no
|
||
! HiDPI Parameters
|
||
#define DPI 192
|
||
#define BAR_HEIGHT 50
|
||
#define MODULE_MARGIN 0
|
||
#define MODULE_PADDING 0
|
||
#define MODULE_DWM_PADDING 2
|
||
#define TRAY_MAXSIZE 40
|
||
#define TRAY_SCALE 1
|
||
#define BORDER_SIZE 4
|
||
#define INNER_GAPS 40
|
||
#define OUTER_GAPS 20
|
||
#define MAXLEN 45
|
||
#define CURSOR_SIZE 32
|
||
#+END_SRC
|
||
|
||
**** Application Specific Changes
|
||
|
||
***** dwm
|
||
|
||
#+BEGIN_SRC conf :tangle dwm/.Xresources
|
||
! DWM
|
||
dwm.normbordercolor: BLACK2
|
||
dwm.normbgcolor: BACKGROUND
|
||
dwm.normfgcolor: FOREGROUND
|
||
dwm.selbordercolor: PURPLE1
|
||
dwm.selbgcolor: PURPLE1
|
||
dwm.selfgcolor: BACKGROUND
|
||
dwm.borderpx: BORDER_SIZE
|
||
dwm.gappih: INNER_GAPS
|
||
dwm.gappiv: INNER_GAPS
|
||
dwm.gappoh: OUTER_GAPS
|
||
dwm.gappov: OUTER_GAPS
|
||
#+END_SRC
|
||
|
||
***** Polybar
|
||
|
||
#+BEGIN_SRC conf :tangle dwm/.Xresources
|
||
! Polybar
|
||
polybar.bar-height: BAR_HEIGHT
|
||
polybar.module-margin: MODULE_MARGIN
|
||
polybar.module-padding: MODULE_PADDING
|
||
polybar.module-dwm-padding: MODULE_DWM_PADDING
|
||
polybar.tray-maxsize: TRAY_MAXSIZE
|
||
polybar.tray-scale: TRAY_SCALE
|
||
polybar.maxlen: MAXLEN
|
||
#+END_SRC
|
||
|
||
***** Display Scaling
|
||
|
||
#+BEGIN_SRC conf :tangle dwm/.Xresources
|
||
! Display Scaling
|
||
,*.dpi: DPI
|
||
Xcursor.size: CURSOR_SIZE
|
||
#+END_SRC
|
||
|
||
*** X11 Startup
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwm/.scripts/x11-startup.sh
|
||
declare -a startup_array=(\
|
||
"/usr/bin/greenclip daemon" \ # Greenclip Clipboard Manager
|
||
"/usr/libexec/polkit-gnome-authentication-agent-1" \ # GNOME Polkit Authentication Agent
|
||
"/usr/bin/xss-lock -l -- betterlockscreen --lock" \ # Session Lock Utility
|
||
"/usr/lib/kdeconnectd --replace" \ # KDE Connect Daemon
|
||
"/usr/bin/gammastep -x" \ # Gammastep Night Light
|
||
"/usr/bin/unclutter" \ # Hide Mouse Cursor
|
||
"/usr/bin/easyeffects --gapplication-service" \ # Easy Effects PipeWire Plugins
|
||
)
|
||
|
||
declare -a kill_startup_array=(\
|
||
"pkill greenclip" \ # Greenclip Clipboard Manager
|
||
"pkill polkit" \ # GNOME Polkit Authentication Agent
|
||
"pkill xss-lock" \ # Session Lock Utility
|
||
"pkill kdeconnectd" \ # KDE Connect Daemon
|
||
"pkill gammastep" \ # Gammastep Night Light
|
||
"pkill unclutter" \ # Hide Mouse Cursor
|
||
"pkill easyeffects" \ # Easy Effects PipeWire Plugins
|
||
)
|
||
|
||
declare -a delay_array=(\
|
||
"/usr/bin/gammastep-indicator" \ # Gammastep Night Light
|
||
"/usr/bin/blueman-applet" \ # Blueman Bluetooth Manager
|
||
"/usr/bin/nm-applet" \ # Network Manager Applet
|
||
"/usr/bin/kdeconnect-indicator" \ # KDE Connect Indicator
|
||
"/usr/bin/flameshot" \ # Flameshot Screenshot Tool
|
||
"/usr/bin/xfce4-power-manager" \ # XFCE4 Power Manager
|
||
"/usr/bin/udiskie -a -n -s" \ # Udiskie
|
||
"/usr/bin/openrgb" \ # OpenRGB
|
||
"/usr/bin/syncthing-gtk" \ # Syncthing GTK
|
||
"/usr/bin/nextcloud" \ # NextCloud Client
|
||
"/usr/bin/nyrna" \ # Nyrna
|
||
"bash $HOME/.scripts/dunst.sh --on" \ # Dunst Notification Daemon
|
||
"bash $HOME/.scripts/picom.sh --on" \ # Picom Compositor
|
||
"/usr/bin/autorandr --change --force" \ # Auto restore screen layout
|
||
"/usr/bin/numlockx on" \ # Enable numlock
|
||
)
|
||
|
||
declare -a kill_delay_array=(\
|
||
"pkill gammastep-indic" \ # Gammastep Night Light
|
||
"pkill blueman-applet" \ # Blueman Bluetooth Manager
|
||
"pkill nm-applet" \ # Network Manager Applet
|
||
"pkill kdeconnect-indicator" \ # KDE Connect Indicator
|
||
"pkill flameshot" \ # Flameshot Screenshot Tool
|
||
"pkill xfce4-power-manager" \ # XFCE4 Power Manager
|
||
"pkill udiskie" \ # Udiskie
|
||
"pkill openrgb" \ # OpenRGB
|
||
"pkill syncthing-gtk" \ # Syncthing GTK
|
||
"pkill nextcloud" \ # NextCloud Client
|
||
"pkill nyrna" \ # Nyrna
|
||
"bash $HOME/.scripts/dunst.sh --off" \ # Dunst Notification Daemon
|
||
"bash $HOME/.scripts/picom.sh --off" \ # Picom Compositor
|
||
)
|
||
|
||
help_menu() {
|
||
echo "Main script to launch and kill startup processes. Use only one argument at a time."
|
||
# echo " - Play / Pause: playerctl.sh --play-pause"
|
||
# echo " - Next: playerctl.sh --next"
|
||
# echo " - Previous: playerctl.sh --prev"
|
||
# echo " - Change Player: playerctl.sh --change"
|
||
# echo " - Rofi Menu: playerctl.sh --rofi"
|
||
# echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" Launch Startup Processes - startup"
|
||
" Launch Delayed Processes - delay"
|
||
" Kill Startup Processes - kill-startup"
|
||
" Kill Delayed Processes - kill-delay"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--startup)
|
||
for i in "${startup_array[@]}"
|
||
do
|
||
if ! command -v $i > /dev/null
|
||
then
|
||
do_nothing() { :; }
|
||
else
|
||
$i &
|
||
fi
|
||
done
|
||
;;
|
||
--delay)
|
||
for i in "${delay_array[@]}"
|
||
do
|
||
if ! command -v $i > /dev/null
|
||
then
|
||
do_nothing() { :; }
|
||
else
|
||
$i &
|
||
fi
|
||
done
|
||
;;
|
||
--kill-startup)
|
||
for i in "${kill_startup_array[@]}"
|
||
do
|
||
if ! command -v $i > /dev/null
|
||
then
|
||
do_nothing() { :; }
|
||
else
|
||
$i &
|
||
fi
|
||
done
|
||
;;
|
||
--kill-delay)
|
||
for i in "${kill_delay_array[@]}"
|
||
do
|
||
if ! command -v $i > /dev/null
|
||
then
|
||
do_nothing() { :; }
|
||
else
|
||
$i &
|
||
fi
|
||
done
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Wayland
|
||
|
||
*** Winit
|
||
|
||
**** Environment Variables
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwl/.winitrc
|
||
export TERM=xterm-256color # Sets the terminal type
|
||
export SHELL=/bin/fish # Preferred shell
|
||
export EDITOR="emacs" # Default editor
|
||
export GIT_EDITOR="emacs" # Default git editor
|
||
export BROWSER=vivaldi-stable # Web Browser
|
||
export XDG_CONFIG_HOME=$HOME/.config # Set Config directory
|
||
export QT_QPA_PLATFORMTHEME=qt6ct # QGtkStyle
|
||
export _JAVA_AWT_WM_NONREPARENTING=1 # Java fix for Window Managers
|
||
export XDG_CURRENT_DESKTOP=wlroots # Set XDG current desktop
|
||
#+END_SRC
|
||
|
||
**** Launch Environment
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwl/.winitrc
|
||
dwl &
|
||
#+END_SRC
|
||
|
||
**** Startup Applications & Processes
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwl/.winitrc
|
||
(sleep 3 &&
|
||
$HOME/.scripts/wayland-startup.sh --kill-startup &&
|
||
sleep 2 &&
|
||
$HOME/.scripts/wayland-startup.sh --startup) &
|
||
#+END_SRC
|
||
|
||
*** Wayland Startup
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwl/.scripts/wayland-startup.sh
|
||
declare -a startup_array=(\
|
||
# Display / Compositor Setup
|
||
"/usr/bin/shikane" \ # Display Setup
|
||
"/usr/bin/bash $HOME/.azotebg" \ # Wallpaper
|
||
"/usr/bin/gammastep -x" \ # Reset gammastep night light
|
||
# Background Processes
|
||
"/usr/libexec/polkit-gnome-authentication-agent-1" \ # GNOME Polkit Authentication Agent
|
||
"/usr/bin/kdeconnectd --replace" \ # KDE Connect Daemon
|
||
"/usr/bin/bash $HOME/.scripts/dunst.sh" \ # Dunst Notification Daemon
|
||
"/usr/bin/wl-paste --type text --watch cliphist store" \ # Clipboard for Text
|
||
"/usr/bin/wl-paste --type image --watch cliphist store" \ # Clipboard for Images
|
||
# Tray Applications
|
||
"/usr/bin/gammastep-indicator" \ # Gamamstep Night Light Indicator
|
||
"/usr/bin/blueman-applet" \ # Bluetooth Manager Applet
|
||
"/usr/bin/nm-applet" \ # Network Manager Applet
|
||
"/usr/bin/kdeconnect-indicator" \ # KDE Connect Indicator
|
||
"/usr/bin/udiskie -a -n -s" \ # Udiskie
|
||
# Status Bar
|
||
"/usr/bin/sh -c $HOME/.config/dwl/waybar/launch.sh" \ # Waybar (dwl configuration)
|
||
# GUI Applications
|
||
"/usr/bin/nextcloud" \ # NextCloud Client
|
||
"/usr/bin/syncthing-gtk" \ # Syncthing GUI
|
||
"/usr/bin/openrgb" \ # OpenRGB
|
||
)
|
||
|
||
declare -a kill_startup_array=(\
|
||
# Display / Compositor Setup
|
||
"pkill shikane" \
|
||
"pkill gammastep" \
|
||
# Background Processes
|
||
"pkill polkit-gnome-au" \
|
||
"pkill kdeconnectd" \
|
||
"pkill dunst" \
|
||
"pkill wl-paste" \
|
||
# Tray Applications
|
||
"pkill gammastep-indic" \
|
||
"pkill blueman-applet" \
|
||
"pkill nm-applet" \
|
||
"pkill kdeconnect-indi" \
|
||
"pkill udiskie" \
|
||
# Status Bar
|
||
"pkill waybar" \
|
||
# GUI Applications
|
||
"pkill nextcloud" \
|
||
"pkill syncthing-gtk" \
|
||
"pkill openrgb" \
|
||
)
|
||
|
||
help_menu() {
|
||
echo "Main script to launch and kill startup processes. Use only one argument at a time."
|
||
# echo " - Play / Pause: playerctl.sh --play-pause"
|
||
# echo " - Next: playerctl.sh --next"
|
||
# echo " - Previous: playerctl.sh --prev"
|
||
# echo " - Change Player: playerctl.sh --change"
|
||
# echo " - Rofi Menu: playerctl.sh --rofi"
|
||
# echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" Launch Startup Processes - startup"
|
||
" Kill Startup Processes - kill-startup"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--startup)
|
||
for i in "${startup_array[@]}"
|
||
do
|
||
if ! command -v $i > /dev/null
|
||
then
|
||
do_nothing() { :; }
|
||
else
|
||
$i &
|
||
fi
|
||
done
|
||
;;
|
||
--kill-startup)
|
||
for i in "${kill_startup_array[@]}"
|
||
do
|
||
if ! command -v $i > /dev/null
|
||
then
|
||
do_nothing() { :; }
|
||
else
|
||
$i &
|
||
fi
|
||
done
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
* Justfile
|
||
|
||
#+BEGIN_SRC just :tangle justfile
|
||
set shell := ["bash", "-c"]
|
||
|
||
DOOM_BIN := "~/.config/doom-emacs/bin/doom"
|
||
DOOM_DIR_PATH := "~/.config/doom-emacs-config"
|
||
|
||
# List just commands by default
|
||
default:
|
||
@just --list
|
||
|
||
# Update doom emacs and sync config
|
||
doom-emacs-update: && doom-emacs-sync
|
||
DOOMDIR={{DOOM_DIR_PATH}} {{DOOM_BIN}} upgrade
|
||
|
||
# Sync doom emacs config
|
||
doom-emacs-sync:
|
||
DOOMDIR={{DOOM_DIR_PATH}} {{DOOM_BIN}} sync -u
|
||
|
||
# Check doom emacs & config for issues
|
||
doom-emacs-doctor:
|
||
DOOMDIR={{DOOM_DIR_PATH}} {{DOOM_BIN}} doctor
|
||
|
||
# Create softlinks from .dotfiles to home directory
|
||
stow-create:
|
||
stow -v \
|
||
-S alacritty \
|
||
-S bash \
|
||
-S blender \
|
||
-S brightness \
|
||
-S calibre \
|
||
-S dunst \
|
||
-S dwl \
|
||
-S emacs \
|
||
-S fish \
|
||
-S freecad \
|
||
-S gaming \
|
||
-S gammastep \
|
||
-S geoclue \
|
||
-S gimp \
|
||
-S git \
|
||
-S gtk \
|
||
-S kitty \
|
||
-S mangal \
|
||
-S mpv \
|
||
-S pactl \
|
||
-S playerctl \
|
||
-S qt5 \
|
||
-S rofi \
|
||
-S shikane \
|
||
-S snapborg \
|
||
-S ssh \
|
||
-S starship \
|
||
-S swappy \
|
||
-S swaylock \
|
||
-S swhkd \
|
||
-S syncthing \
|
||
-S system76 \
|
||
-S tmux \
|
||
-S trackma \
|
||
-S tty \
|
||
-S vim \
|
||
-S vscode \
|
||
-S xournalpp \
|
||
-S zathura \
|
||
-S zsh
|
||
|
||
# Remove softlinks from .dotfiles to home directory
|
||
stow-delete:
|
||
stow -v \
|
||
-D alacritty \
|
||
-D autorandr \
|
||
-D awesome \
|
||
-D bash \
|
||
-D betterlockscreen \
|
||
-D blender \
|
||
-D brightness \
|
||
-D calibre \
|
||
-D deadd \
|
||
-D dunst \
|
||
-D dwl \
|
||
-D dwm \
|
||
-D emacs \
|
||
-D eww \
|
||
-D fish \
|
||
-D freecad \
|
||
-D fuzzel \
|
||
-D gaming \
|
||
-D gammastep \
|
||
-D geoclue \
|
||
-D gimp \
|
||
-D git \
|
||
-D gtk \
|
||
-D hyprland \
|
||
-D kitty \
|
||
-D mangal \
|
||
-D mpv \
|
||
-D naughty \
|
||
-D pactl \
|
||
-D picom \
|
||
-D playerctl \
|
||
-D qt5 \
|
||
-D redshift \
|
||
-D rofi \
|
||
-D shikane \
|
||
-D snapborg \
|
||
-D ssh \
|
||
-D starship \
|
||
-D swappy \
|
||
-D swaylock \
|
||
-D swaync \
|
||
-D swhkd \
|
||
-D syncthing \
|
||
-D system76 \
|
||
-D tmux \
|
||
-D trackma \
|
||
-D trackpad \
|
||
-D tty \
|
||
-D vim \
|
||
-D vscode \
|
||
-D xfce4-notifyd \
|
||
-D xmonad \
|
||
-D xournalpp \
|
||
-D xrandr \
|
||
-D zathura \
|
||
-D zsh
|
||
|
||
# Remove and re-create softlinks from .dotfiles to home directory
|
||
stow-recreate:
|
||
stow -v \
|
||
-R alacritty \
|
||
-R bash \
|
||
-R blender \
|
||
-R brightness \
|
||
-R calibre \
|
||
-R dunst \
|
||
-R dwl \
|
||
-R emacs \
|
||
-R fish \
|
||
-R freecad \
|
||
-R gaming \
|
||
-R gammastep \
|
||
-R geoclue \
|
||
-R gimp \
|
||
-R git \
|
||
-R gtk \
|
||
-R kitty \
|
||
-R mangal \
|
||
-R mpv \
|
||
-R pactl \
|
||
-R playerctl \
|
||
-R qt5 \
|
||
-R rofi \
|
||
-R shikane \
|
||
-R snapborg \
|
||
-R ssh \
|
||
-R starship \
|
||
-R swappy \
|
||
-R swaylock \
|
||
-R swhkd \
|
||
-R syncthing \
|
||
-R system76 \
|
||
-R tmux \
|
||
-R trackma \
|
||
-R tty \
|
||
-R vim \
|
||
-R vscode \
|
||
-R xournalpp \
|
||
-R zathura \
|
||
-R zsh
|
||
|
||
# Update git submodules from remotes
|
||
submodule-update:
|
||
git submodule update --init --recursive --remote --progress
|
||
#+END_SRC
|
||
|
||
* Miscellaneous Scripts
|
||
|
||
** Media Control
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle playerctl/.scripts/playerctl.sh
|
||
help_menu() {
|
||
echo "Script to interact with playerctl. Use only one argument at a time."
|
||
echo " - Play / Pause: playerctl.sh --play-pause"
|
||
echo " - Next: playerctl.sh --next"
|
||
echo " - Previous: playerctl.sh --prev"
|
||
echo " - Change Player: playerctl.sh --change"
|
||
echo " - Rofi Menu: playerctl.sh --rofi"
|
||
echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" Play / Pause - play-pause"
|
||
" Next - next"
|
||
" Previous - prev"
|
||
" Change Source - change"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--play-pause)
|
||
playerctl --player=playerctld play-pause
|
||
;;
|
||
--next)
|
||
playerctl --player=playerctld next
|
||
;;
|
||
--prev)
|
||
playerctl --player=playerctld previous
|
||
;;
|
||
--change)
|
||
playerctld shift
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Volume Control
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle pactl/.scripts/pactl.sh
|
||
help_menu() {
|
||
echo "Script to interact with pactl. Use only one argument at a time."
|
||
# echo " - Play / Pause: playerctl.sh --play-pause"
|
||
# echo " - Next: playerctl.sh --next"
|
||
# echo " - Previous: playerctl.sh --prev"
|
||
# echo " - Change Player: playerctl.sh --change"
|
||
# echo " - Rofi Menu: playerctl.sh --rofi"
|
||
# echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" Raise Volume - raise"
|
||
" Lower Volume - lower"
|
||
" Mute - mute"
|
||
" Mixer - mixer"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--raise)
|
||
pactl set-sink-volume @DEFAULT_SINK@ +5%
|
||
;;
|
||
--lower)
|
||
pactl set-sink-volume @DEFAULT_SINK@ -5%
|
||
;;
|
||
--mute)
|
||
pactl set-sink-mute @DEFAULT_SINK@ toggle
|
||
;;
|
||
--mixer)
|
||
pavucontrol
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Brightness Control
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle brightness/.scripts/brightness.sh
|
||
help_menu() {
|
||
echo "Script to control brightness. Use only one argument at a time."
|
||
# echo " - Play / Pause: playerctl.sh --play-pause"
|
||
# echo " - Next: playerctl.sh --next"
|
||
# echo " - Previous: playerctl.sh --prev"
|
||
# echo " - Change Player: playerctl.sh --change"
|
||
# echo " - Rofi Menu: playerctl.sh --rofi"
|
||
# echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" Raise Brightness - raise"
|
||
" Lower Brightness - lower"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--raise)
|
||
brightnessctl -c backlight s 10%+
|
||
;;
|
||
--lower)
|
||
brightnessctl -c backlight s 10%-
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Trackpad Control
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle trackpad/.scripts/trackpad.sh
|
||
trackpad_id=13
|
||
|
||
if xinput list-props $trackpad_id | grep "Device Enabled (.*):.*1" >/dev/null
|
||
then
|
||
xinput disable $trackpad_id
|
||
notify-send -u low -i mouse "Trackpad disabled"
|
||
else
|
||
xinput enable $trackpad_id
|
||
notify-send -u low -i mouse "Trackpad enabled"
|
||
fi
|
||
#+END_SRC
|
||
|
||
** CPU & GPU Control
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle system76/.scripts/cpu-gpu.sh
|
||
help_menu() {
|
||
echo "Script to control CPU & GPU modes / performance profiles. Use only one argument at a time."
|
||
# echo " - Play / Pause: playerctl.sh --play-pause"
|
||
# echo " - Next: playerctl.sh --next"
|
||
# echo " - Previous: playerctl.sh --prev"
|
||
# echo " - Change Player: playerctl.sh --change"
|
||
# echo " - Rofi Menu: playerctl.sh --rofi"
|
||
# echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" CPU Performance Profile - rofi-cpu-profile"
|
||
" GPU Switching - rofi-graphics"
|
||
" NVIDIA GPU Performance Profile - rofi-gpu-profile"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
rofi_cpu_profile_menu() {
|
||
declare -a options=(
|
||
" Query Current Profile - cpu-profile-query"
|
||
" Switch to Battery Mode - cpu-profile-battery"
|
||
" Switch to Balanced Mode - cpu-profile-balanced"
|
||
" Switch to Performance Mode - cpu-profile-performance"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi-cpu-profile"
|
||
fi
|
||
}
|
||
|
||
rofi_graphics_menu() {
|
||
declare -a options=(
|
||
" Query Current Graphics - graphics-query"
|
||
"Switch to Compute Mode - graphics-compute"
|
||
"Switch to Hybrid Mode - graphics-hybrid"
|
||
"Switch to Integrated Mode - graphics-integrated"
|
||
"Switch to Nvidia Mode - graphics-nvidia"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi-graphics"
|
||
fi
|
||
}
|
||
|
||
rofi_gpu_profile_menu() {
|
||
declare -a options=(
|
||
" Query Current Profile - gpu-profile-query"
|
||
" Switch to Adaptive Mode - gpu-profile-adaptive"
|
||
" Switch to Performance Mode - gpu-profile-performance"
|
||
" Switch to Auto Mode - gpu-profile-auto"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi-gpu-profile"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--rofi-graphics)
|
||
rofi_graphics_menu
|
||
;;
|
||
--graphics-query)
|
||
current_graphics=$(sudo system76-power graphics)
|
||
notify-send "System76-Power Graphics" "$current_graphics"
|
||
;;
|
||
--graphics-compute)
|
||
notify-send "System76-Power Graphics" "Switching to Compute Graphics..."
|
||
sudo system76-power graphics compute
|
||
notify-send -u critical -t 0 "System76-Power Graphics" "Please reboot computer to switch graphics"
|
||
;;
|
||
--graphics-hybrid)
|
||
notify-send "System76-Power Graphics" "Switching to Hybrid Graphics..."
|
||
sudo system76-power graphics hybrid
|
||
notify-send -u critical -t 0 "System76-Power Graphics" "Please reboot computer to switch graphics"
|
||
;;
|
||
--graphics-integrated)
|
||
notify-send "System76-Power Graphics" "Switching to Integrated Graphics..."
|
||
sudo system76-power graphics integrated
|
||
notify-send -u critical -t 0 "System76-Power Graphics" "Please reboot computer to switch graphics"
|
||
;;
|
||
--graphics-nvidia)
|
||
notify-send "System76-Power Graphics" "Switching to Nvidia Graphics..."
|
||
sudo system76-power graphics nvidia
|
||
notify-send -u critical -t 0 "System76-Power Graphics" "Please reboot computer to switch graphics"
|
||
;;
|
||
--rofi-cpu-profile)
|
||
rofi_cpu_profile_menu
|
||
;;
|
||
--cpu-profile-query)
|
||
current_profile=$(sudo system76-power profile)
|
||
notify-send "System76-Power CPU Profile" "$current_profile"
|
||
;;
|
||
--cpu-profile-battery)
|
||
sudo system76-power profile battery
|
||
notify-send "System76-Power CPU Profile" "Switched to Battery Profile"
|
||
;;
|
||
--cpu-profile-balanced)
|
||
sudo system76-power profile balanced
|
||
notify-send "System76-Power CPU Profile" "Switched to Balanced Profile"
|
||
;;
|
||
--cpu-profile-performance)
|
||
sudo system76-power profile performance
|
||
notify-send "System76-Power CPU Profile" "Switched to Performance Profile"
|
||
;;
|
||
--rofi-gpu-profile)
|
||
rofi_gpu_profile_menu
|
||
;;
|
||
--gpu-profile-query)
|
||
if [ $XDG_SESSION_TYPE == "x11" ]; then
|
||
current_profile=$(nvidia-settings -q GpuPowerMizerMode)
|
||
notify-send "NVIDIA GPU Profile" "$current_profile"
|
||
elif [ $XDG_SESSION_TYPE == "wayland" ]; then
|
||
notify-send "NVIDIA GPU Profile not supported on Wayland"
|
||
fi
|
||
;;
|
||
--gpu-profile-adaptive)
|
||
if [ $XDG_SESSION_TYPE == "x11" ]; then
|
||
nvidia-settings -a "[gpu:0]/GpuPowerMizerMode=0"
|
||
notify-send "NVIDIA GPU Profile" "Switched to Adaptive Profile"
|
||
elif [ $XDG_SESSION_TYPE == "wayland" ]; then
|
||
notify-send "NVIDIA GPU Profile not supported on Wayland"
|
||
fi
|
||
;;
|
||
--gpu-profile-performance)
|
||
if [ $XDG_SESSION_TYPE == "x11" ]; then
|
||
nvidia-settings -a "[gpu:0]/GpuPowerMizerMode=1"
|
||
notify-send "NVIDIA GPU Profile" "Switched to Performance Profile"
|
||
elif [ $XDG_SESSION_TYPE == "wayland" ]; then
|
||
notify-send "NVIDIA GPU Profile not supported on Wayland"
|
||
fi
|
||
;;
|
||
--gpu-profile-auto)
|
||
if [ $XDG_SESSION_TYPE == "x11" ]; then
|
||
nvidia-settings -a "[gpu:0]/GpuPowerMizerMode=2"
|
||
notify-send "NVIDIA GPU Profile" "Switched to Auto Profile"
|
||
elif [ $XDG_SESSION_TYPE == "wayland" ]; then
|
||
notify-send "NVIDIA GPU Profile not supported on Wayland"
|
||
fi
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Gaming Control
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle gaming/.scripts/gaming.sh
|
||
help_menu() {
|
||
echo "Script to control gaming related things. Use only one argument at a time."
|
||
# echo " - Play / Pause: playerctl.sh --play-pause"
|
||
# echo " - Next: playerctl.sh --next"
|
||
# echo " - Previous: playerctl.sh --prev"
|
||
# echo " - Change Player: playerctl.sh --change"
|
||
# echo " - Rofi Menu: playerctl.sh --rofi"
|
||
# echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" DualSense to Xbox 360 Mapping - dualsense-to-xbox-360"
|
||
" Game Launch Settings - game-launch"
|
||
" Game Exit Settings - game-exit"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && pkill rofi
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--dualsense-to-xbox-360)
|
||
kitty --hold $HOME/.scripts/dualsense_to_xbox_360_controller.sh
|
||
;;
|
||
--game-launch)
|
||
$HOME/.scripts/game_launch.sh
|
||
;;
|
||
--game-exit)
|
||
$HOME/.scripts/game_exit.sh
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Session Control
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwl/.scripts/session.sh
|
||
help_menu() {
|
||
echo "Script to interact with desktop session. Use only one argument at a time."
|
||
# echo " - Play / Pause: playerctl.sh --play-pause"
|
||
# echo " - Next: playerctl.sh --next"
|
||
# echo " - Previous: playerctl.sh --prev"
|
||
# echo " - Change Player: playerctl.sh --change"
|
||
# echo " - Rofi Menu: playerctl.sh --rofi"
|
||
# echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" Logout - logout"
|
||
" Lock - lock"
|
||
"⏾ Sleep - sleep"
|
||
" Reboot - reboot"
|
||
" Shutdown - shutdown"
|
||
" Hibernate - hibernate"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && pkill rofi
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--logout)
|
||
notify-send "Session Control" "Logging Out of dwl"
|
||
pkill dwl
|
||
;;
|
||
--lock)
|
||
notify-send "Session Control" "Locking Session"
|
||
swaylock
|
||
;;
|
||
--sleep)
|
||
notify-send "Session Control" "Going to Sleep"
|
||
systemctl suspend
|
||
;;
|
||
--reboot)
|
||
notify-send "Session Control" "Rebooting System"
|
||
systemctl reboot
|
||
;;
|
||
--shutdown)
|
||
notify-send "Session Control" "Shutting Down System"
|
||
systemctl poweroff
|
||
;;
|
||
--hibernate)
|
||
notify-send "Session Control" "Hibernating System"
|
||
systemctl hibernate
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
** Control Center
|
||
|
||
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle dwl/.scripts/control-center.sh
|
||
help_menu() {
|
||
echo "Main script to launch sub-menu scripts. Use only one argument at a time."
|
||
# echo " - Play / Pause: playerctl.sh --play-pause"
|
||
# echo " - Next: playerctl.sh --next"
|
||
# echo " - Previous: playerctl.sh --prev"
|
||
# echo " - Change Player: playerctl.sh --change"
|
||
# echo " - Rofi Menu: playerctl.sh --rofi"
|
||
# echo " - Help: playerctl.sh --help OR playerctl.sh -h"
|
||
}
|
||
|
||
rofi_menu() {
|
||
declare -a options=(
|
||
" Display - brightness"
|
||
" Notifications - dunst"
|
||
" Media - playerctl"
|
||
" Volume - pactl"
|
||
" Backup - backup"
|
||
" Hardware - cpu-gpu"
|
||
" Gaming - gaming"
|
||
" Power Menu - session"
|
||
" Back - back"
|
||
" Quit - quit"
|
||
)
|
||
|
||
choice=$(printf '%s\n' "${options[@]}" | rofi -dmenu -i)
|
||
option=$(printf '%s\n' "${choice}" | awk '{print $NF}')
|
||
|
||
if [[ "$option" == "quit" ]]; then
|
||
pkill rofi
|
||
elif [[ "$option" != "back" ]]; then
|
||
main "--$option" && main "--rofi"
|
||
fi
|
||
}
|
||
|
||
main() {
|
||
if [ $# -eq 0 ]; then
|
||
# No arguments
|
||
help_menu
|
||
else
|
||
case $1 in
|
||
--help | -h)
|
||
help_menu
|
||
;;
|
||
--brightness)
|
||
$HOME/.scripts/brightness.sh --rofi
|
||
;;
|
||
--dunst)
|
||
$HOME/.scripts/dunst.sh --rofi
|
||
;;
|
||
--playerctl)
|
||
$HOME/.scripts/playerctl.sh --rofi
|
||
;;
|
||
--pactl)
|
||
$HOME/.scripts/pactl.sh --rofi
|
||
;;
|
||
--backup)
|
||
$HOME/.scripts/backup.sh --rofi
|
||
;;
|
||
--cpu-gpu)
|
||
$HOME/.scripts/cpu-gpu.sh --rofi
|
||
;;
|
||
--gaming)
|
||
$HOME/.scripts/gaming.sh --rofi
|
||
;;
|
||
--session)
|
||
$HOME/.scripts/session.sh --rofi
|
||
;;
|
||
--rofi)
|
||
rofi_menu
|
||
;;
|
||
esac
|
||
fi
|
||
}
|
||
|
||
main $@
|
||
#+END_SRC
|
||
|
||
* Acknowledgements
|
||
|
||
I previously used [[https://www.youtube.com/channel/UCVls1GmFKf6WlTraIb_IaJg][DistroTube]]'s process for setting up a git bare repository as shown in [[https://youtu.be/tBoLDpTWVOM][Git Bare Repository - A Better Way To Manage Dotfiles]].
|
||
He references [[https://www.atlassian.com/git/tutorials/dotfiles][The best way to store your dotfiles: A bare Git repository]] by [[https://www.durdn.com/][Nicola Paolucci]].
|
||
|
||
I have since switched to using [[https://www.gnu.org/software/stow/][GNU Stow]] as described in [[https://www.youtube.com/c/SystemCrafters][System Crafters]]' video called [[https://youtu.be/CxAT1u8G7is][Give Your Dotfiles a Home with GNU Stow]].
|