Add missing dotfiles, update existing
This commit is contained in:
parent
fc8ec0f3c8
commit
c9d5583c0b
54
.Xresources
54
.Xresources
|
@ -1,34 +1,40 @@
|
|||
Xft.antialias: 1
|
||||
Xft.autohint: 0
|
||||
Xft.dpi: 98
|
||||
Xft.hinting: 1
|
||||
Xft.hintstyle: hintfull
|
||||
Xft.lcdfilter: lcddefault
|
||||
Xft.rgba: rgb
|
||||
! -*- mode: conf-xdefaults -*-
|
||||
! vim: ft=xdefaults cms=!\ %s
|
||||
|
||||
URxvt.font: xft:Roboto Mono:style=regular:size=10:antialias=true:hinting=hintfull
|
||||
URxvt.boldFont: xft:Roboto Mono:stlye=bold:size=10:antialias=true:hinting=hintfull
|
||||
! Emacs
|
||||
Emacs.menuBar: true
|
||||
Emacs.toolBar: false
|
||||
Emacs.verticalScrollBars: false
|
||||
|
||||
URxvt.skipBuiltinGlyphs: true
|
||||
URxvt.secondaryScreen: true
|
||||
URxvt.secondaryScroll: false
|
||||
URxvt.iso14755: false
|
||||
URxvt.iso14755_52: false
|
||||
URxvt.scrollBar: false
|
||||
URxvt.scrollTtyOutput: false
|
||||
URxvt.scrollWithBuffer: true
|
||||
URxvt.scrollTtyKeypress: true
|
||||
URxvt.cursorBlink: true
|
||||
URxvt.urgentOnBell: true
|
||||
URxvt.buffered: true
|
||||
! xft
|
||||
Xft.dpi: 96
|
||||
Xft.rgba: rgb
|
||||
Xft.hinting: 1
|
||||
Xft.autohint: 0
|
||||
Xft.antialias: 1
|
||||
Xft.hintstyle: hintslight
|
||||
Xft.lcdfilter: lcddefault
|
||||
|
||||
URxvt.saveLines: 1000
|
||||
URxvt.depth: 32
|
||||
! URxvt
|
||||
URxvt*font: xft:Iosevka:size=12:antialias=true
|
||||
URxvt*boldFont: xft:Iosevka:bold:size=12:antialias=true
|
||||
|
||||
URxvt*saveLines: 5000
|
||||
URxvt*secondaryScreen: true
|
||||
URxvt*scrollWithBuffer: true
|
||||
URxvt*scrollTtyKeypress: true
|
||||
URxvt*scrollTtyOutput: false
|
||||
URxvt*secondaryScroll: false
|
||||
URxvt*scrollBar: false
|
||||
|
||||
URxvt*iso14755: false
|
||||
URxvt*iso14755_52: false
|
||||
|
||||
URxvt*url-launcher: /usr/bin/xdg-open
|
||||
|
||||
! https://github.com/chriskempson/base16-xresources
|
||||
! Base16 Tomorrow Night
|
||||
! Scheme: Chris Kempson (http://chriskempson.com)
|
||||
|
||||
#define base00 #1d1f21
|
||||
#define base01 #282a2e
|
||||
#define base02 #373b41
|
||||
|
|
|
@ -0,0 +1,120 @@
|
|||
{
|
||||
"editor.fontFamily": "Iosevka",
|
||||
"editor.fontSize": 16,
|
||||
"editor.fontLigatures": false,
|
||||
"editor.cursorStyle": "block",
|
||||
"editor.accessibilitySupport": "off",
|
||||
"editor.cursorBlinking": "blink",
|
||||
"editor.lineNumbers": "relative",
|
||||
"editor.minimap.enabled": false,
|
||||
"editor.mouseWheelZoom": true,
|
||||
"editor.roundedSelection": false,
|
||||
"editor.smoothScrolling": false,
|
||||
"editor.stablePeek": true,
|
||||
"editor.suggestSelection": "recentlyUsedByPrefix",
|
||||
|
||||
"files.associations": {
|
||||
"Pipfile": "toml",
|
||||
"Vagrantfile": "ruby"
|
||||
},
|
||||
|
||||
"terminal.external.linuxExec": "/usr/bin/termite",
|
||||
"terminal.external.osxExec": "iTerm2.app",
|
||||
|
||||
"workbench.iconTheme": "vscode-icons",
|
||||
"workbench.startupEditor": "none",
|
||||
"workbench.commandPalette.history": 500,
|
||||
"workbench.commandPalette.preserveInput": true,
|
||||
"workbench.editor.enablePreview": false,
|
||||
"workbench.editor.enablePreviewFromQuickOpen": false,
|
||||
"workbench.editor.labelFormat": "medium",
|
||||
"workbench.editor.revealIfOpen": true,
|
||||
"workbench.editor.tabCloseButton": "left",
|
||||
"workbench.statusBar.feedback.visible": false,
|
||||
"workbench.tree.horizontalScrolling": true,
|
||||
"workbench.view.alwaysShowHeaderActions": true,
|
||||
|
||||
"window.newWindowDimensions": "inherit",
|
||||
"window.restoreWindows": "none",
|
||||
"window.title": "${dirty}${activeEditorMedium}${separator}${rootName}${separator}${appName}",
|
||||
|
||||
"files.insertFinalNewline": true,
|
||||
"files.trimTrailingWhitespace": true,
|
||||
"files.trimFinalNewlines": true,
|
||||
"files.useExperimentalFileWatcher": false,
|
||||
|
||||
"explorer.sortOrder": "default",
|
||||
|
||||
"search.exclude": {
|
||||
"**/node_modules": true,
|
||||
"**/venv/**": true,
|
||||
"**/.tox/**": true,
|
||||
"**/.pytest_cache/**": true,
|
||||
"**/.vagrant/**": true
|
||||
},
|
||||
|
||||
"search.location": "sidebar",
|
||||
"search.smartCase": true,
|
||||
"search.useRipgrep": true,
|
||||
|
||||
"html.format.indentInnerHtml": true,
|
||||
"html.suggest.angular1": false,
|
||||
"html.suggest.ionic": false,
|
||||
|
||||
"extensions.ignoreRecommendations": true,
|
||||
|
||||
"python.autoComplete.showAdvancedMembers": true,
|
||||
"python.autoComplete.preloadModules": [
|
||||
"flask",
|
||||
"sqlalchemy"
|
||||
],
|
||||
|
||||
"python.disablePromptForFeatures": [
|
||||
"pylint"
|
||||
],
|
||||
|
||||
"python.formatting.provider": "yapf",
|
||||
"python.linting.pylamaEnabled": true,
|
||||
"python.linting.pydocstyleEnabled": false,
|
||||
"python.linting.mypyEnabled": true,
|
||||
|
||||
"python.linting.mypyArgs": [
|
||||
"--ignore-missing-imports",
|
||||
"--follow-imports=silent"
|
||||
],
|
||||
|
||||
"python.linting.ignorePatterns": [
|
||||
".vscode/*.py",
|
||||
"**/site-packages/**/*.py",
|
||||
"**/venv/**",
|
||||
".tox/**"
|
||||
],
|
||||
|
||||
"python.venvPath": "~/.local/share/virtualenvs",
|
||||
|
||||
"python.workspaceSymbols.enabled": true,
|
||||
"python.workspaceSymbols.exclusionPatterns": [
|
||||
"**/site-packages/**"
|
||||
],
|
||||
|
||||
"C_Cpp.clang_format_path": "/usr/bin/clang-format",
|
||||
"C_Cpp.clang_format_style": "file",
|
||||
"C_Cpp.default.cStandard": "c11",
|
||||
"C_Cpp.default.cppStandard": "c++17",
|
||||
"C_Cpp.default.intelliSenseMode": "clang-x64",
|
||||
|
||||
"liveshare.connectionMode": "auto",
|
||||
|
||||
"git.defaultCloneDirectory": "/home/alex/projects",
|
||||
"git.enableCommitSigning": true,
|
||||
"git.path": "/usr/bin/git",
|
||||
|
||||
"vim.neovimPath": "/usr/bin/nvim",
|
||||
"vim.enableNeovim": true,
|
||||
"vim.cmdLineInitialColon": true,
|
||||
"vim.hlsearch": true,
|
||||
"vim.statusBarColorControl": true,
|
||||
"vim.textwidth": 72,
|
||||
"vim.useSystemClipboard": true,
|
||||
"files.autoSave": "off"
|
||||
}
|
|
@ -0,0 +1,66 @@
|
|||
# -*- mode: conf -*-
|
||||
# vim: ft=conf :
|
||||
|
||||
backend = "glx";
|
||||
vsync = "opengl-swc";
|
||||
|
||||
shadow = true;
|
||||
no-dock-shadow = true;
|
||||
no-dnd-shadow = true;
|
||||
clear-shadow = true;
|
||||
|
||||
shadow-radius = 10;
|
||||
shadow-offset-x = -5;
|
||||
shadow-offset-y = 0;
|
||||
shadow-opacity = 0.8;
|
||||
shadow-red = 0.11;
|
||||
shadow-green = 0.12;
|
||||
shadow-blue = 0.13;
|
||||
shadow-exclude = [
|
||||
"name = 'Notification'",
|
||||
"_GTK_FRAME_EXTENTS@:c",
|
||||
"_NET_WM_STATE@:32a *= '_NET_WM_STATE_HIDDEN'",
|
||||
"_NET_WM_STATE@:32a *= '_NET_WM_STATE_STICKY'",
|
||||
];
|
||||
shadow-ignore-shaped = true;
|
||||
|
||||
alpha-step = 0.06;
|
||||
blur-background = false;
|
||||
blur-background-fixed = true;
|
||||
blur-kern = "7x7box";
|
||||
blur-background-exclude = [
|
||||
"window_type = 'dock'",
|
||||
"window_type = 'desktop'",
|
||||
"_GTK_FRAME_EXTENTS@:c"
|
||||
];
|
||||
|
||||
opacity-rule = [
|
||||
];
|
||||
|
||||
fading = false;
|
||||
fade-delta = 7;
|
||||
fade-in-step = 0.05;
|
||||
fade-out-step = 0.05;
|
||||
fade-exclude = [];
|
||||
|
||||
mark-wmwin-focused = true;
|
||||
mark-ovredir-focused = true;
|
||||
use-ewmh-active-win = true;
|
||||
detect-rounded-corners = true;
|
||||
detect-client-opacity = true;
|
||||
refresh-rate = 0;
|
||||
dbe = false;
|
||||
paint-on-overlay = true;
|
||||
glx-no-stencil = true;
|
||||
glx-copy-from-front = false;
|
||||
glx-swap-method = "undefined";
|
||||
sw-opti = true;
|
||||
unredir-if-possible = false;
|
||||
focus-exclude = [];
|
||||
detect-transient = true;
|
||||
detect-client-leader = true;
|
||||
invert-color-include = [];
|
||||
|
||||
wintypes: {
|
||||
tooltip = { fade = true; shadow = false; opacity = 1.00; focus = true; };
|
||||
};
|
|
@ -0,0 +1,15 @@
|
|||
[Settings]
|
||||
gtk-theme-name=Arc-Dark
|
||||
gtk-icon-theme-name=Paper
|
||||
gtk-font-name=Noto Sans 11
|
||||
gtk-cursor-theme-size=0
|
||||
gtk-toolbar-style=GTK_TOOLBAR_BOTH_HORIZ
|
||||
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
||||
gtk-button-images=0
|
||||
gtk-menu-images=0
|
||||
gtk-enable-event-sounds=1
|
||||
gtk-enable-input-feedback-sounds=1
|
||||
gtk-xft-antialias=1
|
||||
gtk-xft-hinting=1
|
||||
gtk-xft-hintstyle=hintslight
|
||||
gtk-xft-rgba=rgb
|
|
@ -0,0 +1,184 @@
|
|||
# i3 config file (v4)
|
||||
#
|
||||
# Please see https://i3wm.org/docs/userguide.html for a complete reference!
|
||||
|
||||
# note: I have no idea what I'm doing.
|
||||
|
||||
set $mod Mod4
|
||||
|
||||
font pango:iosevka 12
|
||||
|
||||
floating_modifier $mod
|
||||
focus_follows_mouse no
|
||||
|
||||
# start a terminal
|
||||
bindsym $mod+Shift+Return exec --no-startup-id termite
|
||||
bindsym $mod+Control+Return exec --no-startup-id urxvt
|
||||
|
||||
# kill focused window
|
||||
bindsym $mod+Shift+c kill
|
||||
|
||||
# start rofi (a program launcher)
|
||||
bindsym $mod+p exec --no-startup-id rofi -show run
|
||||
|
||||
# change focus
|
||||
bindsym $mod+h focus left
|
||||
bindsym $mod+j focus down
|
||||
bindsym $mod+k focus up
|
||||
bindsym $mod+l focus right
|
||||
|
||||
# move focused window
|
||||
bindsym $mod+Shift+h move left
|
||||
bindsym $mod+Shift+j move down
|
||||
bindsym $mod+Shift+k move up
|
||||
bindsym $mod+Shift+l move right
|
||||
|
||||
# split in horizontal orientation
|
||||
bindsym $mod+Control+h split h
|
||||
|
||||
# split in vertical orientation
|
||||
bindsym $mod+Control+v split v
|
||||
|
||||
# enter fullscreen mode for the focused container
|
||||
bindsym $mod+f fullscreen toggle
|
||||
|
||||
# change container layout (stacked, tabbed, toggle split)
|
||||
bindsym $mod+s layout stacking
|
||||
bindsym $mod+w layout tabbed
|
||||
bindsym $mod+e layout toggle split
|
||||
|
||||
# toggle tiling / floating
|
||||
bindsym $mod+Shift+space floating toggle
|
||||
|
||||
# change focus between tiling / floating windows
|
||||
bindsym $mod+space focus mode_toggle
|
||||
|
||||
# focus the parent container
|
||||
bindsym $mod+a focus parent
|
||||
|
||||
# focus the child container
|
||||
bindsym $mod+d focus child
|
||||
|
||||
# Define names for default workspaces for which we configure key bindings later on.
|
||||
# We use variables to avoid repeating the names in multiple places.
|
||||
set $ws1 "1"
|
||||
set $ws2 "2"
|
||||
set $ws3 "3"
|
||||
set $ws4 "4"
|
||||
set $ws5 "5"
|
||||
set $ws6 "6"
|
||||
set $ws7 "7"
|
||||
set $ws8 "8"
|
||||
set $ws9 "9"
|
||||
set $ws10 "10"
|
||||
|
||||
workspace $ws1 output DP-2
|
||||
workspace $ws2 output DP-2
|
||||
workspace $ws3 output DP-2
|
||||
workspace $ws4 output DP-2
|
||||
workspace $ws5 output DP-2
|
||||
workspace $ws6 output DP-2
|
||||
workspace $ws7 output DP-2
|
||||
workspace $ws8 output DP-2
|
||||
workspace $ws9 output DP-2
|
||||
workspace $ws10 output DP-2
|
||||
|
||||
# switch to workspace
|
||||
bindsym $mod+1 workspace $ws1
|
||||
bindsym $mod+2 workspace $ws2
|
||||
bindsym $mod+3 workspace $ws3
|
||||
bindsym $mod+4 workspace $ws4
|
||||
bindsym $mod+5 workspace $ws5
|
||||
bindsym $mod+6 workspace $ws6
|
||||
bindsym $mod+7 workspace $ws7
|
||||
bindsym $mod+8 workspace $ws8
|
||||
bindsym $mod+9 workspace $ws9
|
||||
bindsym $mod+0 workspace $ws10
|
||||
|
||||
# move focused container to workspace
|
||||
bindsym $mod+Shift+1 move container to workspace $ws1
|
||||
bindsym $mod+Shift+2 move container to workspace $ws2
|
||||
bindsym $mod+Shift+3 move container to workspace $ws3
|
||||
bindsym $mod+Shift+4 move container to workspace $ws4
|
||||
bindsym $mod+Shift+5 move container to workspace $ws5
|
||||
bindsym $mod+Shift+6 move container to workspace $ws6
|
||||
bindsym $mod+Shift+7 move container to workspace $ws7
|
||||
bindsym $mod+Shift+8 move container to workspace $ws8
|
||||
bindsym $mod+Shift+9 move container to workspace $ws9
|
||||
bindsym $mod+Shift+0 move container to workspace $ws10
|
||||
|
||||
# nagivate between workspaces
|
||||
bindsym $mod+bracketleft workspace prev
|
||||
bindsym $mod+bracketright workspace next
|
||||
|
||||
bindsym $mod+Shift+Tab workspace prev
|
||||
bindsym $mod+Tab workspace next
|
||||
|
||||
bindsym $mod+q reload
|
||||
bindsym $mod+Shift+r restart
|
||||
bindsym $mod+Shift+q exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'"
|
||||
|
||||
mode "resize" {
|
||||
bindsym $mod+h resize shrink width 5 px or 5 ppt
|
||||
bindsym $mod+j resize grow height 5 px or 5 ppt
|
||||
bindsym $mod+k resize shrink height 5 px or 5 ppt
|
||||
bindsym $mod+l resize grow width 5 px or 5 ppt
|
||||
|
||||
bindsym Return mode "default"
|
||||
bindsym Escape mode "default"
|
||||
}
|
||||
|
||||
bindsym $mod+r mode "resize"
|
||||
|
||||
bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume 1 +2%
|
||||
bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume 1 -2%
|
||||
bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 1 toggle
|
||||
|
||||
bindsym XF86MonBrightnessUp exec --no-startup-id light -A 1.5%
|
||||
bindsym XF86MonBrightnessDown exec --no-startup-id light -U 1.5%
|
||||
|
||||
bindsym XF86AudioPlay exec playerctl play
|
||||
bindsym XF86AudioPause exec playerctl pause
|
||||
bindsym XF86AudioNext exec playerctl next
|
||||
bindsym XF86AudioPrev exec playerctl previous
|
||||
|
||||
set $bg-color #2f343f
|
||||
set $inactive-bg-color #2f343f
|
||||
set $text-color #f3f4f5
|
||||
set $inactive-text-color #676E7D
|
||||
set $urgent-bg-color #E53935
|
||||
|
||||
# window colors
|
||||
# border background text indicator
|
||||
client.focused $bg-color $bg-color $text-color #00ff00
|
||||
client.unfocused $inactive-bg-color $inactive-bg-color $inactive-text-color #00ff00
|
||||
client.focused_inactive $inactive-bg-color $inactive-bg-color $inactive-text-color #00ff00
|
||||
client.urgent $urgent-bg-color $urgent-bg-color $text-color #00ff00
|
||||
|
||||
|
||||
bar {
|
||||
status_command i3blocks -c ~/.config/i3/i3blocks.conf
|
||||
position top
|
||||
colors {
|
||||
background $bg-color
|
||||
separator #757575
|
||||
focused_workspace $bg-color $bg-color $text-color
|
||||
inactive_workspace $inactive-bg-color $inactive-bg-color $inactive-text-color
|
||||
urgent_workspace $urgent-bg-color $urgent-bg-color $text-color
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
for_window [window_role="pop-up"] floating enable
|
||||
for_window [window_role="task_dialog"] floating enable
|
||||
for_window [title="Preferences$"] floating enable
|
||||
|
||||
set $default_gaps_inner 12
|
||||
set $default_gaps_outer 0
|
||||
|
||||
gaps inner $default_gaps_inner
|
||||
gaps outer $default_gaps_outer
|
||||
|
||||
popup_during_fullscreen smart
|
||||
new_window pixel 0
|
||||
workspace_auto_back_and_forth yes
|
|
@ -0,0 +1,18 @@
|
|||
command=/usr/lib/i3blocks/$BLOCK_NAME
|
||||
separator_block_width=15
|
||||
markup=none
|
||||
|
||||
[iface]
|
||||
label=
|
||||
instance=enp025
|
||||
color=#00FF00
|
||||
interval=10
|
||||
|
||||
[battery]
|
||||
label=
|
||||
interval=30
|
||||
|
||||
[time]
|
||||
command=date '+%b %d %I:%M:%S'
|
||||
interval=1
|
||||
label=
|
|
@ -1,4 +1,4 @@
|
|||
music_directory "~/media/music"
|
||||
music_directory "~/media/music/library"
|
||||
playlist_directory "~/.config/mpd/playlists"
|
||||
pid_file "~/.config/mpd/pid"
|
||||
state_file "~/.config/mpd/state"
|
||||
|
@ -14,9 +14,7 @@ audio_output {
|
|||
type "pulse"
|
||||
name "PulseAudio"
|
||||
mixer_type "software"
|
||||
|
||||
# use the equalizer+bs2b sink instead of defaul;
|
||||
sink "crossfeed"
|
||||
sink "equalizer"
|
||||
}
|
||||
|
||||
# output for ncmpcpp visualizer
|
||||
|
|
|
@ -0,0 +1,35 @@
|
|||
# -*- mode: conf -*-
|
||||
# vim: ft=conf :
|
||||
|
||||
def_key "+"
|
||||
show_clock
|
||||
|
||||
def_key "="
|
||||
volume_up
|
||||
|
||||
def_key "j"
|
||||
scroll_down
|
||||
|
||||
def_key "k"
|
||||
scroll_up
|
||||
|
||||
def_key "ctrl-u"
|
||||
page_up
|
||||
|
||||
def_key "ctrl-d"
|
||||
page_down
|
||||
|
||||
def_key "h"
|
||||
previous_column
|
||||
|
||||
def_key "l"
|
||||
next_column
|
||||
|
||||
def_key "."
|
||||
show_lyrics
|
||||
|
||||
def_key "n"
|
||||
next_found_item
|
||||
|
||||
def_key "N"
|
||||
previous_found_item
|
|
@ -1,58 +1,53 @@
|
|||
# TODO: figure out what half this crap does (I forgot) and
|
||||
# reconfig/remove/reorganize.
|
||||
# -*- mode: conf -*-
|
||||
# vim: set ft=conf :
|
||||
|
||||
ncmpcpp_directory = ~/.config/ncmpcpp
|
||||
mpd_host = localhost
|
||||
mpd_port = 6600
|
||||
mpd_connection_timeout = 5
|
||||
mpd_music_dir = ~/media/music
|
||||
mpd_crossfade_time = 0
|
||||
ncmpcpp_directory = ~/.config/ncmpcpp
|
||||
lyrics_directory = ~/.local/share/lyrics
|
||||
mpd_host = 127.0.0.1
|
||||
mpd_port = 6600
|
||||
mpd_connection_timeout = 5
|
||||
mpd_music_dir = ~/media/music/library
|
||||
mpd_crossfade_time = 0
|
||||
media_library_primary_tag = album_artist
|
||||
mouse_support = yes
|
||||
cyclic_scrolling = yes
|
||||
follow_now_playing_lyrics = yes
|
||||
fetch_lyrics_for_current_song_in_background = yes
|
||||
regular_expressions = perl
|
||||
|
||||
visualizer_fifo_path = /tmp/mpd.fifo
|
||||
visualizer_output_name = my_fifo
|
||||
visualizer_in_stereo = yes
|
||||
visualizer_sample_multiplier = .8
|
||||
visualizer_sync_interval = 15
|
||||
visualizer_type = spectrum
|
||||
visualizer_look = -+
|
||||
visualizer_color = blue, cyan, green, yellow, magenta, red
|
||||
playlist_display_mode = "columns"
|
||||
search_engine_display_mode = "columns"
|
||||
browser_display_mode = "columns"
|
||||
titles_visibility = "yes"
|
||||
incremental_seeking = "yes"
|
||||
autocenter_mode = "yes"
|
||||
header_visibility = "yes"
|
||||
statusbar_visibility = "yes"
|
||||
display_bitrate = "yes"
|
||||
ignore_leading_the = "yes"
|
||||
enable_window_title = "yes"
|
||||
progressbar_look = "·· "
|
||||
|
||||
song_list_format = {%a - }{%t}|{$8%f$9}$R{$3(%l)$9}
|
||||
song_status_format = {{%a{ "%b"{ (%y)}} - }{%t}}|{%f}
|
||||
song_library_format = {%n - }{%t}|{%f}
|
||||
now_playing_suffix = $/b
|
||||
song_columns_list_format = (20)[red]{a} (6f)[green]{NE} (50)[blue]{t|f:Title} (20)[yellow]{b} (7f)[magenta]{l}
|
||||
# formats
|
||||
song_list_format = "{%a - }{%t}|{$8%f$9}$R{$3(%l)$9}"
|
||||
song_library_format = "{%n - }{%t}|{%f}"
|
||||
song_status_format = "{{%a{ %b{ (%y)}} - }{%t}}|{%f}"
|
||||
song_columns_list_format = "(20)[red]{a} (6f)[green]{NE} (50)[blue]{t|f:Title} (20)[yellow]{b} (7f)[magenta]{l}"
|
||||
|
||||
browser_display_mode = columns
|
||||
search_engine_display_mode = columns
|
||||
playlist_editor_display_mode = columns
|
||||
|
||||
incremental_seeking = yes
|
||||
autocenter_mode = yes
|
||||
centered_cursor = yes
|
||||
progressbar_boldness = yes
|
||||
user_interface = classic
|
||||
header_visibility = yes
|
||||
statusbar_visibility = yes
|
||||
titles_visibility = yes
|
||||
header_text_scrolling = yes
|
||||
display_volume_level = yes
|
||||
display_bitrate = yes
|
||||
mouse_support = no
|
||||
colors_enabled = yes
|
||||
header_window_color = white
|
||||
volume_color = green
|
||||
state_line_color = red
|
||||
main_window_color = magenta
|
||||
color1 = green
|
||||
color2 = red
|
||||
main_window_highlight_color = green
|
||||
progressbar_color = black
|
||||
progressbar_elapsed_color = green
|
||||
statusbar_color = green
|
||||
alternative_ui_separator_color = black
|
||||
active_column_color = red
|
||||
window_border_color = magenta
|
||||
active_window_border = green
|
||||
|
||||
# vim: ft=conf
|
||||
song_window_title_format = "{%b}"
|
||||
alternative_header_first_line_format = "{$b$6%a$9} $1««$9 {$6%t$9}"
|
||||
alternative_header_second_line_format = "{$5%b$9} $1»»$9 {$5(%y)$9}"
|
||||
alternative_ui_separator_color = "black"
|
||||
playlist_separate_albums = "no"
|
||||
colors_enabled = "yes"
|
||||
empty_tag_color = "blue"
|
||||
header_window_color = "black"
|
||||
volume_color = "black"
|
||||
display_volume_level = "yes"
|
||||
state_line_color = "cyan"
|
||||
state_flags_color = "red"
|
||||
color1 = "white"
|
||||
color2 = "blue"
|
||||
progressbar_color = "cyan"
|
||||
window_border_color = "red"
|
||||
active_window_border = "red"
|
||||
|
|
|
@ -51,14 +51,6 @@ call plug#begin('~/.config/nvim/plugged')
|
|||
Plug 'equalsraf/neovim-gui-shim'
|
||||
endif
|
||||
|
||||
Plug 'tweekmonster/helpful.vim'
|
||||
Plug 'tweekmonster/startuptime.vim'
|
||||
|
||||
" if has('nvim') && s:platform ==? 'linux'
|
||||
" " Plug 'Shougo/denite.nvim', { 'do': ':UpdateRemotePlugins' }
|
||||
" Plug 'nixprime/cpsm'
|
||||
" endif
|
||||
|
||||
Plug 'ctrlpvim/ctrlp.vim'
|
||||
Plug 'FelikZ/ctrlp-py-matcher'
|
||||
Plug 'tacahiroy/ctrlp-funky'
|
||||
|
@ -66,77 +58,33 @@ call plug#begin('~/.config/nvim/plugged')
|
|||
Plug 'mileszs/ack.vim'
|
||||
Plug 'majutsushi/tagbar'
|
||||
Plug 'romainl/vim-qf'
|
||||
" Plug 'mtth/scratch.vim'
|
||||
" Plug 'airblade/vim-gitgutter'
|
||||
" Plug 'ludovicchabant/vim-gutentags'
|
||||
Plug 'junegunn/gv.vim'
|
||||
" Plug 'jreybert/vimagit'
|
||||
" Plug 'jceb/vim-orgmode'
|
||||
" Plug 'chrisbra/nrrwrgn'
|
||||
" Plug 'jmcantrell/vim-virtualenv'
|
||||
" Plug 'gregsexton/gitv'
|
||||
" Plug 'mhinz/vim-startify'
|
||||
" Plug 'unblevable/quick-scope'
|
||||
|
||||
" Plug 'vim-airline/vim-airline' | Plug 'vim-airline/vim-airline-themes'
|
||||
" Plug 'itchyny/lightline.vim'
|
||||
Plug 'vim-airline/vim-airline' | Plug 'vim-airline/vim-airline-themes'
|
||||
|
||||
if has('nvim')
|
||||
" Plug 'neomake/neomake'
|
||||
" Plug 'w0rp/ale'
|
||||
|
||||
" completion
|
||||
Plug 'roxma/python-support.nvim'
|
||||
Plug 'roxma/nvim-completion-manager'
|
||||
" Plug 'roxma/ncm-github'
|
||||
" Plug 'roxma/nvim-cm-tern', { 'do': 'npm install' }
|
||||
|
||||
Plug 'fgrsnau/ncm-otherbuf'
|
||||
Plug 'Shougo/neco-syntax'
|
||||
Plug 'Shougo/neoinclude.vim'
|
||||
" Plug 'mhartington/nvim-typescript', { 'do': 'npm install typescript' }
|
||||
Plug 'roxma/ncm-clang'
|
||||
|
||||
Plug 'SirVer/ultisnips' | Plug 'honza/vim-snippets'
|
||||
|
||||
" Rust
|
||||
Plug 'rust-lang/rust.vim'
|
||||
Plug 'racer-rust/vim-racer'
|
||||
Plug 'roxma/nvim-cm-racer'
|
||||
|
||||
" Python
|
||||
" Plug 'davidhalter/jedi-vim'
|
||||
" Plug 'tell-k/vim-autopep8'
|
||||
" Plug 'jmcantrell/vim-virtualenv'
|
||||
|
||||
" C/C++
|
||||
" Plug 'roxma/clang_complete'
|
||||
Plug 'roxma/ncm-clang'
|
||||
endif
|
||||
|
||||
" Plug 'roxma/vim-tmux-clipboard'
|
||||
" Plug 'tmux-plugins/vim-tmux-focus-events'
|
||||
" Plug 'whatyouhide/vim-tmux-syntax'
|
||||
|
||||
Plug 'othree/html5.vim'
|
||||
Plug 'mattn/emmet-vim'
|
||||
Plug 'chr4/nginx.vim'
|
||||
|
||||
" Plug 'Shougo/neco-vim'
|
||||
Plug 'lervag/vimtex'
|
||||
Plug 'neovimhaskell/haskell-vim'
|
||||
Plug 'chrisbra/csv.vim'
|
||||
|
||||
" Plug 'veegee/vim-pic'
|
||||
|
||||
Plug 'pearofducks/ansible-vim'
|
||||
Plug 'lifepillar/pgsql.vim'
|
||||
" Plug 'leafgarland/typescript-vim'
|
||||
Plug 'vim-pandoc/vim-pandoc'
|
||||
Plug 'vim-pandoc/vim-pandoc-syntax'
|
||||
Plug 'jparise/vim-graphql'
|
||||
" Plug 'kovetskiy/sxhkd-vim'
|
||||
" Plug 'mboughaba/i3config.vim'
|
||||
" Plug 'pangloss/vim-javascript'
|
||||
Plug 'vim-pandoc/vim-pandoc' | Plug 'vim-pandoc/vim-pandoc-syntax'
|
||||
Plug 'sheerun/vim-polyglot'
|
||||
Plug 'nickhutchinson/vim-cmake-syntax'
|
||||
call plug#end()
|
||||
|
@ -162,9 +110,6 @@ set background=dark
|
|||
let base16colorspace=256
|
||||
silent! colorscheme base16-tomorrow-night
|
||||
|
||||
" let g:onedark_termcolors=256
|
||||
" silent! colorscheme onedark
|
||||
|
||||
if has('shada')
|
||||
set shada=!,'100,<100,s100,h
|
||||
endif
|
||||
|
@ -180,14 +125,6 @@ else
|
|||
runtime macros/matchit.vim
|
||||
endif
|
||||
|
||||
" if executable("rg")
|
||||
" set grepprg=rg\ --vimgrep\ --no-heading
|
||||
" set grepformat=%f:%l:%c:%m,%f:%l:%m
|
||||
" elseif executable ('ag')
|
||||
" set grepprg=ag\ --vimgrep
|
||||
" set grepformat=%f:%l:%c:%m,%f:%l:%m
|
||||
" endif
|
||||
|
||||
" persistent undo
|
||||
if has('persistent_undo')
|
||||
set undodir=$HOME/.local/share/nvim/undo
|
||||
|
@ -210,7 +147,6 @@ set number
|
|||
set showmatch
|
||||
set ignorecase
|
||||
set smartcase
|
||||
" set shiftwidth=4 tabstop=4 softtabstop=4
|
||||
set splitright
|
||||
set splitbelow
|
||||
set noswapfile
|
||||
|
@ -282,7 +218,6 @@ let g:tex_comment_nospell = 1
|
|||
let g:netrw_banner = 0
|
||||
let g:netrw_keepdir = 0
|
||||
let g:netrw_liststyle = 3
|
||||
" let g:netrw_sort_options = 'i'
|
||||
let g:netrw_winsize = -28
|
||||
let g:netrw_sort_sequence = '[\/]$,*'
|
||||
let g:netrw_browse_split = 3
|
||||
|
@ -312,9 +247,6 @@ endfunction
|
|||
|
||||
command! -range=% HighlightRepeats <line1>,<line2>call HighlightRepeats()
|
||||
|
||||
" display the callstrack for recent exceptions
|
||||
command! Backtrace call exception#trace()
|
||||
|
||||
" :Grep <keyword>
|
||||
command! -nargs=1 -bar Grep execute 'silent! grep! <q-args>' | redraw! | copen
|
||||
|
||||
|
@ -374,20 +306,12 @@ augroup vimrc
|
|||
autocmd BufEnter term://* startinsert
|
||||
endif
|
||||
|
||||
" autocmd FileType help let b:helpful=1
|
||||
|
||||
" " TODO: remove this when I'm done taking the course
|
||||
" autocmd BufRead,BufNewFIle *.s set ft=pic8
|
||||
" autocmd BufRead,BufNewFile *.js set ft=javascript
|
||||
|
||||
autocmd FileType gitcommit
|
||||
\ nnoremap <buffer> <silent> <leader>cA
|
||||
\ :<C-U>Gcommit --amend --date="$(date)"<CR>
|
||||
|
||||
autocmd FileType GV setlocal foldlevel=1
|
||||
|
||||
" autocmd BufRead,BufNewFile *.csv set ft=csv
|
||||
|
||||
" delete fugitive buffer when hidden
|
||||
autocmd BufReadPost fugitive:// setlocal bufhidden=delete
|
||||
|
||||
|
@ -425,6 +349,7 @@ if exists('g:plugs["vim-polyglot"]')
|
|||
\ 'javascript',
|
||||
\ 'rust',
|
||||
\ 'tex',
|
||||
\ 'latex',
|
||||
\ 'markdown',
|
||||
\ 'haskell',
|
||||
\ 'lhaskell'
|
||||
|
@ -447,26 +372,16 @@ if exists('g:plugs["ctrlp.vim"]')
|
|||
let g:ctrlp_reuse_window = 'netrw\|help\|quickfix'
|
||||
let g:ctrlp_match_window = 'bottom,order:btt,min:1,max:15,results:15'
|
||||
|
||||
" mappings
|
||||
" nnoremap <c-b> :ctrlpbuffer<cr>
|
||||
" nnoremap <c-f> :ctrlpline<cr>
|
||||
|
||||
" leader mappings
|
||||
let g:ctrlp_map = '<C-p>'
|
||||
nnoremap <leader>. :CtrlPTag<CR>
|
||||
" nnoremap <leader>p :ctrlp<cr>
|
||||
" nnoremap <leader>b :ctrlpbuffer<cr>
|
||||
" nnoremap <leader>o :ctrlpmrufiles<cr>
|
||||
|
||||
nnoremap <leader>b :CtrlPBuffer<CR>
|
||||
nnoremap <leader>r :CtrlPMRUFiles<CR>
|
||||
nnoremap <leader>f :CtrlPFunky<CR>
|
||||
nnoremap <leader><C-f> :CtrlPFunky<CR>
|
||||
nnoremap <leader><C-l> :CtrlPLine<CR>
|
||||
|
||||
" nnoremap <C-x><C-r> :CtrlPMRUFiles<CR>
|
||||
|
||||
|
||||
if exists('g:plugs["ctrlp-funky"]')
|
||||
let g:ctrlp_funky_matchtype = 'path'
|
||||
let g:ctrlp_funky_multi_buffers = 1
|
||||
|
@ -516,7 +431,6 @@ endif
|
|||
if exists('g:plugs["gutentags"]')
|
||||
" let g:gutentags_generate_on_empty_buffer = 1
|
||||
let g:gutentags_ctags_tagfile = '.tags'
|
||||
|
||||
let g:gutentags_ctags_exclude = ['*node_modules*', 'tmp*', "package*json"]
|
||||
endif
|
||||
|
||||
|
@ -709,22 +623,6 @@ if exists('g:plugs["vim-airline"]')
|
|||
" let g:airline#extensions#tabline#fnamemod = ':t'
|
||||
endif
|
||||
|
||||
" }}}
|
||||
" lightline {{{
|
||||
|
||||
" if exists('g:plugs["lightline.vim"]')
|
||||
" let g:lightline =
|
||||
" \ { 'colorscheme': '',
|
||||
|
||||
" endif
|
||||
|
||||
" }}}
|
||||
" csv.vim {{{
|
||||
|
||||
if exists('g:plugs["csv.vim"]')
|
||||
let g:csv_delim=','
|
||||
endif
|
||||
|
||||
" }}}
|
||||
" vim-gitgutter {{{
|
||||
|
||||
|
@ -749,34 +647,6 @@ if exists('g:plugs["scratch.vim"]')
|
|||
xmap <leader>gS <plug>(scratch-selection-clear)
|
||||
endif
|
||||
|
||||
" }}}
|
||||
" vim-virtualenv {{{
|
||||
|
||||
if exists('g:plugs["vim-virtualenv"]')
|
||||
" TODO: configure this
|
||||
endif
|
||||
|
||||
" }}}
|
||||
" vim-ctrlspace {{{
|
||||
|
||||
if exists('g:plugs["vim-ctrlspace"]')
|
||||
if s:platform ==? 'linux'
|
||||
let g:CtrlSpaceFileEngine = 'file_engine_linux_amd64'
|
||||
|
||||
if executable('rg')
|
||||
let g:CtrlSpaceGlobCommand = 'rg -l --color=never -g ""'
|
||||
endif
|
||||
endif
|
||||
|
||||
nnoremap <silent><C-p> :CtrlSpace O<CR>
|
||||
endif
|
||||
|
||||
" }}}
|
||||
" vimagit {{{
|
||||
|
||||
if exists('g:plugs["vimagit"]')
|
||||
endif
|
||||
|
||||
" }}}
|
||||
" denite.nvim {{{
|
||||
|
||||
|
@ -796,8 +666,6 @@ if exists('g:plugs["denite.nvim"]')
|
|||
call denite#custom#map('insert', '<C-p>', '<denite:move_to_previous_line>', 'noremap')
|
||||
|
||||
call denite#custom#source('file_mru', 'matchers', ['matcher_fuzzy', 'matcher_project_files'])
|
||||
" call denite#custom#source('file_rec', 'matchers', ['matcher_cpsm'])
|
||||
|
||||
endif
|
||||
|
||||
" }}}
|
||||
|
@ -811,13 +679,6 @@ if exists('g:plugs["vim-pandoc"]')
|
|||
let g:pandoc#syntax#codeblocks#embeds#langs = ['bash=sh', 'bat=dosbatch']
|
||||
endif
|
||||
|
||||
" }}}
|
||||
" quick-scope {{{
|
||||
|
||||
if exists('g:plugs["quick-scope"]')
|
||||
let g:qs_highlight_on_keys = ['f', 'F', 't', 'T']
|
||||
endif
|
||||
|
||||
" }}}
|
||||
" pgsql.vim {{{
|
||||
|
||||
|
@ -829,7 +690,7 @@ endif
|
|||
" vim-virtualenv {{{
|
||||
|
||||
if exists('g:plugs["vim-virtualenv"]')
|
||||
let g:virtualenv_directory = $HOME . "/.venvs"
|
||||
let g:virtualenv_directory = $HOME . "/.local/share/virtualenvs"
|
||||
endif
|
||||
|
||||
" }}}
|
||||
|
|
|
@ -8,10 +8,6 @@
|
|||
load-module module-equalizer-sink sink_name=equalizer
|
||||
load-module module-dbus-protocol
|
||||
|
||||
# load bs2b ladspa sink using the equalizer as its master so that we
|
||||
# have the equalizer and bs2b active on on a single sink
|
||||
load-module module-ladspa-sink sink_name=crossfeed master=equalizer plugin=bs2b label=bs2b control=650,9.5
|
||||
|
||||
# prevent laptop from being loud if headphones are accidentially
|
||||
# unplugged.
|
||||
load-module module-switch-on-port-available
|
||||
|
|
|
@ -0,0 +1,129 @@
|
|||
configuration {
|
||||
modi: "window,run,drun";
|
||||
width: 50;
|
||||
lines: 15;
|
||||
columns: 1;
|
||||
font: "Iosevka 12";
|
||||
bw: 1;
|
||||
location: 0;
|
||||
padding: 5;
|
||||
yoffset: 0;
|
||||
xoffset: 0;
|
||||
fixed-num-lines: true;
|
||||
show-icons: true;
|
||||
terminal: "termite";
|
||||
ssh-client: "ssh";
|
||||
ssh-command: "{terminal} -e {ssh-client} {host}";
|
||||
run-command: "{cmd}";
|
||||
run-list-command: "";
|
||||
run-shell-command: "{terminal} -e {cmd}";
|
||||
window-command: "xkill -id {window}";
|
||||
/* drun-icon-theme: ; */
|
||||
disable-history: false;
|
||||
sort: false;
|
||||
levenshtein-sort: false;
|
||||
case-sensitive: false;
|
||||
cycle: true;
|
||||
sidebar-mode: true;
|
||||
eh: 1;
|
||||
auto-select: false;
|
||||
parse-hosts: false;
|
||||
parse-known-hosts: true;
|
||||
combi-modi: "window,run,drun";
|
||||
matching: "fuzzy";
|
||||
tokenize: true;
|
||||
m: "-5";
|
||||
line-margin: 2;
|
||||
line-padding: 1;
|
||||
/* filter: ; */
|
||||
separator-style: "solid";
|
||||
hide-scrollbar: true;
|
||||
fullscreen: false;
|
||||
fake-transparency: false;
|
||||
dpi: -1;
|
||||
threads: 0;
|
||||
scrollbar-width: 8;
|
||||
scroll-method: 1;
|
||||
fake-background: "screenshot";
|
||||
window-format: "{w} {i}{c} {t}";
|
||||
click-to-exit: true;
|
||||
show-match: true;
|
||||
/* theme: ; */
|
||||
color-normal: "#00383c4a, #c4cbd4, #96404552, #4084d6, #f9f9f9";
|
||||
color-urgent: "#002d303b, #cc6666, #e52d303b, #a54242, #f9f9f9";
|
||||
color-active: "#002d303b, #b5bd68, #e42d303b, #8c9440, #f9f9f9";
|
||||
color-window: "#f22d303b, #7c8389, #1d1f21";
|
||||
max-history-size: 25;
|
||||
pid: "/run/user/1000/rofi.pid";
|
||||
/* display-window: ; */
|
||||
/* display-windowcd: ; */
|
||||
/* display-run: ; */
|
||||
/* display-ssh: ; */
|
||||
/* display-drun: ; */
|
||||
/* display-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";
|
||||
kb-move-word-forward: "Alt+f";
|
||||
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,Control+h";
|
||||
kb-remove-to-eol: "Control+k";
|
||||
kb-remove-to-sol: "Control+u";
|
||||
kb-accept-entry: "Control+j,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,Control+ISO_Left_Tab";
|
||||
kb-row-left: "Control+Page_Up";
|
||||
kb-row-right: "Control+Page_Down";
|
||||
kb-row-up: "Up,Control+p,ISO_Left_Tab";
|
||||
kb-row-down: "Down,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-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";
|
||||
}
|
|
@ -1,5 +1,5 @@
|
|||
[options]
|
||||
font = Roboto Mono 10
|
||||
font = Iosevka Term 12
|
||||
scroll_on_output = false
|
||||
scroll_on_keystroke = true
|
||||
allow_bold = true
|
||||
|
@ -15,9 +15,7 @@ cursor_shape = block
|
|||
foreground = #c5c8c6
|
||||
foreground_bold = #c5c8c6
|
||||
cursor = #c5c8c6
|
||||
|
||||
# use rgba for transparency
|
||||
background = rgba(29, 31, 33, 0.95)
|
||||
background = #1d1f21
|
||||
|
||||
# black
|
||||
color0 = #1d1f21
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
# This file is written by xdg-user-dirs-update
|
||||
# If you want to change or add directories, just edit the line you're
|
||||
# interested in. All local changes will be retained on the next run.
|
||||
# Format is XDG_xxx_DIR="$HOME/yyy", where yyy is a shell-escaped
|
||||
# homedir-relative path, or XDG_xxx_DIR="/yyy", where /yyy is an
|
||||
# absolute path. No other format is supported.
|
||||
#
|
||||
XDG_DESKTOP_DIR="$HOME/desktop"
|
||||
XDG_DOWNLOAD_DIR="$HOME/downloads"
|
||||
XDG_TEMPLATES_DIR="$HOME/docs/templates"
|
||||
XDG_PUBLICSHARE_DIR="$HOME/docs/public-share"
|
||||
XDG_DOCUMENTS_DIR="$HOME/docs"
|
||||
XDG_MUSIC_DIR="$HOME/media/music"
|
||||
XDG_PICTURES_DIR="$HOME/media/pictures"
|
||||
XDG_VIDEOS_DIR="$HOME/media/videos"
|
File diff suppressed because it is too large
Load Diff
16
.gitconfig
16
.gitconfig
|
@ -4,16 +4,22 @@
|
|||
[color]
|
||||
ui = auto
|
||||
|
||||
[user]
|
||||
email = zyeryi@gmail.com
|
||||
name = Alexander Schmidt
|
||||
[url "ssh://git@github.com/"]
|
||||
insteadOf = https://github.com/
|
||||
|
||||
[url "ssh://git@bitbucket.org/"]
|
||||
insteadOf = https://bitbucket.org/
|
||||
|
||||
[url "ssh://git@gitlab.com/"]
|
||||
insteadOf = https://gitlab.com
|
||||
|
||||
[alias]
|
||||
ls = log -n 16 --pretty=format:"%C(yellow)%h\\ %C(cyan)[%cn]\\ %C(reset)%s\\ %C(red)%d" --decorate
|
||||
lo = log --pretty=format:"%C(yellow)%h\\ %C(cyan)[%cn]\\ %C(reset)%s\\ %C(red)%d" --decorate
|
||||
ls = log -n 16 --pretty=format:"%C(yellow)%h\\ %C(cyan)[%cn]\\ %C(reset)%s\\ %C(red)%d" --decorate
|
||||
lo = log --pretty=format:"%C(yellow)%h\\ %C(cyan)[%cn]\\ %C(reset)%s\\ %C(red)%d" --decorate
|
||||
ll = log --pretty=format:"%C(yellow)%h\\ %C(cyan)[%cn]\\ %C(reset)%s\\ %C(red)%ad" --decorate --date=short --stat
|
||||
tree = log --pretty=format:"%C(yellow)%h\\ %C(cyan)[%cn]\\ %C(reset)%s\\ %C(red)%d" --decorate --graph
|
||||
graph = log --graph --date-order --all --pretty=format:'%h %Cred%d %Cgreen%ad %Cblue%cn %Creset%s' --date=short
|
||||
graph2 = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all
|
||||
unstage = reset HEAD
|
||||
st = status
|
||||
ch = checkout
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
# vim: set ft=gtkrc :
|
||||
|
||||
gtk-theme-name="Arc-Dark"
|
||||
gtk-icon-theme-name="Paper"
|
||||
gtk-font-name="Noto Sans 11"
|
||||
gtk-cursor-theme-size=0
|
||||
gtk-toolbar-style=GTK_TOOLBAR_BOTH_HORIZ
|
||||
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
||||
gtk-button-images=0
|
||||
gtk-menu-images=0
|
||||
gtk-enable-event-sounds=1
|
||||
gtk-enable-input-feedback-sounds=1
|
||||
gtk-xft-antialias=1
|
||||
gtk-xft-hinting=1
|
||||
gtk-xft-hintstyle="hintslight"
|
||||
gtk-xft-rgba="rgb"
|
23
.inputrc
23
.inputrc
|
@ -3,21 +3,31 @@
|
|||
|
||||
$include /etc/inputrc
|
||||
|
||||
set meta-flag on
|
||||
set input-meta on
|
||||
set output-meta on
|
||||
set convert-meta on
|
||||
set convert-meta off
|
||||
|
||||
set visible-stats on
|
||||
set match-hidden-files on
|
||||
set page-completions on
|
||||
set completion-ignore-case on
|
||||
set completion-query-items 200
|
||||
set show-all-if-ambiguous on
|
||||
set show-all-if-unmodified on
|
||||
set echo-control-characters off
|
||||
set skip-completed-text on
|
||||
set match-hidden-files off
|
||||
|
||||
# colors
|
||||
set colored-stats on
|
||||
set visible-stats on
|
||||
set mark-symlinked-directories on
|
||||
set colored-completion-prefix on
|
||||
set menu-complete-display-prefix on
|
||||
|
||||
# vi-mode
|
||||
set editing-mode vi
|
||||
# set editing-mode vi
|
||||
|
||||
set editing-mode emacs
|
||||
|
||||
$if mode=vi
|
||||
set keymap vi-command
|
||||
|
@ -30,3 +40,8 @@ $if mode=vi
|
|||
"\C-p": history-search-backward
|
||||
"\C-n": history-search-forward
|
||||
$endif
|
||||
|
||||
$if mode=emacs
|
||||
"\C-p": history-search-backward
|
||||
"\C-n": history-search-forward
|
||||
$endif
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
# -*-: mode perl -*-
|
||||
# vi: set ft=perl :
|
||||
|
||||
$pdflatex = 'lualatex -interaction=nonstopmode -file-line-error -shell-escape -synctex=1 %O %S';
|
||||
$bibtex = 'biber -u -U';
|
||||
$pdf_previewer = '';
|
||||
$pdf_mode = 1;
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
SSH_AGENT_PID DEFAULT=
|
||||
SSH_AUTH_SOCK DEFAULT="${XDG_RUNTIME_DIR}/gnupg/S.gpg-agent.ssh"
|
|
@ -0,0 +1,19 @@
|
|||
# -*- mode: conf -*-
|
||||
# vim: ft=config:tw=80:et:cms=#\ %s
|
||||
|
||||
decorations none
|
||||
transparent false
|
||||
dockapp_mode none
|
||||
fuzzy_edges 0
|
||||
geometry 8x1+825+0
|
||||
background "#1d1f21"
|
||||
kludges force_icons_size
|
||||
grow_gravity E
|
||||
icon_gravity NE
|
||||
icon_size 20
|
||||
sticky true
|
||||
window_type dock
|
||||
window_layer bottom
|
||||
window_strut none
|
||||
skip_taskbar true
|
||||
sticky true
|
|
@ -0,0 +1,62 @@
|
|||
# tmux.conf
|
||||
|
||||
# bind prefix to C-a
|
||||
unbind C-b
|
||||
set -g prefix C-a
|
||||
bind C-a send-prefix
|
||||
|
||||
# split window in current dir
|
||||
bind s split-window -v -c '#{pane_current_path}'
|
||||
bind v split-window -h -c '#{pane_current_path}'
|
||||
|
||||
bind S list-sessions
|
||||
|
||||
# new window in current dir
|
||||
bind c new-window -a -c '#{pane_current_path}'
|
||||
|
||||
# toggle mouse
|
||||
bind-key m run-shell "if [[ $(tmux show-options | grep 'mouse on') ]]; then export toggle=disabled; else export toggle=enabled; fi; tmux display-message \"mouse: \$toggle\"; tmux set-window-option mouse &> /dev/null"
|
||||
|
||||
set -g default-terminal "tmux-256color"
|
||||
|
||||
# display longer pane indicators
|
||||
set -g display-panes-time 800
|
||||
|
||||
# renumber windows when one is closed
|
||||
set -g renumber-windows on
|
||||
|
||||
# start at 1 when assigning a pane index
|
||||
set-window-option -g pane-base-index 1
|
||||
|
||||
# start at 1 when assigning a window index
|
||||
set-option -g base-index 1
|
||||
|
||||
# use vi-style controls in copy mode
|
||||
set-window-option -g mode-keys vi
|
||||
set -g focus-events on
|
||||
|
||||
set -g visual-activity on
|
||||
set -g monitor-activity off
|
||||
|
||||
set-option -g set-titles on
|
||||
set-option -g set-titles-string '#S:#I.#P #W'
|
||||
|
||||
# appearance
|
||||
set -g status-right '#{prefix_highlight} | %a %Y-%m-%d %H:%M'
|
||||
|
||||
# plugins
|
||||
set -g @plugin 'tmux-plugins/tpm'
|
||||
set -g @plugin 'tmux-plugins/tmux-sensible'
|
||||
|
||||
set -g @plugin 'tmux-plugins/tmux-open'
|
||||
set -g @plugin 'tmux-plugins/tmux-yank'
|
||||
set -g @plugin 'tmux-plugins/tmux-copycat'
|
||||
|
||||
set -g @plugin 'tmux-plugins/tmux-sidebar'
|
||||
set -g @plugin 'tmux-plugins/tmux-pain-control'
|
||||
set -g @plugin 'tmux-plugins/tmux-prefix-highlight'
|
||||
|
||||
set -g @plugin 'seebi/tmux-colors-solarized'
|
||||
set -g @colors-solarized 'dark'
|
||||
|
||||
run '~/.tmux/plugins/tpm/tpm'
|
|
@ -1,12 +1,15 @@
|
|||
Config { font = "xft:Roboto Mono:size=10:medium:antialias=true"
|
||||
-- -*- mode: haskell -*-
|
||||
-- vi: set ft=haskell :
|
||||
|
||||
Config { font = "xft:Iosevka:size=12:antialias=true"
|
||||
, additionalFonts = ["xft:FontAwesome-10"]
|
||||
, bgColor = "#1d1f21"
|
||||
, fgColor = "#c5c8c6"
|
||||
, bgColor = "#1d1f21"
|
||||
, fgColor = "#c5c8c6"
|
||||
, position = Top
|
||||
, border = NoBorder
|
||||
, commands =
|
||||
[ Run UnsafeStdinReader
|
||||
, Run Date "%H:%M:%S - %y/%m/%d" "date" 10
|
||||
, Run Date "%F (%a) %T" "date" 10
|
||||
, Run Battery [ "--template", "batt: <acstatus>"
|
||||
, "--Low", "10"
|
||||
, "--High", "80"
|
||||
|
@ -21,10 +24,13 @@ Config { font = "xft:Roboto Mono:size=10:medium:antialias=true"
|
|||
, "-O" , "<fc=#b5bd68>Charging</fc>"
|
||||
-- charged status
|
||||
, "-i" , "<fc=#81a2be>Charged</fc>"] 60
|
||||
-- , Run MPD ["-t", "<state>: <title> by <artist>"] 10
|
||||
]
|
||||
, sepChar = "%"
|
||||
, alignSep = "}{"
|
||||
, template = " %UnsafeStdinReader% }{ %battery% | %date% "
|
||||
}
|
||||
|
||||
-- vim: ft=haskell
|
||||
-- , Run MPD ["-t",
|
||||
-- "<title> (<album>) <track>/<plength> <statei> [<flags>]",
|
||||
-- "--", "-P", ">>", "-Z", "|", "-S", "><"] 10
|
||||
|
|
|
@ -1,73 +1,97 @@
|
|||
-- xmonad.hs
|
||||
{-# OPTIONS_GHC -fno-warn-missing-signatures -fno-warn-orphans #-}
|
||||
{-# LANGUAGE TypeFamilies #-}
|
||||
|
||||
import XMonad hiding ( (|||) )
|
||||
import XMonad.Layout hiding ( (|||) )
|
||||
module Main (main) where
|
||||
|
||||
import XMonad hiding ((|||))
|
||||
import XMonad.Layout hiding ((|||))
|
||||
import XMonad.Operations
|
||||
|
||||
-- Layout
|
||||
-- layouts
|
||||
import XMonad.Layout.IM
|
||||
import XMonad.Layout.Gaps
|
||||
import XMonad.Layout.Grid
|
||||
import XMonad.Layout.ResizableTile
|
||||
import XMonad.Layout.BinarySpacePartition
|
||||
import XMonad.Layout.ThreeColumns
|
||||
import XMonad.Layout.Fullscreen
|
||||
|
||||
import XMonad.Layout.Spacing
|
||||
import XMonad.Layout.Reflect
|
||||
import XMonad.Layout.Renamed
|
||||
import XMonad.Layout.ShowWName
|
||||
import XMonad.Layout.NoBorders
|
||||
import XMonad.Layout.ResizableTile
|
||||
import XMonad.Layout.PerWorkspace
|
||||
import XMonad.Layout.LayoutCombinators
|
||||
import qualified XMonad.Layout.Renamed as R
|
||||
|
||||
-- Hooks
|
||||
import XMonad.Layout.LayoutCombinators
|
||||
import XMonad.Layout.MultiToggle
|
||||
import XMonad.Layout.MultiToggle.Instances
|
||||
|
||||
-- hooks
|
||||
import XMonad.Hooks.DynamicLog
|
||||
import XMonad.Hooks.ServerMode
|
||||
import XMonad.Hooks.DynamicBars
|
||||
import XMonad.Hooks.ManageDocks
|
||||
import XMonad.Hooks.ManageHelpers
|
||||
import XMonad.Hooks.EwmhDesktops
|
||||
import XMonad.Hooks.ServerMode
|
||||
import XMonad.Hooks.UrgencyHook
|
||||
import XMonad.Hooks.XPropManage
|
||||
import XMonad.Hooks.ManageHelpers
|
||||
import XMonad.Hooks.InsertPosition
|
||||
import XMonad.Hooks.EwmhDesktops (ewmh)
|
||||
import XMonad.Hooks.DynamicProperty
|
||||
|
||||
-- Actions
|
||||
-- actions
|
||||
import XMonad.Actions.Submap
|
||||
import XMonad.Actions.CycleWS
|
||||
import XMonad.Actions.RotSlaves
|
||||
import XMonad.Actions.Promote
|
||||
import XMonad.Actions.Commands
|
||||
import XMonad.Actions.TagWindows
|
||||
import XMonad.Actions.RotSlaves
|
||||
import XMonad.Actions.GridSelect
|
||||
import XMonad.Actions.PhysicalScreens
|
||||
import XMonad.Actions.DynamicWorkspaces
|
||||
import XMonad.Actions.Commands
|
||||
import qualified XMonad.Actions.FlexibleResize as FR
|
||||
import XMonad.Actions.SwapWorkspaces
|
||||
import XMonad.Actions.FindEmptyWorkspace
|
||||
import XMonad.Actions.DynamicWorkspaceGroups
|
||||
import XMonad.Actions.CopyWindow
|
||||
|
||||
-- floating keys
|
||||
import XMonad.Actions.FloatKeys
|
||||
import XMonad.Actions.FloatSnap
|
||||
|
||||
-- import XMonad.Actions.CopyWindow
|
||||
-- import XMonad.Actions.Submap
|
||||
-- import XMonad.Actions.GridSelect
|
||||
-- import XMonad.Actions.CopyWindow
|
||||
-- import XMonad.Actions.WindowMenu
|
||||
-- prompt
|
||||
import XMonad.Prompt
|
||||
import XMonad.Prompt.Pass
|
||||
import XMonad.Prompt.Workspace
|
||||
import XMonad.Prompt.RunOrRaise
|
||||
import XMonad.Prompt.ConfirmPrompt
|
||||
|
||||
-- Util
|
||||
-- util
|
||||
import XMonad.Util.Run
|
||||
import XMonad.Util.SpawnOnce
|
||||
import XMonad.Util.EZConfig
|
||||
import XMonad.Util.WorkspaceCompare
|
||||
import XMonad.Util.Scratchpad
|
||||
import XMonad.Util.NamedScratchpad
|
||||
|
||||
import qualified XMonad.Util.ExtensibleState as XS
|
||||
|
||||
-- Prompt
|
||||
import XMonad.Prompt
|
||||
import XMonad.Prompt.Workspace
|
||||
|
||||
-- other
|
||||
import qualified XMonad.StackSet as W
|
||||
import qualified Data.Map as M
|
||||
|
||||
import Data.Monoid
|
||||
import Data.Ratio ((%))
|
||||
-- misc
|
||||
import System.IO
|
||||
import System.Exit
|
||||
import System.Environment (getArgs)
|
||||
import Control.Monad (when)
|
||||
|
||||
import Data.List
|
||||
import Data.Ratio ((%))
|
||||
import Data.Monoid
|
||||
|
||||
import Graphics.X11.Types
|
||||
import Graphics.X11.Xinerama
|
||||
import Graphics.X11.ExtraTypes.XF86
|
||||
|
||||
import qualified DBus as D
|
||||
import qualified DBus.Client as D
|
||||
import qualified Codec.Binary.UTF8.String as UTF8
|
||||
import qualified Data.Set as S
|
||||
import qualified Data.Map as M
|
||||
|
||||
import qualified XMonad.StackSet as W
|
||||
import qualified XMonad.Util.Timer as T
|
||||
import qualified XMonad.Util.ExtensibleState as XS
|
||||
|
||||
-- | The default number of workspaces (virtual screens) and their names.
|
||||
-- By default we use numeric strings, but any string may be used as a
|
||||
|
@ -78,9 +102,8 @@ import qualified Codec.Binary.UTF8.String as UTF8
|
|||
--
|
||||
-- > workspaces = ["web", "irc", "code" ] ++ map show [4..9]
|
||||
--
|
||||
-- workspaces' = map show [1 .. 9 :: Int]
|
||||
workspaces' :: [WorkspaceId]
|
||||
workspaces' = map show [ 1..9 :: Int]
|
||||
workspaces' = map show [ 1..9 :: Int ]
|
||||
|
||||
-- | modMask lets you specify which modkey you want to use. The default
|
||||
-- is mod1Mask ("left alt"). You may also consider using mod3Mask
|
||||
|
@ -93,7 +116,7 @@ modMask' = mod4Mask
|
|||
-- | Width of the window border in pixels.
|
||||
--
|
||||
borderWidth' :: Dimension
|
||||
borderWidth' = 1
|
||||
borderWidth' = 2
|
||||
|
||||
-- | Border colors for unfocused and focused windows, respectively.
|
||||
--
|
||||
|
@ -101,19 +124,6 @@ normalBorderColor', focusedBorderColor' :: String
|
|||
normalBorderColor' = "#1d1f21"
|
||||
focusedBorderColor' = "#969896"
|
||||
|
||||
-- | The preferred terminal program, which is used in a binding below and by
|
||||
-- certain contrib modules.
|
||||
terminal' :: String
|
||||
terminal' = "/usr/bin/termite"
|
||||
|
||||
-- | Whether focus follows the mouse pointer.
|
||||
focusFollowsMouse' :: Bool
|
||||
focusFollowsMouse' = False
|
||||
|
||||
-- | Whether a mouse click select the focus or is just passed to the window
|
||||
clickJustFocuses' :: Bool
|
||||
clickJustFocuses' = True
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- Window rules
|
||||
|
||||
|
@ -125,35 +135,51 @@ clickJustFocuses' = True
|
|||
-- To find the property name associated with a program, use
|
||||
-- xprop | grep WM_CLASS
|
||||
-- and click on the client you're interested in.
|
||||
-- --
|
||||
avoidMaster :: W.StackSet i l a s sd -> W.StackSet i l a s sd
|
||||
avoidMaster = W.modify' $ modifyFunc
|
||||
where modifyFunc c@(W.Stack t [] (r:rs)) = W.Stack t [r] rs
|
||||
modifyFunc c@_ = c
|
||||
|
||||
--
|
||||
manageHook' :: ManageHook
|
||||
manageHook' = manageHooks'
|
||||
<+> namedScratchpadManageHook scratchpads
|
||||
<+> manageDocks
|
||||
<+> transience'
|
||||
manageHook' = composeAll
|
||||
[ appName =? "discord" --> doShift (workspaces' !! 8)
|
||||
, appName =? "google-chrome" --> doShift (workspaces' !! 0)
|
||||
, appName =? "telegram-desktop" --> doShift (workspaces' !! 8)
|
||||
|
||||
manageHooks' :: ManageHook
|
||||
manageHooks' = composeAll . concat $
|
||||
[ [ className =? c --> doShift (workspaces' !! 0) | c <- browsers ]
|
||||
, [ className =? c --> doShift (workspaces' !! 7) | c <- chatClients ]
|
||||
, [ className =? c --> doCenterFloat | c <- scratchpadFloats ]
|
||||
, [ className =? c --> doCenterFloat | c <- centerFloats ]
|
||||
, [ windowRole =? d --> doCenterFloat | d <- dialogs ]
|
||||
, [ fmap not isDialog --> doF avoidMaster
|
||||
, isDialog --> doCenterFloat
|
||||
, isFullscreen --> doFullFloat
|
||||
] ]
|
||||
where browsers = [ "Google-chrome" ]
|
||||
chatClients = [ "TelegramDesktop", "discord", "Slack" ]
|
||||
centerFloats = [ "Arandr", "VirtualBox" ]
|
||||
dialogs = [ "GtkFileChooserDialog" ]
|
||||
scratchpadFloats = [ "Zeal" ]
|
||||
windowRole = stringProperty "WM_WINDOW_ROLE"
|
||||
-- make these windows float around the center of the screen
|
||||
, appName =? "imv" --> doFullFloat
|
||||
, appName =? "zeal" --> doCenterFloat
|
||||
, appName =? "arandr" --> doCenterFloat
|
||||
, appName =? "synergy" --> doCenterFloat
|
||||
, appName =? "pinentry" --> doCenterFloat
|
||||
, appName =? "nitrogen" --> doCenterFloat
|
||||
, appName =? "keepassxc" --> doCenterFloat
|
||||
, appName =? "pavucontrol" --> doCenterFloat
|
||||
, appName =? "gcr-prompter" --> doCenterFloat
|
||||
, appName =? "nm-connection-editor" --> doCenterFloat
|
||||
|
||||
, className =? "mpv" --> doFullFloat
|
||||
|
||||
-- dialog windows
|
||||
, windowRole =? "Preferences" --> doCenterFloat
|
||||
, windowRole =? "GtkFileChooserDialog" --> doCenterFloat
|
||||
|
||||
-- misc hooks
|
||||
, isDialog --> doCenterFloat
|
||||
, isFullscreen --> doFullFloat
|
||||
, className =? "Dunst" --> doIgnore
|
||||
, className =? "stalonetray" --> doIgnore
|
||||
, resource =? "desktop_window" --> doIgnore
|
||||
|
||||
-- avoid the master pane
|
||||
, fmap not isDialog --> doF avoidMaster
|
||||
, namedScratchpadManageHook namedScratchpads'
|
||||
, scratchpadHook'
|
||||
]
|
||||
|
||||
avoidMaster :: W.StackSet i l a s sd -> W.StackSet i l a s sd
|
||||
avoidMaster = W.modify' $ \c -> case c of
|
||||
W.Stack t [] (r:rs) -> W.Stack t [r] rs
|
||||
otherwise -> c
|
||||
|
||||
windowRole :: XMonad.Query String
|
||||
windowRole = stringProperty "WM_WINDOW_ROLE"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- Logging
|
||||
|
@ -168,42 +194,54 @@ manageHooks' = composeAll . concat $
|
|||
-- See the 'DynamicLog' extension for examples.
|
||||
--
|
||||
|
||||
-- make a workspace clickable
|
||||
logHook' :: X ()
|
||||
logHook' = multiPP focusedPP unfocusedPP
|
||||
|
||||
-- | Make a workspace clickable
|
||||
clickable :: [Char] -> [Char]
|
||||
clickable w = "<action=`xdotool key super+" ++ w ++ "`>" ++ w ++ "</action>"
|
||||
clickable w = "<action=$(xdotool key super+" ++ w ++ ")>" ++ w ++ "</action>"
|
||||
|
||||
-- | Command to launch Xmobar with
|
||||
xmobarCommand :: Show a => a -> [Char]
|
||||
xmobarCommand s = "/usr/bin/xmobar ~/.xmonad/xmobarrc --screen=" ++ show s
|
||||
xmobarCommand s = "/usr/bin/xmobar $HOME/.xmobarrc --screen=" ++ show s
|
||||
|
||||
-- | Create a satusbar
|
||||
statusBarCreator :: DynamicStatusBar
|
||||
statusBarCreator (S sid) = do
|
||||
statusBarCreator (S sid) = do
|
||||
spawnPipe . xmobarCommand $ sid
|
||||
|
||||
-- | Remove a statusbar
|
||||
statusBarDestroyer :: DynamicStatusBarCleanup
|
||||
statusBarDestroyer = do return ()
|
||||
|
||||
focusedStatusBarPP :: PP
|
||||
focusedStatusBarPP = def
|
||||
{ ppCurrent = xmobarColor "#81A2BE" "" . wrap "[" "]" . clickable
|
||||
, ppHidden = xmobarColor "#707880" "" . clickable
|
||||
, ppHiddenNoWindows = wrap "" "" . clickable
|
||||
, ppTitle = shorten 40
|
||||
, ppVisible = wrap "(" ")" . clickable
|
||||
, ppUrgent = xmobarColor "#1d1f21" "#cc6666"
|
||||
, ppWsSep = " "
|
||||
, ppSep = " :: "
|
||||
, ppOrder = \(ws:l:_:_) -> [ws, l]
|
||||
-- | How workspaces should be sorted on the statusbar
|
||||
workspaceSort :: X WorkspaceSort
|
||||
workspaceSort = (. namedScratchpadFilterOutWorkspace) <$> getSortByIndex
|
||||
|
||||
-- | Focused screen
|
||||
focusedPP :: PP
|
||||
focusedPP = def
|
||||
{ ppCurrent = xmobarColor "#81A2BE" "" . clickable . wrap "[" "]"
|
||||
, ppVisible = xmobarColor "#969896" "" . clickable . wrap "(" ")"
|
||||
, ppHidden = xmobarColor "#5F819D" "" . clickable
|
||||
, ppUrgent = xmobarColor "#cc6666" "" . clickable . wrap " " " "
|
||||
, ppHiddenNoWindows = xmobarColor "#969896" "" . clickable
|
||||
, ppSort = workspaceSort
|
||||
, ppTitle = shorten 32
|
||||
}
|
||||
|
||||
unfocusedStatusBarPP :: PP
|
||||
unfocusedStatusBarPP = def
|
||||
{ ppCurrent = wrap "[" "]"
|
||||
, ppWsSep = " "
|
||||
-- | Unfocused screen
|
||||
unfocusedPP :: PP
|
||||
unfocusedPP = def
|
||||
{ ppCurrent = xmobarColor "#81A2BE" "" . clickable . wrap "[" "]"
|
||||
, ppVisible = xmobarColor "#969896" "" . clickable . wrap "(" ")"
|
||||
, ppHidden = xmobarColor "#5F819D" "" . clickable
|
||||
, ppUrgent = xmobarColor "#cc6666" "" . clickable . wrap " " " "
|
||||
, ppHiddenNoWindows = xmobarColor "#969896" "" . clickable
|
||||
, ppSort = workspaceSort
|
||||
, ppTitle = shorten 32
|
||||
}
|
||||
|
||||
logHook' = do
|
||||
multiPP focusedStatusBarPP unfocusedStatusBarPP
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- Event handling
|
||||
|
||||
|
@ -211,10 +249,8 @@ logHook' = do
|
|||
-- return (All True) if the default handler is to be run afterwards.
|
||||
-- To combine event hooks, use mappend or mconcat from Data.Monoid.
|
||||
handleEventHook' :: Event -> X All
|
||||
handleEventHook' =
|
||||
handleEventHook' = do
|
||||
serverModeEventHookCmd' defaultCommands'
|
||||
<+> fullscreenEventHook
|
||||
<+> docksEventHook
|
||||
<+> dynStatusBarEventHook statusBarCreator statusBarDestroyer
|
||||
|
||||
-- | Perform an arbitrary action at xmonad startup.
|
||||
|
@ -222,9 +258,6 @@ startupHook' :: X ()
|
|||
startupHook' = do
|
||||
dynStatusBarStartup statusBarCreator statusBarDestroyer
|
||||
|
||||
-- run startup script
|
||||
spawnOnce "/home/alex/bin/xmonad-startup.sh"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- Extensible layouts
|
||||
--
|
||||
|
@ -236,164 +269,289 @@ startupHook' = do
|
|||
|
||||
-- | The available layouts. Note that each layout is separated by |||, which
|
||||
-- denotes layout choice.
|
||||
|
||||
layoutHook' = avoidStruts . smartBorders
|
||||
. spacing 10 . gaps [(U, 15), (D, 20), (L, 20), (R, 20)]
|
||||
$ onWorkspace(workspaces' !! 7) telegramLayout
|
||||
layoutHook' = avoidStruts
|
||||
$ onWorkspace (workspaces' !! 8) telegram
|
||||
$ layouts
|
||||
where
|
||||
layouts = resizable
|
||||
||| Mirror resizable
|
||||
||| noBorders Full
|
||||
-- layout definitions
|
||||
layouts' = resizable
|
||||
||| grid
|
||||
||| threecol
|
||||
||| threemid
|
||||
|
||||
-- resizable Tall layout
|
||||
resizable = R.renamed [R.Replace "Tall"] $ ResizableTall nmaster delta ratio []
|
||||
-- add toggle modifiers
|
||||
layouts = mirror' $ borders' $ fullscreen' $ layouts'
|
||||
|
||||
-- The default number of windows in the master pane
|
||||
nmaster = 1
|
||||
-- toggle modifiers
|
||||
mirror' = mkToggle (single MIRROR)
|
||||
borders' = mkToggle (single NOBORDERS)
|
||||
fullscreen' = mkToggle (single NBFULL)
|
||||
|
||||
-- Default proportion of screen occupied by master pane
|
||||
ratio = toRational (2/(1 + sqrt 5 :: Double))
|
||||
-- rename a layout
|
||||
named n = renamed [Replace n]
|
||||
|
||||
-- Percent of screen to increment by when resizing panes
|
||||
delta = 3/100
|
||||
delta = (3%100)
|
||||
ratio = toRational (2/(1 + sqrt 5 :: Double))
|
||||
|
||||
-- use 35% of the screen for telegram
|
||||
telegramLayout = R.renamed [R.Replace "IM" ] $ reflectHoriz $ withIM (35%100) (ClassName "TelegramDesktop") ( reflectHoriz $ resizable ||| Mirror resizable)
|
||||
-- spacing and gaps
|
||||
spacing' = spacing 5
|
||||
gaps' = gaps [(U, 10), (D, 10), (L, 10), (R, 10)]
|
||||
|
||||
-- ResizableTall layout
|
||||
resizable = named "Tall"
|
||||
$ spacing'
|
||||
$ gaps'
|
||||
$ ResizableTall 1 delta ratio []
|
||||
|
||||
-- ThreeCol layout
|
||||
threecol = named "ThreeCol"
|
||||
$ spacing'
|
||||
$ gaps'
|
||||
$ ThreeCol 1 (3%100) (1%2)
|
||||
|
||||
-- ThreeColMid layout
|
||||
threemid = named "ThreeColMid"
|
||||
$ spacing'
|
||||
$ gaps'
|
||||
$ ThreeColMid 1 (3%100) (1%2)
|
||||
|
||||
-- Grid layout
|
||||
grid = named "Grid"
|
||||
$ spacing'
|
||||
$ gaps'
|
||||
$ Grid
|
||||
|
||||
-- layout for telegram
|
||||
telegramMatch = ClassName "TelegramDesktop"
|
||||
telegram' = withIM (35%100) telegramMatch Grid
|
||||
telegram = named "Grid"
|
||||
$ reflectHoriz
|
||||
$ spacing'
|
||||
$ gaps'
|
||||
$ telegram'
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- Key bindings:
|
||||
|
||||
-- | The preferred terminal program, which is used in a binding below and by
|
||||
-- certain contrib modules.
|
||||
terminal' :: String
|
||||
terminal' = "/usr/bin/termite"
|
||||
|
||||
-- | Whether focus follows the mouse pointer.
|
||||
focusFollowsMouse' :: Bool
|
||||
focusFollowsMouse' = False
|
||||
|
||||
-- | Whether a mouse click select the focus or is just passed to the window
|
||||
clickJustFocuses' :: Bool
|
||||
clickJustFocuses' = True
|
||||
|
||||
-- | The xmonad key bindings. Add, modify or remove key bindings here.
|
||||
--
|
||||
-- (The comment formatting character is used when generating the manpage)
|
||||
-- myKeys :: XConfig Layout -> M.Map (KeyMask, KeySym) (X ())
|
||||
-- myKeys conf@(XConfig {XMonad.modMask = modm}) = M.fromList $
|
||||
|
||||
--
|
||||
keys' :: XConfig Layout -> M.Map (KeyMask, KeySym) (X ())
|
||||
keys' conf@(XConfig {XMonad.modMask = modm}) = M.fromList $
|
||||
[ ((modm .|. shiftMask, xK_Return), spawn $ XMonad.terminal conf) -- %! Launch terminal
|
||||
, ((modm, xK_p ), spawn "dmenu_run") -- %! Launch dmenu
|
||||
, ((modm .|. shiftMask, xK_p ), spawn "gmrun") -- %! Launch gmrun
|
||||
, ((modm .|. shiftMask, xK_c ), kill) -- %! Close the focused window
|
||||
keys' = \c -> keybindings' c `M.union` mkKeymap c keymap'
|
||||
|
||||
, ((modm, xK_space ), sendMessage NextLayout) -- %! Rotate through the available layout algorithms
|
||||
, ((modm .|. shiftMask, xK_space ), setLayout $ XMonad.layoutHook conf) -- %! Reset the layouts on the current workspace to default
|
||||
|
||||
, ((modm, xK_n ), refresh) -- %! Resize viewed windows to the correct size
|
||||
|
||||
-- move focus up or down the window stack
|
||||
, ((modm, xK_Tab ), windows W.focusDown) -- %! Move focus to the next window
|
||||
, ((modm .|. shiftMask, xK_Tab ), windows W.focusUp ) -- %! Move focus to the previous window
|
||||
, ((modm, xK_j ), windows W.focusDown) -- %! Move focus to the next window
|
||||
, ((modm, xK_k ), windows W.focusUp ) -- %! Move focus to the previous window
|
||||
, ((modm, xK_m ), windows W.focusMaster ) -- %! Move focus to the master window
|
||||
|
||||
-- modifying the window order
|
||||
, ((modm, xK_Return), windows W.swapMaster) -- %! Swap the focused window and the master window
|
||||
, ((modm .|. shiftMask, xK_j ), windows W.swapDown ) -- %! Swap the focused window with the next window
|
||||
, ((modm .|. shiftMask, xK_k ), windows W.swapUp ) -- %! Swap the focused window with the previous window
|
||||
|
||||
-- resizing the master/slave ratio
|
||||
, ((modm, xK_h ), sendMessage Shrink) -- %! Shrink the master area
|
||||
, ((modm, xK_l ), sendMessage Expand) -- %! Expand the master area
|
||||
|
||||
-- floating layer support
|
||||
, ((modm, xK_t ), withFocused $ windows . W.sink) -- %! Push window back into tiling
|
||||
|
||||
-- increase or decrease number of windows in the master area
|
||||
, ((modm , xK_comma ), sendMessage (IncMasterN 1)) -- %! Increment the number of windows in the master area
|
||||
, ((modm , xK_period), sendMessage (IncMasterN (-1))) -- %! Deincrement the number of windows in the master area
|
||||
-- toggle floating for current window
|
||||
toggleFloat w = windows (\s -> if M.member w (W.floating s)
|
||||
then W.sink w s
|
||||
else (W.float w (W.RationalRect (1%5) (1%5) (3%5) (3%5)) s))
|
||||
|
||||
keymap' :: [(String, X ())]
|
||||
keymap' =
|
||||
[ ("M-<Return>", promote)
|
||||
-- quit, or restart
|
||||
, ((modm .|. shiftMask, xK_q ), io (exitWith ExitSuccess)) -- %! Quit xmonad
|
||||
, ((modm , xK_q ), spawn "if type xmonad; then xmonad --recompile && xmonad --restart; else xmessage xmonad not in \\$PATH: \"$PATH\"; fi") -- %! Restart xmonad<Paste>
|
||||
, ("M-S-q", confirmPrompt promptConfig "Quit XMonad" $ io (exitWith ExitSuccess))
|
||||
|
||||
, ((0, xF86XK_AudioRaiseVolume), spawn "pactl set-sink-volume 1 +2%")
|
||||
, ((0, xF86XK_AudioLowerVolume), spawn "pactl set-sink-volume 1 -2%")
|
||||
-- media keys
|
||||
, ((0, xF86XK_AudioMute), spawn "pactl set-sink-mute 1 toggle")
|
||||
, ((0, xF86XK_AudioNext), spawn "mpc -q next")
|
||||
, ((0, xF86XK_AudioPrev), spawn "mpc -q prev")
|
||||
, ((0, xF86XK_AudioPlay), spawn "mpc toggle")
|
||||
, ((0, xF86XK_AudioStop), spawn "mpc stop")
|
||||
--
|
||||
-- backlight
|
||||
, ((0, xF86XK_MonBrightnessUp), spawn "light -A 1.5%")
|
||||
, ((0, xF86XK_MonBrightnessDown), spawn "light -U 1.5%")
|
||||
-- volume controls
|
||||
, ("<XF86AudioMute>", spawn "pactl set-sink-mute 1 toggle")
|
||||
, ("<XF86AudioRaiseVolume>", spawn "pactl set-sink-volume 1 +2%")
|
||||
, ("<XF86AudioLowerVolume>", spawn "pactl set-sink-volume 1 -2%")
|
||||
|
||||
-- toggle struts 'n gaps
|
||||
, ((modm, xK_b), sendMessage $ ToggleStruts)
|
||||
, ((modm, xK_u), sendMessage $ ToggleGaps)
|
||||
, ("<XF86AudioStop>", spawn "mpc stop")
|
||||
, ("<XF86AudioNext>", spawn "mpc next")
|
||||
, ("<XF86AudioPrev>", spawn "mpc prev")
|
||||
, ("<XF86AudioPlay>", spawn "mpc toggle")
|
||||
|
||||
-- backlight controls
|
||||
, ("<XF86MonBrightnessUp>", spawn "light -A 1.5%")
|
||||
, ("<XF86MonBrightnessDown>", spawn "light -U 1.5%")
|
||||
|
||||
-- launch a terminal (urxvt)
|
||||
, ("C-M-<Return>", spawn "urxvt")
|
||||
|
||||
-- lock the screen
|
||||
, ((controlMask .|. mod1Mask, xK_l), spawn "/home/alex/bin/lock")
|
||||
|
||||
-- resize windows vertically
|
||||
, ((modm .|. shiftMask, xK_l), sendMessage MirrorShrink)
|
||||
, ((modm .|. shiftMask, xK_h), sendMessage MirrorExpand)
|
||||
|
||||
-- rotate workspaces
|
||||
, ((modm .|. shiftMask, xK_bracketleft ), rotAllUp)
|
||||
, ((modm .|. shiftMask, xK_bracketright), rotAllDown)
|
||||
, ("M-C-l", spawn "betterlockscreen -l")
|
||||
|
||||
-- move between workspaces
|
||||
, ((modm, xK_bracketleft ), moveTo Prev (WSIs notNSP))
|
||||
, ((modm, xK_bracketright ), moveTo Next (WSIs notNSP))
|
||||
, ("M-]", moveTo Next (WSIs notNSP'))
|
||||
, ("M-[", moveTo Prev (WSIs notNSP'))
|
||||
|
||||
-- move between screens
|
||||
, ((modm, xK_Right), nextScreen)
|
||||
, ((modm, xK_Left), prevScreen)
|
||||
, ("M-,", sendMessage (IncMasterN (-1)))
|
||||
, ("M-.", sendMessage (IncMasterN 1))
|
||||
|
||||
-- shift windows between screens
|
||||
, ((modm .|. shiftMask, xK_Right), shiftNextScreen)
|
||||
, ((modm .|. shiftMask, xK_Left), shiftPrevScreen)
|
||||
, ("M-M1-h", sendMessage MirrorExpand)
|
||||
, ("M-M1-l", sendMessage MirrorShrink)
|
||||
|
||||
, ((mod1Mask .|. controlMask .|. shiftMask, xK_Right), shiftToNext >> nextWS)
|
||||
, ((mod1Mask .|. controlMask .|. shiftMask, xK_Left), shiftToPrev >> prevWS)
|
||||
, ("M-<Up>", sendMessage MirrorExpand)
|
||||
, ("M-<Down>", sendMessage MirrorShrink)
|
||||
, ("M-<Left>", sendMessage Shrink)
|
||||
, ("M-<Right>", sendMessage Expand)
|
||||
|
||||
-- toggles
|
||||
, ("M-t f", sendMessage $ Toggle NBFULL)
|
||||
, ("M-t m", sendMessage $ Toggle MIRROR)
|
||||
, ("M-t b", sendMessage $ Toggle NOBORDERS)
|
||||
, ("M-t g", sendMessage ToggleGaps)
|
||||
, ("M-t s", sendMessage ToggleStruts)
|
||||
|
||||
-- swap current workspace with the previously displayed workspace
|
||||
, ((modm, xK_z), namedScratchpadAction scratchpads "zeal")
|
||||
-- sink the current floating window
|
||||
, ("M-s t", withFocused $ windows . W.sink)
|
||||
|
||||
, ((modm .|. shiftMask, xK_m ), workspacePrompt def (windows . W.shift))
|
||||
-- float the current tiled window
|
||||
, ("M-s f", withFocused toggleFloat)
|
||||
|
||||
, ((modm, xK_p), spawn "rofi -show run")
|
||||
, ((modm .|. controlMask, xK_x), spawn "/home/alex/bin/lock")
|
||||
-- scratchpads
|
||||
, ("M-s v", namedScratchpadAction namedScratchpads' "pavucontrol")
|
||||
, ("M-s k", namedScratchpadAction namedScratchpads' "keepassxc")
|
||||
, ("M-s m", namedScratchpadAction namedScratchpads' "arandr")
|
||||
, ("M-m", namedScratchpadAction namedScratchpads' "emacs")
|
||||
|
||||
-- launchers
|
||||
, ("M-p", spawn "rofi -show run")
|
||||
, ("M-o", spawn "rofi -show combi")
|
||||
]
|
||||
++
|
||||
[((mod4Mask .|. mask, key), f sc)
|
||||
| (key, sc) <- zip [xK_w, xK_e] [0..]
|
||||
, (f, mask) <- [(viewScreen, 0), (sendToScreen, shiftMask)]]
|
||||
++
|
||||
|
||||
-- default keys
|
||||
keybindings' :: XConfig Layout -> M.Map (KeyMask, KeySym) (X ())
|
||||
keybindings' conf@(XConfig {XMonad.modMask = modm}) = M.fromList $
|
||||
[ ((modm .|. shiftMask, xK_Return), spawn $ XMonad.terminal conf)
|
||||
, ((modm .|. shiftMask, xK_c ), kill)
|
||||
|
||||
, ((modm, xK_q), spawn "if type xmonad; then xmonad --recompile && xmonad --restart; else xmessage xmonad not in \\$PATH: \"$PATH\"; fi") -- %! Restart xmonad
|
||||
, ((modm, xK_space ), sendMessage NextLayout)
|
||||
, ((modm .|. shiftMask, xK_space), setLayout $ XMonad.layoutHook conf)
|
||||
|
||||
-- make focused window always visible
|
||||
, ((modm, xK_v), windows copyToAll)
|
||||
|
||||
-- toggle window state back
|
||||
, ((modm .|. shiftMask, xK_v), killAllOtherCopies)
|
||||
|
||||
-- move focus up or down the window stack
|
||||
, ((modm, xK_j), windows W.focusDown)
|
||||
, ((modm, xK_k), windows W.focusUp)
|
||||
|
||||
-- modifying the window order
|
||||
, ((modm .|. shiftMask, xK_j), windows W.swapDown)
|
||||
, ((modm .|. shiftMask, xK_k), windows W.swapUp)
|
||||
|
||||
-- resizing the master/slave ratio
|
||||
, ((modm, xK_h), sendMessage Shrink)
|
||||
, ((modm, xK_l), sendMessage Expand)
|
||||
]
|
||||
++
|
||||
[((m .|. mod4Mask, key), screenWorkspace sc >>= flip whenJust (windows . f)) | (key, sc) <- zip [xK_w, xK_e, xK_r] [0..], (f, m) <- [(W.view, 0), (W.shift, shiftMask)]]
|
||||
++
|
||||
zip (zip (repeat (mod4Mask)) [xK_1..xK_9]) (map (withNthWorkspace W.greedyView) [0..])
|
||||
++
|
||||
++
|
||||
zip (zip (repeat (mod4Mask .|. shiftMask)) [xK_1..xK_9]) (map (withNthWorkspace W.shift) [0..])
|
||||
++
|
||||
[ ((modm .|. controlMask, k), windows $ swapWithCurrent i) | (i, k) <- zip workspaces' [xK_1 ..]]
|
||||
|
||||
|
||||
mouseBindings' (XConfig {XMonad.modMask = modm}) = M.fromList $
|
||||
[ ((modm, button1), (\w -> focus w >> mouseMoveWindow w >> afterDrag (snapMagicMove (Just 50) (Just 50) w )))
|
||||
, ((modm, button2), (\w -> focus w >> windows W.swapMaster >> afterDrag (snapMagicResize [L,R,U,D] (Just 50) (Just 50) w )))
|
||||
, ((modm, button3), (\w -> focus w >> FR.mouseResizeWindow w >> afterDrag (snapMagicResize [L,R,U,D] (Just 50) (Just 50) w )))
|
||||
-- | Mouse bindings: default actions bound to mouse events
|
||||
mouseBindings' :: XConfig Layout -> M.Map (KeyMask, Button) (Window -> X ())
|
||||
mouseBindings' (XConfig {XMonad.modMask = modm}) = M.fromList
|
||||
[ ((modm, button1), \w -> focus w >> mouseMoveWindow w >> windows W.shiftMaster)
|
||||
, ((modm, button2), windows . (W.shiftMaster .) . W.focusWindow)
|
||||
, ((modm, button3), \w -> focus w >> mouseResizeWindow w >> windows W.shiftMaster)
|
||||
]
|
||||
--named scratchpads
|
||||
scratchpads = [ NS "zeal" "zeal" (className =? "Zeal") defaultFloating ]
|
||||
|
||||
-- Filter out the NSP workspace
|
||||
notNSP = (return $ ("NSP" /=) . W.tag) :: X (WindowSpace -> Bool)
|
||||
|
||||
-- custom command list
|
||||
-- | List of commands for ServerMode
|
||||
-- TODO: add more commands to this to make xmonadctl a little more useful?
|
||||
defaultCommands' :: X [(String, X ())]
|
||||
defaultCommands' = do
|
||||
return $ otherCommands
|
||||
where
|
||||
otherCommands =
|
||||
[
|
||||
("next-ws", moveTo Next (WSIs notNSP))
|
||||
, ("prev-ws", moveTo Prev (WSIs notNSP))
|
||||
]
|
||||
return $
|
||||
[ ("next-ws", moveTo Next (WSIs notNSP'))
|
||||
, ("prev-ws", moveTo Prev (WSIs notNSP'))
|
||||
|
||||
-- grid commands
|
||||
, ("grid-selected-focus", goToSelected $ gridSelectConfig colorizer')
|
||||
, ("grid-selected-bring", bringSelected $ gridSelectConfig colorizer')
|
||||
]
|
||||
|
||||
-- | Named scratchpads
|
||||
namedScratchpads' :: [NamedScratchpad]
|
||||
namedScratchpads' =
|
||||
[ NS "keepassxc" "keepassxc" (appName =? "keepassxc") floating'
|
||||
, NS "pavucontrol" "pavucontrol" (appName =? "pavucontrol") floating'
|
||||
, NS "arandr" "arandr" (appName =? "arandr") floating'
|
||||
, NS "emacs" "emacs" (appName =? "emacs") nonFloating
|
||||
]
|
||||
where floating' = customFloating $ W.RationalRect 0.2 0.2 0.6 0.6
|
||||
|
||||
-- | Hook for managing scratchpads
|
||||
scratchpadHook' :: ManageHook
|
||||
scratchpadHook' = scratchpadManageHook $ W.RationalRect l t w h
|
||||
where
|
||||
h = 0.25 -- terminal height
|
||||
w = 1 -- terminal width
|
||||
t = 0
|
||||
l = 1 - w
|
||||
|
||||
-- | Custom urgency hook
|
||||
urgencyHook' = withUrgencyHook NoUrgencyHook
|
||||
|
||||
-- | Check if a workspace is the named scratchpad workspace
|
||||
notNSP' :: X (WindowSpace -> Bool)
|
||||
notNSP' = (return $ ("NSP" /=) . W.tag) :: X (WindowSpace -> Bool)
|
||||
|
||||
-- | Add a tag to a window
|
||||
addTagHook :: String -> ManageHook
|
||||
addTagHook tag = do
|
||||
w <- ask
|
||||
liftX $ addTag tag w
|
||||
idHook
|
||||
|
||||
-- | GridSelect colorizer
|
||||
colorizer' :: Window -> Bool -> X (String, String)
|
||||
colorizer' = colorRangeFromClassName
|
||||
(0x00,0x00,0x00) -- lowest inactive bg
|
||||
(0x1C,0x1C,0x1C) -- highest inactive bg
|
||||
(0x44,0xAA,0xCC) -- active bg
|
||||
(0xBB,0xBB,0xBB) -- inactive fg
|
||||
(0x00,0x00,0x00) -- active fg
|
||||
|
||||
-- | GridSelect configuration
|
||||
gridSelectConfig :: t -> GSConfig Window
|
||||
gridSelectConfig colorizer = (buildDefaultGSConfig colorizer')
|
||||
{ gs_font = "xft:Iosevka:size=10:style=regular:antialias=true"
|
||||
, gs_cellpadding = 10
|
||||
, gs_cellheight = 50
|
||||
, gs_cellwidth = 200
|
||||
}
|
||||
|
||||
-- | Prompt configuration
|
||||
promptConfig :: XPConfig
|
||||
promptConfig = def
|
||||
{ font = "xft:Iosevka:size=12:style=regular:antialias=true"
|
||||
, position = CenteredAt (1%2) (1%2)
|
||||
, historyFilter = deleteConsecutive
|
||||
, historySize = 256
|
||||
, bgColor = "#1d1f21"
|
||||
, fgColor = "#c5c8c6"
|
||||
, height = 32
|
||||
, showCompletionOnTab = True
|
||||
, maxComplRows = Just 8
|
||||
, promptBorderWidth = 4
|
||||
, changeModeKey = xK_grave
|
||||
}
|
||||
|
||||
-- | XMonad
|
||||
main :: IO ()
|
||||
main = do
|
||||
|
||||
xmonad $ withUrgencyHook NoUrgencyHook $ ewmh $ def
|
||||
xmonad $ fullscreenSupport $ urgencyHook' $ docks $ ewmh $ def
|
||||
{ terminal = terminal'
|
||||
, modMask = modMask'
|
||||
, borderWidth = borderWidth'
|
||||
|
@ -403,10 +561,10 @@ main = do
|
|||
, clickJustFocuses = clickJustFocuses'
|
||||
, workspaces = workspaces'
|
||||
, layoutHook = layoutHook'
|
||||
, logHook = logHook'
|
||||
, manageHook = manageHook'
|
||||
, handleEventHook = handleEventHook'
|
||||
, startupHook = startupHook'
|
||||
, keys = keys'
|
||||
, mouseBindings = mouseBindings'
|
||||
}
|
||||
, logHook = logHook'
|
||||
}
|
||||
|
|
13
.xsession
13
.xsession
|
@ -1,13 +0,0 @@
|
|||
#!/usr/bin/env sh
|
||||
# TODO: rewrite this as a series of bash scripts that the various
|
||||
# window managers I have installed execute upon startup so that they
|
||||
# can each have different options.
|
||||
|
||||
# load Xresources
|
||||
[[ -f ~/.Xresources ]] && xrdb ~/.Xresources
|
||||
|
||||
# notifications daemon
|
||||
dunst &
|
||||
|
||||
# load wallpapers
|
||||
nitrogen --restore
|
469
.zshrc
469
.zshrc
|
@ -1,283 +1,208 @@
|
|||
# dotfiles location
|
||||
export DOTFILES=~/.dotfiles
|
||||
# ~/.zshrc
|
||||
|
||||
# locale options
|
||||
export LANG=en_US.UTF-8
|
||||
export LC_CTYPE="en_US.UTF-8"
|
||||
source $HOME/.zplug/init.zsh
|
||||
|
||||
# stops lag in vim
|
||||
zplug themes/mh, from:oh-my-zsh, as:theme
|
||||
zplug plugins/git, from:oh-my-zsh
|
||||
|
||||
zplug zsh-users/zsh-completions
|
||||
zplug zsh-users/zsh-history-substring-search
|
||||
zplug zsh-users/zsh-syntax-highlighting, defer:2
|
||||
|
||||
zplug load
|
||||
|
||||
ttyctl -f
|
||||
|
||||
setopt PROMPT_SUBST
|
||||
setopt auto_pushd
|
||||
setopt pushd_ignore_dups
|
||||
setopt long_list_jobs
|
||||
setopt interactivecomments
|
||||
setopt extended_glob
|
||||
setopt equals
|
||||
setopt complete_aliases
|
||||
setopt multios
|
||||
setopt autocd
|
||||
|
||||
setopt append_history
|
||||
setopt extended_history
|
||||
setopt hist_expire_dups_first
|
||||
setopt hist_ignore_dups
|
||||
setopt hist_ignore_space
|
||||
setopt hist_verify
|
||||
setopt inc_append_history
|
||||
setopt share_history
|
||||
|
||||
# completion
|
||||
zmodload -i zsh/complist
|
||||
|
||||
setopt auto_menu
|
||||
setopt complete_in_word
|
||||
setopt always_to_end
|
||||
|
||||
zstyle ":completion:*" menu select=2
|
||||
bindkey -M menuselect '^O' accept-and-infer-next-history
|
||||
zstyle ':completion:*:*:*:*:*' menu select
|
||||
|
||||
zstyle ':completion:*' rehash true
|
||||
zstyle ':completion:*' use-cache true
|
||||
zstyle ':completion:*' insert-tab pending
|
||||
|
||||
# fuzzy completion
|
||||
zstyle ':completion:*' completer _complete _match _approximate
|
||||
zstyle ':completion:*:match:*' original only
|
||||
zstyle ':completion:*approximate:*' max-errors 1 numeric
|
||||
|
||||
# use a cache to speed things up
|
||||
zstyle ':completion::complete:*' use-cache 1
|
||||
zstyle ':completion::complete:*' cache-path ~/.zsh/cache
|
||||
|
||||
zstyle ':completion:*:default' group-name ''
|
||||
zstyle ':completion:*:manuals' separate-sections true
|
||||
zstyle ':completion:*:manuals.(^1*)' insert-sections true
|
||||
zstyle ':completion:*' menu select
|
||||
zstyle ':completion:*' verbose yes
|
||||
|
||||
zstyle -e ':completion:*:approximate:*' max-errors 'reply=( $(( ($#PREFIX + $#SUFFIX) / 3 )) )'
|
||||
zstyle ':completion::approximate*:*' prefix-needed false
|
||||
|
||||
zstyle ':completion:*:*:kill:*' menu yes select
|
||||
zstyle ':completion:*:kill:*' force-list always
|
||||
|
||||
# bindings
|
||||
bindkey -v
|
||||
|
||||
# C-x C-e to edit current line in $EDITOR
|
||||
autoload -z edit-command-line
|
||||
zle -N edit-command-line
|
||||
bindkey "^X^E" edit-command-line
|
||||
|
||||
bindkey -M viins '^W' backward-kill-word
|
||||
bindkey -M viins '^H' backward-delete-char
|
||||
|
||||
bindkey '^P' history-substring-search-up
|
||||
bindkey '^N' history-substring-search-down
|
||||
|
||||
bindkey -M vicmd 'k' history-substring-search-up
|
||||
bindkey -M vicmd 'j' history-substring-search-down
|
||||
|
||||
bindkey -M vicmd '/' history-incremental-pattern-search-backward
|
||||
bindkey -M vicmd '?' history-incremental-pattern-search-forward
|
||||
|
||||
# aliases
|
||||
|
||||
# always sort directories first
|
||||
alias ls='ls --color=auto --group-directories-first'
|
||||
alias tree='tree --dirsfirst'
|
||||
alias diff='diff --color=always'
|
||||
|
||||
# short forms with useful flags
|
||||
alias l='ls -h -S -I ".git"'
|
||||
alias t='tree -I ".git"'
|
||||
|
||||
# ps with cgroups
|
||||
alias psc='ps xawf -eo pid,user,cgroup,args'
|
||||
|
||||
# misc
|
||||
|
||||
# commands/functions
|
||||
ranger-cd () {
|
||||
tempfile="$(mktemp -t tmp.XXXXXX)"
|
||||
/usr/bin/ranger --choosedir="$tempfile" "${@:-$(pwd)}"
|
||||
test -f "$tempfile" &&
|
||||
if [ "$(cat -- "$tempfile")" != "$(echo -n `pwd`)" ]; then
|
||||
cd -- "$(cat "$tempfile")"
|
||||
fi
|
||||
rm -f -- "$tempfile"
|
||||
}
|
||||
|
||||
fkill () {
|
||||
pid=$(ps -ef | sed 1d | fzf -m | awk '{print $2}')
|
||||
|
||||
if [ "x$pid" != "x" ]
|
||||
then
|
||||
kill -${1:-9} $pid
|
||||
fi
|
||||
}
|
||||
|
||||
fuck () {
|
||||
TF_PREVIOUS=$(fc -ln 1 | tail -n 1);
|
||||
TF_CMD=$(
|
||||
TF_ALIAS=fuck
|
||||
TF_SHELL_ALIAS=$(alias)
|
||||
PYTHONIOENCODING=utf-8
|
||||
thefuck $TF_PREVIOUS THEFUCK_ARGUMENT_PLACEHOLDER $*
|
||||
) && eval $TF_CMD
|
||||
test -n "$TF_CMD" && print -s $TF_CMD
|
||||
}
|
||||
|
||||
|
||||
# termite ctrl+shift+t support
|
||||
if [[ $TERM == xterm-termite ]] ; then
|
||||
. /etc/profile.d/vte.sh
|
||||
__vte_osc7
|
||||
fi
|
||||
|
||||
export NPM_PACKAGES="${HOME}/.npm-packages"
|
||||
export GOPATH="${HOME}/src/go"
|
||||
typeset -U path
|
||||
|
||||
path=(
|
||||
$HOME/bin
|
||||
$HOME/.zplug/bin
|
||||
$HOME/.cargo/bin
|
||||
$NPM_PACKAGES/bin
|
||||
$path[@]
|
||||
)
|
||||
|
||||
fpath=(
|
||||
$HOME/.zsh/zfunc
|
||||
$fpath
|
||||
)
|
||||
|
||||
# pager
|
||||
export PAGER=less
|
||||
export LESS='-R -f -X -i -P ?f%f:(stdin). ?lb%lb?L/%L.. [?eEOF:?pb%pb\%..]'
|
||||
export LESSCHARSET='utf-8'
|
||||
export MANPAGER="/usr/bin/nvim -c 'set ft=man' -"
|
||||
|
||||
# history
|
||||
export HISTFILE=~/.zsh_history
|
||||
export HISTSIZE=10000
|
||||
export SAVEHIST=100000
|
||||
export LISTMAX=100
|
||||
|
||||
export DIRSTACKSIZE=20
|
||||
|
||||
# disable history in root
|
||||
if [[ $UID == 0 ]] ; then
|
||||
unset HISTFILE
|
||||
export SAVEHIST=0
|
||||
fi
|
||||
|
||||
# system editor
|
||||
export EDITOR=/usr/bin/nvim
|
||||
|
||||
# fix tmux lag
|
||||
export KEYTIMEOUT=1
|
||||
|
||||
# set $TERM
|
||||
export TERM=screen-256color
|
||||
|
||||
# command for fzf to use
|
||||
export FZF_DEFAULT_COMMAND='(git ls-tree -r --name-only HEAD || ag -g "") 2> /dev/null'
|
||||
|
||||
# change the mode indication that vim-mode uses
|
||||
export MODE_INDICATOR="%{$fg_bold[yellow]%} [% NORMAL]% %{$reset_color%}"
|
||||
|
||||
# make ~/bin most preferred in PATH
|
||||
export PATH="$HOME/bin:$PATH"
|
||||
|
||||
# ---
|
||||
|
||||
# get the name of the branch we are on
|
||||
function git_prompt_info() {
|
||||
if [[ "$(command git config --get oh-my-zsh.hide-status 2>/dev/null)" != "1" ]]; then
|
||||
ref=$(command git symbolic-ref HEAD 2> /dev/null) || \
|
||||
ref=$(command git rev-parse --short HEAD 2> /dev/null) || return 0
|
||||
echo "$ZSH_THEME_GIT_PROMPT_PREFIX${ref#refs/heads/}$(parse_git_dirty)$ZSH_THEME_GIT_PROMPT_SUFFIX"
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
# Checks if working tree is dirty
|
||||
parse_git_dirty() {
|
||||
local STATUS=''
|
||||
local FLAGS
|
||||
FLAGS=('--porcelain')
|
||||
if [[ "$(command git config --get oh-my-zsh.hide-dirty)" != "1" ]]; then
|
||||
if [[ $POST_1_7_2_GIT -gt 0 ]]; then
|
||||
FLAGS+='--ignore-submodules=dirty'
|
||||
fi
|
||||
if [[ "$DISABLE_UNTRACKED_FILES_DIRTY" == "true" ]]; then
|
||||
FLAGS+='--untracked-files=no'
|
||||
fi
|
||||
STATUS=$(command git status ${FLAGS} 2> /dev/null | tail -n1)
|
||||
fi
|
||||
if [[ -n $STATUS ]]; then
|
||||
echo "$ZSH_THEME_GIT_PROMPT_DIRTY"
|
||||
else
|
||||
echo "$ZSH_THEME_GIT_PROMPT_CLEAN"
|
||||
fi
|
||||
}
|
||||
|
||||
# get the difference between the local and remote branches
|
||||
git_remote_status() {
|
||||
remote=${$(command git rev-parse --verify ${hook_com[branch]}@{upstream} --symbolic-full-name 2>/dev/null)/refs\/remotes\/}
|
||||
if [[ -n ${remote} ]] ; then
|
||||
ahead=$(command git rev-list ${hook_com[branch]}@{upstream}..HEAD 2>/dev/null | wc -l)
|
||||
behind=$(command git rev-list HEAD..${hook_com[branch]}@{upstream} 2>/dev/null | wc -l)
|
||||
|
||||
if [ $ahead -eq 0 ] && [ $behind -eq 0 ]
|
||||
then
|
||||
git_remote_status="$ZSH_THEME_GIT_PROMPT_EQUAL_REMOTE"
|
||||
elif [ $ahead -gt 0 ] && [ $behind -eq 0 ]
|
||||
then
|
||||
git_remote_status="$ZSH_THEME_GIT_PROMPT_AHEAD_REMOTE"
|
||||
git_remote_status_detailed="$ZSH_THEME_GIT_PROMPT_AHEAD_REMOTE_COLOR$ZSH_THEME_GIT_PROMPT_AHEAD_REMOTE$((ahead))%{$reset_color%}"
|
||||
elif [ $behind -gt 0 ] && [ $ahead -eq 0 ]
|
||||
then
|
||||
git_remote_status="$ZSH_THEME_GIT_PROMPT_BEHIND_REMOTE"
|
||||
git_remote_status_detailed="$ZSH_THEME_GIT_PROMPT_BEHIND_REMOTE_COLOR$ZSH_THEME_GIT_PROMPT_BEHIND_REMOTE$((behind))%{$reset_color%}"
|
||||
elif [ $ahead -gt 0 ] && [ $behind -gt 0 ]
|
||||
then
|
||||
git_remote_status="$ZSH_THEME_GIT_PROMPT_DIVERGED_REMOTE"
|
||||
git_remote_status_detailed="$ZSH_THEME_GIT_PROMPT_AHEAD_REMOTE_COLOR$ZSH_THEME_GIT_PROMPT_AHEAD_REMOTE$((ahead))%{$reset_color%}$ZSH_THEME_GIT_PROMPT_BEHIND_REMOTE_COLOR$ZSH_THEME_GIT_PROMPT_BEHIND_REMOTE$((behind))%{$reset_color%}"
|
||||
fi
|
||||
|
||||
if [ $ZSH_THEME_GIT_PROMPT_REMOTE_STATUS_DETAILED ]
|
||||
then
|
||||
git_remote_status="$ZSH_THEME_GIT_PROMPT_REMOTE_STATUS_PREFIX$remote$git_remote_status_detailed$ZSH_THEME_GIT_PROMPT_REMOTE_STATUS_SUFFIX"
|
||||
fi
|
||||
|
||||
echo $git_remote_status
|
||||
fi
|
||||
}
|
||||
|
||||
# Gets the number of commits ahead from remote
|
||||
function git_commits_ahead() {
|
||||
if $(echo "$(command git log @{upstream}..HEAD 2> /dev/null)" | grep '^commit' &> /dev/null); then
|
||||
COMMITS=$(command git log @{upstream}..HEAD | grep '^commit' | wc -l | tr -d ' ')
|
||||
echo "$ZSH_THEME_GIT_COMMITS_AHEAD_PREFIX$COMMITS$ZSH_THEME_GIT_COMMITS_AHEAD_SUFFIX"
|
||||
fi
|
||||
}
|
||||
|
||||
# Outputs if current branch is ahead of remote
|
||||
function git_prompt_ahead() {
|
||||
if [[ -n "$(command git rev-list origin/$(current_branch)..HEAD 2> /dev/null)" ]]; then
|
||||
echo "$ZSH_THEME_GIT_PROMPT_AHEAD"
|
||||
fi
|
||||
}
|
||||
|
||||
# Outputs if current branch is behind remote
|
||||
function git_prompt_behind() {
|
||||
if [[ -n "$(command git rev-list HEAD..origin/$(current_branch) 2> /dev/null)" ]]; then
|
||||
echo "$ZSH_THEME_GIT_PROMPT_BEHIND"
|
||||
fi
|
||||
}
|
||||
|
||||
# Outputs if current branch exists on remote or not
|
||||
function git_prompt_remote() {
|
||||
if [[ -n "$(command git show-ref origin/$(current_branch) 2> /dev/null)" ]]; then
|
||||
echo "$ZSH_THEME_GIT_PROMPT_REMOTE_EXISTS"
|
||||
else
|
||||
echo "$ZSH_THEME_GIT_PROMPT_REMOTE_MISSING"
|
||||
fi
|
||||
}
|
||||
|
||||
# Formats prompt string for current git commit short SHA
|
||||
function git_prompt_short_sha() {
|
||||
SHA=$(command git rev-parse --short HEAD 2> /dev/null) && echo "$ZSH_THEME_GIT_PROMPT_SHA_BEFORE$SHA$ZSH_THEME_GIT_PROMPT_SHA_AFTER"
|
||||
}
|
||||
|
||||
# Formats prompt string for current git commit long SHA
|
||||
function git_prompt_long_sha() {
|
||||
SHA=$(command git rev-parse HEAD 2> /dev/null) && echo "$ZSH_THEME_GIT_PROMPT_SHA_BEFORE$SHA$ZSH_THEME_GIT_PROMPT_SHA_AFTER"
|
||||
}
|
||||
|
||||
# Get the status of the working tree
|
||||
git_prompt_status() {
|
||||
INDEX=$(command git status --porcelain -b 2> /dev/null)
|
||||
STATUS=""
|
||||
if $(echo "$INDEX" | command grep -E '^\?\? ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_UNTRACKED$STATUS"
|
||||
fi
|
||||
if $(echo "$INDEX" | grep '^A ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_ADDED$STATUS"
|
||||
elif $(echo "$INDEX" | grep '^M ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_ADDED$STATUS"
|
||||
fi
|
||||
if $(echo "$INDEX" | grep '^ M ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_MODIFIED$STATUS"
|
||||
elif $(echo "$INDEX" | grep '^AM ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_MODIFIED$STATUS"
|
||||
elif $(echo "$INDEX" | grep '^ T ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_MODIFIED$STATUS"
|
||||
fi
|
||||
if $(echo "$INDEX" | grep '^R ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_RENAMED$STATUS"
|
||||
fi
|
||||
if $(echo "$INDEX" | grep '^ D ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_DELETED$STATUS"
|
||||
elif $(echo "$INDEX" | grep '^D ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_DELETED$STATUS"
|
||||
elif $(echo "$INDEX" | grep '^AD ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_DELETED$STATUS"
|
||||
fi
|
||||
if $(command git rev-parse --verify refs/stash >/dev/null 2>&1); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_STASHED$STATUS"
|
||||
fi
|
||||
if $(echo "$INDEX" | grep '^UU ' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_UNMERGED$STATUS"
|
||||
fi
|
||||
if $(echo "$INDEX" | grep '^## .*ahead' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_AHEAD$STATUS"
|
||||
fi
|
||||
if $(echo "$INDEX" | grep '^## .*behind' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_BEHIND$STATUS"
|
||||
fi
|
||||
if $(echo "$INDEX" | grep '^## .*diverged' &> /dev/null); then
|
||||
STATUS="$ZSH_THEME_GIT_PROMPT_DIVERGED$STATUS"
|
||||
fi
|
||||
echo $STATUS
|
||||
}
|
||||
|
||||
#compare the provided version of git to the version installed and on path
|
||||
#prints 1 if input version <= installed version
|
||||
#prints -1 otherwise
|
||||
function git_compare_version() {
|
||||
local INPUT_GIT_VERSION=$1;
|
||||
local INSTALLED_GIT_VERSION
|
||||
INPUT_GIT_VERSION=(${(s/./)INPUT_GIT_VERSION});
|
||||
INSTALLED_GIT_VERSION=($(command git --version 2>/dev/null));
|
||||
INSTALLED_GIT_VERSION=(${(s/./)INSTALLED_GIT_VERSION[3]});
|
||||
|
||||
for i in {1..3}; do
|
||||
if [[ $INSTALLED_GIT_VERSION[$i] -gt $INPUT_GIT_VERSION[$i] ]]; then
|
||||
echo 1
|
||||
return 0
|
||||
fi
|
||||
if [[ $INSTALLED_GIT_VERSION[$i] -lt $INPUT_GIT_VERSION[$i] ]]; then
|
||||
echo -1
|
||||
return 0
|
||||
fi
|
||||
done
|
||||
echo 0
|
||||
}
|
||||
|
||||
#this is unlikely to change so make it all statically assigned
|
||||
POST_1_7_2_GIT=$(git_compare_version "1.7.2")
|
||||
#clean up the namespace slightly by removing the checker function
|
||||
unset -f git_compare_version
|
||||
|
||||
# ---
|
||||
|
||||
# ls colors
|
||||
autoload -U colors && colors
|
||||
export LSCOLORS="Gxfxcxdxbxegedabagacad"
|
||||
|
||||
# Enable ls colors
|
||||
if [ "$DISABLE_LS_COLORS" != "true" ]
|
||||
then
|
||||
# Find the option for using colors in ls, depending on the version: Linux or BSD
|
||||
if [[ "$(uname -s)" == "NetBSD" ]]; then
|
||||
# On NetBSD, test if "gls" (GNU ls) is installed (this one supports colors);
|
||||
# otherwise, leave ls as is, because NetBSD's ls doesn't support -G
|
||||
gls --color -d . &>/dev/null 2>&1 && alias ls='gls --color=tty'
|
||||
elif [[ "$(uname -s)" == "OpenBSD" ]]; then
|
||||
# On OpenBSD, "gls" (ls from GNU coreutils) and "colorls" (ls from base,
|
||||
# with color and multibyte support) are available from ports. "colorls"
|
||||
# will be installed on purpose and can't be pulled in by installing
|
||||
# coreutils, so prefer it to "gls".
|
||||
gls --color -d . &>/dev/null 2>&1 && alias ls='gls --color=tty'
|
||||
colorls -G -d . &>/dev/null 2>&1 && alias ls='colorls -G'
|
||||
else
|
||||
ls --color -d . &>/dev/null 2>&1 && alias ls='ls --color=tty' || alias ls='ls -G'
|
||||
fi
|
||||
unset SSH_AGENT_PID
|
||||
if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
|
||||
export SSH_AUTH_SOCK="/run/user/$UID/gnupg/S.gpg-agent.ssh"
|
||||
fi
|
||||
|
||||
#setopt no_beep
|
||||
setopt auto_cd
|
||||
setopt multios
|
||||
setopt cdablevars
|
||||
# Set GPG TTY
|
||||
export GPG_TTY=$(tty)
|
||||
|
||||
if [[ x$WINDOW != x ]]
|
||||
then
|
||||
SCREEN_NO="%B$WINDOW%b "
|
||||
else
|
||||
SCREEN_NO=""
|
||||
fi
|
||||
# Refresh gpg-agent tty in case user switches into an X session
|
||||
gpg-connect-agent updatestartuptty /bye >/dev/null
|
||||
|
||||
# Apply theming defaults
|
||||
PS1="%n@%m:%~%# "
|
||||
# fzf
|
||||
source /usr/share/fzf/key-bindings.zsh
|
||||
source /usr/share/fzf/completion.zsh
|
||||
|
||||
# git theming default: Variables for theming the git info prompt
|
||||
ZSH_THEME_GIT_PROMPT_PREFIX="git:(" # Prefix at the very beginning of the prompt, before the branch name
|
||||
ZSH_THEME_GIT_PROMPT_SUFFIX=")" # At the very end of the prompt
|
||||
ZSH_THEME_GIT_PROMPT_DIRTY="*" # Text to display if the branch is dirty
|
||||
ZSH_THEME_GIT_PROMPT_CLEAN="" # Text to display if the branch is clean
|
||||
export RANGER_LOAD_DEFAULT_RC=false
|
||||
|
||||
# Setup the prompt with pretty colors
|
||||
setopt prompt_subst
|
||||
BASE16_SHELL="$HOME/.config/base16-shell/"
|
||||
[ -n "$PS1" ] && [ -s $BASE16_SHELL/profile_helper.sh ] && eval "$($BASE16_SHELL/profile_helper.sh)"
|
||||
|
||||
# ---
|
||||
|
||||
|
||||
# disable annoying things
|
||||
setopt no_beep
|
||||
|
||||
# disable ^S
|
||||
setopt no_flowcontrol
|
||||
|
||||
# ---
|
||||
|
||||
# enable prompt and colors
|
||||
autoload -U compinit promptinit colors
|
||||
compinit && promptinit && colors
|
||||
|
||||
# bindings for history-substring
|
||||
bindkey '^P' history-substring-search-up
|
||||
bindkey '^N' histroy-substring-search-down
|
||||
|
||||
# load local shell configuration if present
|
||||
if [[ -f ~/.zshrc.local ]]
|
||||
then
|
||||
source ~/.zshrc.local
|
||||
fi
|
||||
|
||||
# load fzf
|
||||
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
|
||||
|
||||
prompt walters
|
||||
|
|
Loading…
Reference in New Issue