Moving to X11, better gaming exp. - dotfiles - Unnamed repository; edit this fi… | |
Log | |
Files | |
Refs | |
README | |
--- | |
commit 406144df3d4c0ddd9f25bc8113c78525953d1299 | |
parent 1a92abacbd9178d67fa34a030a9ab80b4b596849 | |
Author: Jay Scott <[email protected]> | |
Date: Thu, 5 Oct 2023 20:59:49 +0100 | |
Moving to X11, better gaming exp. | |
Diffstat: | |
M .gitignore | 18 +++++------------- | |
M README | 16 +++++++--------- | |
A X11/Xresources | 98 +++++++++++++++++++++++++++++… | |
A X11/xinitrc | 13 +++++++++++++ | |
A alacritty/alacritty.yml | 40 +++++++++++++++++++++++++++++… | |
D ashrc | 51 -----------------------------… | |
A bashrc | 53 ++++++++++++++++++++++++++++++ | |
R bin/old/dwmstatus.sh -> bin/dwmsta… | 0 | |
A bin/game_select.sh | 18 ++++++++++++++++++ | |
D bin/old/game_select.sh | 17 ----------------- | |
R bin/sway-run.sh -> bin/old/sway-ru… | 0 | |
M bootstrap.sh | 4 ++-- | |
D castgetrc | 44 -----------------------------… | |
D foot/foot.ini | 27 --------------------------- | |
D mpd/mpd.conf | 20 -------------------- | |
D ncmpcpp/config | 31 -----------------------------… | |
M newsraft/feeds | 6 +++--- | |
M profile | 2 +- | |
D slrn/colors | 125 -----------------------------… | |
D slrn/config | 45 -----------------------------… | |
D slrn/score | 26 -------------------------- | |
D slrn/slrnpull.conf | 50 -----------------------------… | |
A suckless/dmenu/Makefile | 39 +++++++++++++++++++++++++++++… | |
A suckless/dmenu/config.h | 16 ++++++++++++++++ | |
A suckless/dmenu/patches/01-dmenu-bo… | 36 +++++++++++++++++++++++++++… | |
A suckless/dmenu/patches/02-dmenu-ce… | 120 +++++++++++++++++++++++++++… | |
A suckless/dwm/Makefile | 35 +++++++++++++++++++++++++++++… | |
A suckless/dwm/config.h | 195 +++++++++++++++++++++++++++++… | |
A suckless/herbe/Makefile | 40 +++++++++++++++++++++++++++++… | |
A suckless/herbe/config.h | 19 +++++++++++++++++++ | |
D sway/config | 89 -----------------------------… | |
31 files changed, 740 insertions(+), 553 deletions(-) | |
--- | |
diff --git a/.gitignore b/.gitignore | |
@@ -14,24 +14,16 @@ ncmpcpp/error.log | |
# misc | |
*.swp | |
-bin/lf | |
-bin/senpai | |
bin/terraform | |
-bin/neonmodem | |
-bin/gitleaks | |
bin/golangci-lint | |
# vim | |
vim/bundle | |
-# slrn | |
-slrn/out.going | |
-slrn/data | |
-slrn/log | |
-slrn/news | |
-slrn/requests | |
-slrn/authinfo | |
-slrn/jnews* | |
- | |
# mutt contacts | |
mutt/aliases | |
+ | |
+# suckless | |
+suckless/dwm/src | |
+suckless/dmenu/src | |
+suckless/herbe/src | |
diff --git a/README b/README | |
@@ -1,23 +1,21 @@ | |
|> dotfiles | |
-I am a long time supporter of the Unix philosophy which is reflected in | |
-the daily tooling I use. Since 2011, I mainly use the terminal for | |
-everything. | |
+Since 2011, I mainly use the terminal for everything. | |
Privacy is at the forefront of my mind as such some of my browser | |
settings maybe too restrictive for some. I also don't use social media | |
at all, the closest I come is using IRC. | |
- operating sys : alpine linux | |
- window manager : sway | |
- terminal : foot | |
- launcher : bemenu | |
+ operating sys : archlinux / alpine linux | |
+ window manager : dwm | |
+ terminal : alacritty | |
+ launcher : dmenu | |
email : mutt / isync | |
browser : qutebrowser | |
video : mpv | |
- music : mpd / ncmpcpp | |
+ music : mpv | |
password mgt : pass | |
vpn : mullvad | |
- news : newsboat | |
+ news : newsraft | |
diff --git a/X11/Xresources b/X11/Xresources | |
@@ -0,0 +1,98 @@ | |
+! vim:ft=xdefaults | |
+ | |
+/* COLOURS */ | |
+#define RED0 #cc0403 | |
+#define RED1 #f2201f | |
+#define GREEN0 #19cb00 | |
+#define GREEN1 #23fd00 | |
+#define YELLOW0 #cecb00 | |
+#define YELLOW1 #fffd00 | |
+#define BLUE0 #0d73cc | |
+#define BLUE1 #1a8fff | |
+#define MAGENTA0 #cb1ed1 | |
+#define MAGENTA1 #fd28ff | |
+#define CYAN0 #0dcdcd | |
+#define CYAN1 #14ffff | |
+#define BLACK #000000 | |
+#define GREY1 #767676 | |
+#define GREY2 #dddddd | |
+#define WHITE #ffffff | |
+ | |
+#define FONT Hack:size=14 | |
+ | |
+/* XFT */ | |
+Xft.dpi: 96 | |
+Xft.hinting: true | |
+Xft.rgba: rgb | |
+Xft.antialias: true | |
+Xft.autohint: false | |
+Xft.hintstyle: hintslight | |
+Xft.lcdfilter: lcddefault | |
+ | |
+*.foreground: WHITE | |
+*.background: BLACK | |
+ | |
+/* NORMAL */ | |
+*.color0: BLACK | |
+*.color1: RED0 | |
+*.color2: GREEN0 | |
+*.color3: YELLOW0 | |
+*.color4: BLUE0 | |
+*.color5: MAGENTA0 | |
+*.color6: CYAN0 | |
+*.color7: GREY2 | |
+ | |
+/* BRIGHT */ | |
+*.color8: GREY1 | |
+*.color9: RED1 | |
+*.color10: GREEN1 | |
+*.color11: YELLOW1 | |
+*.color12: BLUE1 | |
+*.color13: MAGENTA1 | |
+*.color14: CYAN1 | |
+*.color15: WHITE | |
+ | |
+! | |
+! Generated with : | |
+! XRDB2Xreources.py | |
+! | |
+*.foreground: #e6d4a3 | |
+*.background: #1e1e1e | |
+*.cursorColor: #bbbbbb | |
+! | |
+! Black | |
+*.color0: #161819 | |
+*.color8: #7f7061 | |
+! | |
+! Red | |
+*.color1: #f73028 | |
+*.color9: #be0f17 | |
+! | |
+! Green | |
+*.color2: #aab01e | |
+*.color10: #868715 | |
+! | |
+! Yellow | |
+*.color3: #f7b125 | |
+*.color11: #cc881a | |
+! | |
+! Blue | |
+*.color4: #719586 | |
+*.color12: #377375 | |
+! | |
+! Magenta | |
+*.color5: #c77089 | |
+*.color13: #a04b73 | |
+! | |
+! Cyan | |
+*.color6: #7db669 | |
+*.color14: #578e57 | |
+! | |
+! White | |
+*.color7: #faefbb | |
+*.color15: #e6d4a3 | |
+! | |
+! Bold, Italic, Underline | |
+*.colorBD: #978771 | |
+!*.colorIT: | |
+!*.colorUL: | |
diff --git a/X11/xinitrc b/X11/xinitrc | |
@@ -0,0 +1,13 @@ | |
+# x stuff | |
+setxkbmap gb | |
+xset s off -dpms | |
+xrdb -load ~/.config/X11/Xresources | |
+ | |
+if [ -z "$XDG_RUNTIME_DIR" ]; then | |
+ mkdir -p /tmp/runtime/jay | |
+ chmod 700 /tmp/runtime/jay | |
+ export XDG_RUNTIME_DIR=/tmp/runtime/jay | |
+fi | |
+ | |
+~/bin/dwmstatus.sh & | |
+exec dwm | |
diff --git a/alacritty/alacritty.yml b/alacritty/alacritty.yml | |
@@ -0,0 +1,40 @@ | |
+font: | |
+ normal: | |
+ family: Hack | |
+ style: Regular | |
+ | |
+ size: 15 | |
+ | |
+env: | |
+ TERM: xterm-256color | |
+ | |
+# Colors (Gruvbox dark) | |
+colors: | |
+ # Default colors | |
+ primary: | |
+ # hard contrast: background = '0x1d2021' | |
+ background: '0x282828' | |
+ # soft contrast: background = '0x32302f' | |
+ foreground: '0xebdbb2' | |
+ | |
+ # Normal colors | |
+ normal: | |
+ black: '0x282828' | |
+ red: '0xcc241d' | |
+ green: '0x98971a' | |
+ yellow: '0xd79921' | |
+ blue: '0x458588' | |
+ magenta: '0xb16286' | |
+ cyan: '0x689d6a' | |
+ white: '0xa89984' | |
+ | |
+ # Bright colors | |
+ bright: | |
+ black: '0x928374' | |
+ red: '0xfb4934' | |
+ green: '0xb8bb26' | |
+ yellow: '0xfabd2f' | |
+ blue: '0x83a598' | |
+ magenta: '0xd3869b' | |
+ cyan: '0x8ec07c' | |
+ white: '0xebdbb2' | |
diff --git a/ashrc b/ashrc | |
@@ -1,51 +0,0 @@ | |
-export XDG_CONFIG_HOME="$HOME/.config" | |
-export XDG_CACHE_HOME="$HOME/.cache" | |
-export XDG_DATA_HOME="$HOME/.local/share" | |
-export XDG_STATE_HOME="$HOME/.local/state" | |
- | |
-# cleanup ~/ | |
-export PASSWORD_STORE_DIR="$XDG_CONFIG_HOME"/pass | |
-export XINITRC="$XDG_CONFIG_HOME"/X11/xinitrc | |
-export XAUTHORITY="$XDG_RUNTIME_DIR"/Xauthority | |
-export CARGO_HOME="$XDG_DATA_HOME"/cargo | |
-alias wget='wget --hsts-file="$XDG_CACHE_HOME/wget-hsts"' | |
- | |
-# common exports | |
-GPG_TTY=$(tty) | |
-export GPG_TTY | |
-export EDITOR="vim" | |
-export BROWSER="qutebrowser" | |
-export GOPATH="$XDG_DATA_HOME"/go | |
-export GOPROXY=direct | |
-export PATH=$PATH:$GOPATH/bin:$HOME/bin:$HOME/.local/bin | |
-export PS1="[\[$(tput sgr0)\]\[\033[38;5;7m\]\W\[$(tput sgr0)\]] \\$ \[$(tput … | |
- | |
-export BEMENU_OPTS="-p '> ' --tb '#013220' --tf '#ffffff' --hf '#444444'" | |
- | |
-# terraform config | |
-export TF_CLOUD_ORGANIZATION="jay-scot" | |
-export TF_WORKSPACE="hetzner" | |
- | |
-# lynx | |
-export LYNX_CFG=$HOME/.config/lynx/config | |
-export LYNX_LSS=$HOME/.config/lynx/theme.lss | |
- | |
-# slrn | |
-export NNTPSERVER='snews://news.eternal-september.org:563' | |
-alias slrn='slrn -i ~/.config/slrn/config -f ~/.config/slrn/jnewsrc' | |
-alias slrnpull='slrnpull -d ~/.config/slrn/' | |
- | |
-# safety first kids! | |
-alias cp='cp -i' | |
-alias mv='mv -i' | |
-alias rm='rm -i' | |
- | |
-# random alias | |
-alias weather='curl wttr.in/?1QF' | |
- | |
-# git alias | |
-alias ga='git add -A' | |
-alias gs='git status -s' | |
-alias gl="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset… | |
-alias gd='git diff' | |
-alias gma='git commit -am' | |
diff --git a/bashrc b/bashrc | |
@@ -0,0 +1,53 @@ | |
+if [[ -r /usr/share/bash-completion/bash_completion ]]; then | |
+ . /usr/share/bash-completion/bash_completion | |
+fi | |
+ | |
+export XDG_CONFIG_HOME="$HOME/.config" | |
+export XDG_CACHE_HOME="$HOME/.cache" | |
+export XDG_DATA_HOME="$HOME/.local/share" | |
+export XDG_STATE_HOME="$HOME/.local/state" | |
+ | |
+# cleanup ~/ | |
+export PASSWORD_STORE_DIR="$XDG_CONFIG_HOME"/pass | |
+export XINITRC="$XDG_CONFIG_HOME"/X11/xinitrc | |
+export XAUTHORITY="$XDG_RUNTIME_DIR"/Xauthority | |
+export CARGO_HOME="$XDG_DATA_HOME"/cargo | |
+alias wget='wget --hsts-file="$XDG_CACHE_HOME/wget-hsts"' | |
+ | |
+# common exports | |
+GPG_TTY=$(tty) | |
+export GPG_TTY | |
+export EDITOR="vim" | |
+export BROWSER="qutebrowser" | |
+export GOPATH="$XDG_DATA_HOME"/go | |
+export GOPROXY=direct | |
+export PATH=$PATH:$GOPATH/bin:$HOME/bin:$HOME/.local/bin | |
+export PS1="[\[$(tput sgr0)\]\[\033[38;5;7m\]\W\[$(tput sgr0)\]] \\$ \[$(tput … | |
+ | |
+export BEMENU_OPTS="-p '> ' --tb '#013220' --tf '#ffffff' --hf '#444444'" | |
+ | |
+# terraform config | |
+export TF_CLOUD_ORGANIZATION="jay-scot" | |
+export TF_WORKSPACE="hetzner" | |
+ | |
+# lynx | |
+export LYNX_CFG=$HOME/.config/lynx/config | |
+export LYNX_LSS=$HOME/.config/lynx/theme.lss | |
+ | |
+# safety first kids! | |
+alias cp='cp -i' | |
+alias mv='mv -i' | |
+alias rm='rm -i' | |
+ | |
+# random alias | |
+alias weather='curl wttr.in/?1QF' | |
+alias ls='ls --color=auto' | |
+ | |
+# git alias | |
+alias ga='git add -A' | |
+alias gs='git status -s' | |
+alias gl="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset… | |
+alias gd='git diff' | |
+alias gma='git commit -am' | |
+ | |
+source ~/.secret | |
diff --git a/bin/old/dwmstatus.sh b/bin/dwmstatus.sh | |
diff --git a/bin/game_select.sh b/bin/game_select.sh | |
@@ -0,0 +1,18 @@ | |
+#!/bin/sh | |
+ | |
+games=$(printf "%s\n" "Gibbous" "AtomRPG" "Primordia" | dmenu -p "games »") | |
+ | |
+[ -z "$games" ] && exit 0 | |
+ | |
+case "$games" in | |
+"Gibbous") | |
+ ~/media/games/gibbous/start.sh | |
+ ;; | |
+"AtomRPG") | |
+ ~/media/games/atomrpg/start.sh | |
+ ;; | |
+"Primordia") | |
+ ~/media/games/primordia/start.sh | |
+ /data/games/enterthegungeon/start.sh | |
+ ;; | |
+esac | |
diff --git a/bin/old/game_select.sh b/bin/old/game_select.sh | |
@@ -1,17 +0,0 @@ | |
-#!/bin/sh | |
- | |
-games=$(printf "%s\n" "Kathy Rain" "Beneath A Steel Sky" "Enter The Gungeon" |… | |
- | |
-[ -z "$games" ] && exit 0 | |
- | |
-case "$games" in | |
-"Kathy Rain") | |
- /data/games/kathy_rain/start.sh | |
- ;; | |
-"Beneath A Steel Sky") | |
- /data/games/beneath_a_steel_sky/start.sh | |
- ;; | |
-"Enter The Gungeon") | |
- /data/games/enterthegungeon/start.sh | |
- ;; | |
-esac | |
diff --git a/bin/sway-run.sh b/bin/old/sway-run.sh | |
diff --git a/bootstrap.sh b/bootstrap.sh | |
@@ -2,9 +2,9 @@ | |
DOTFILES=$(pwd) | |
-FILES='ashrc castgetrc profile vimrc' | |
+FILES='bashrc profile vimrc' | |
ROOT='bin' | |
-CONFIG='foot git isync lynx mpd mutt ncmpcpp newsraft qutebrowser senpai slrn … | |
+CONFIG='alacritty git isync lynx mutt newsraft qutebrowser senpai X11' | |
link() { | |
for f in $FILES; do ln -sfn "$DOTFILES/$f" "$HOME/.$f"; done | |
diff --git a/castgetrc b/castgetrc | |
@@ -1,44 +0,0 @@ | |
-[*] | |
-spool=/home/jay/media/podcasts | |
-filename=%(date)-%(title).mp3 | |
- | |
- | |
-[2600] | |
-url=https://www.2600.com/oth-broadband.xml | |
-spool=/home/jay/media/podcasts/offthehook | |
- | |
-[cory-doctorows] | |
-url=http://feeds.feedburner.com/doctorow_podcast | |
-spool=/home/jay/media/podcasts/cory-doctorows | |
- | |
-[corecursive] | |
-url=https://link.chtbl.com/corecursive?id=corecursive&platform=rss | |
-spool=/home/jay/media/podcasts/corecursive | |
- | |
-[commandlineheroes] | |
-url=https://feeds.pacific-content.com/commandlineheroes | |
-spool=/home/jay/media/podcasts/commandlineheroes | |
- | |
-[hpr] | |
-url=http://hackerpublicradio.org/hpr_rss.php | |
-spool=/home/jay/media/podcasts/hacker-public-radio | |
- | |
-[ask-noah] | |
-url=https://feeds.fireside.fm/asknoah/rss | |
-spool=/home/jay/media/podcasts/ask-noah | |
- | |
-[2.5-admins] | |
-url=https://2.5admins.com/feed/podcast | |
-spool=/home/jay/media/podcasts/2.5-admins | |
- | |
-[going-linux] | |
-url=https://goinglinux.com/mp3podcast.xml | |
-spool=/home/jay/media/podcasts/going-linux | |
- | |
-[living-adventurously] | |
-url=https://feeds.transistor.fm/living-adventurously | |
-spool=/home/jay/media/podcasts/living-adventurously | |
- | |
-[selfhosted] | |
-url=https://feeds.fireside.fm/selfhosted/rss | |
-spool=/home/jay/media/podcasts/selfhosted | |
diff --git a/foot/foot.ini b/foot/foot.ini | |
@@ -1,27 +0,0 @@ | |
-font=Hack:size=14 | |
- | |
-[url] | |
-launch=link_handler.sh ${url} | |
- | |
-[key-bindings] | |
-show-urls-launch=Control+Shift+p | |
- | |
-[colors] | |
-background=282828 | |
-foreground=ebdbb2 | |
-regular0=282828 | |
-regular1=cc241d | |
-regular2=98971a | |
-regular3=d79921 | |
-regular4=458588 | |
-regular5=b16286 | |
-regular6=689d6a | |
-regular7=a89984 | |
-bright0=928374 | |
-bright1=fb4934 | |
-bright2=b8bb26 | |
-bright3=fabd2f | |
-bright4=83a598 | |
-bright5=d3869b | |
-bright6=8ec07c | |
-bright7=ebdbb2 | |
diff --git a/mpd/mpd.conf b/mpd/mpd.conf | |
@@ -1,20 +0,0 @@ | |
-music_directory "/home/jay/media/music" | |
-playlist_directory "/home/jay/.config/mpd/playlists" | |
-db_file "/home/jay/.config/mpd/mpd.db" | |
-log_file "syslog" | |
-pid_file "/home/jay/.config/mpd/mpd.pid" | |
-state_file "/home/jay/.config/mpd/mpdstate" | |
- | |
-audio_output { | |
- type "pulse" | |
- name "pulse audio" | |
-} | |
-audio_output { | |
- type "fifo" | |
- name "my_fifo" | |
- path "/tmp/mpd.fifo" | |
- format "44100:16:2" | |
-} | |
- | |
-bind_to_address "127.0.0.1" | |
-port "6600" | |
diff --git a/ncmpcpp/config b/ncmpcpp/config | |
@@ -1,31 +0,0 @@ | |
-# visual stuff for 8 | |
-visualizer_data_source = /tmp/mpd.fifo | |
-visualizer_output_name = my_fifo | |
-visualizer_in_stereo = no | |
-visualizer_type = spectrum | |
-visualizer_look = ∙▋ | |
-visualizer_color = 7,5,8,3 | |
-song_columns_list_format = "(50)[green]{a} (50)[white]{t|f}" | |
- | |
-playlist_display_mode = columns | |
-browser_display_mode = columns | |
- | |
-ncmpcpp_directory = ~/.config/ncmpcpp | |
-lyrics_directory = /tmp | |
-store_lyrics_in_song_dir = yes | |
-autocenter_mode = "yes" | |
-centered_cursor = "yes" | |
-cyclic_scrolling = "no" | |
- | |
-titles_visibility = "no" | |
-header_visibility = "no" | |
-statusbar_visibility = "no" | |
-progressbar_look = "❙❙❙" | |
-progressbar_color = "white" | |
- | |
-user_interface = "classic" | |
- | |
-startup_screen = playlist | |
-startup_slave_screen = visualizer | |
-startup_slave_screen_focus = no | |
-locked_screen_width_part = 35 | |
diff --git a/newsraft/feeds b/newsraft/feeds | |
@@ -12,11 +12,13 @@ https://old.reddit.com/r/ukbike/.rss "R UKBike" | |
https://old.reddit.com/r/nosurf/.rss "R NoSurf" | |
https://old.reddit.com/r/shortwave/.rss "R Shortwave" | |
-@ RADIO | |
+@ OUTDOORS | |
https://www.hfunderground.com/board/index.php?type=rss;action=.xml | |
+https://bushcraftuk.com/community/forums/-/index.rss | |
@ MEDIA | |
https://showrss.info/other/all.rss "TV Torrents" | |
+http://feed.rutracker.cc/atom/f/1992.atom "RU Tracker" | |
@ GAMING | |
https://www.gamingonlinux.com/article_rss.php "Gaming On Linux" | |
@@ -26,8 +28,6 @@ https://blog.qutebrowser.org/feeds/all.atom.xml "Qutebrowser" | |
https://newsboat.org/news.atom "Newsboat" | |
https://git.sr.ht/~taiite/senpai/log/master/rss.xml "Senpai" | |
https://github.com/mlj/castget/commits.atom "Castget" | |
-https://status.hetzner.com/en.atom "Hetzner" | |
-https://gitlab.alpinelinux.org/alpine/aports/-/issues.atom "aports issues" | |
@ PEOPLE | |
https://codemadness.org/atom.xml "CodeMadness" | |
diff --git a/profile b/profile | |
@@ -1,2 +1,2 @@ | |
-export ENV=$HOME/.ashrc | |
+export ENV=$HOME/.bashrc | |
. $ENV | |
diff --git a/slrn/colors b/slrn/colors | |
@@ -1,125 +0,0 @@ | |
-% | |
-%% 9. Display / color settings | |
-% | |
- | |
-% If non-zero, slrn will draw the thread tree using simple ascii characters | |
-%set simulate_graphic_chars 0 | |
- | |
-% Enable xterm/win32 mouse support: 1 to enable, 0 to disable | |
-%set mouse 1 | |
- | |
-% Draw cursor bar ala tin instead of slrn "->" cursor? | |
-set display_cursor_bar 1 | |
- | |
-% Set to 1 to have slrn scroll by full page instead of by line. | |
-%set scroll_by_page 0 | |
- | |
-% Should color be used to indicate the score of an article? | |
-% (0) scores do not influence colors (1) scores are colored by their value | |
-% (2) subjects are colored by score (3) both are colored by score | |
-%set color_by_score 3 | |
- | |
-% If non-zero, the subjects of unread articles are highlighted | |
-set highlight_unread_subjects 2 | |
- | |
-% If non-zero, URLs are highlighted. | |
-set highlight_urls 1 | |
- | |
-% Enables blinking in monochrome mode and allows bright backgrounds in some | |
-% color terminals: | |
-set use_blink 0 | |
- | |
-% This color object is only used when highlight_unread_subjects is set to 2 | |
-% (see the reference manual for details): | |
-color unread_subject "default" "default" | |
-mono unread_subject "none" | |
- | |
-% These settings are used for color terminals: | |
-color article "default" "default" | |
-color author "default" "default" | |
-color boldtext "white" "default" | |
-color box "black" "white" | |
-color cursor "default" "default" "reverse" | |
-color date "default" "default" | |
-color description "default" "default" | |
-color error "brightred" "default" | |
-color frame "gray" "black" | |
-color from_myself "brightmagenta" "default" | |
-color group "default" "default" | |
-color grouplens_display "gray" "default" | |
-color header_number "gray" "default" | |
-color header_name "gray" "default" | |
-color headers "gray" "default" | |
-color neg_score "red" "default" | |
-color pos_score "brightblue" "default" | |
-color high_score "yellow" "default" | |
-color italicstext "white" "default" | |
-color menu "white" "black" | |
-color menu_press "white" "gray" | |
-color message "default" "default" | |
-color normal "lightgray" "default" | |
-color pgpsignature "cyan" "default" | |
-color quotes "gray" "default" | |
-color quotes1 "gray" "default" | |
-color quotes2 "gray" "default" | |
-color quotes3 "gray" "default" | |
-color quotes4 "gray" "default" | |
-color quotes5 "gray" "default" | |
-color quotes6 "gray" "default" | |
-color quotes7 "gray" "default" | |
-color response_char "blue" "default" | |
-color signature "gray" "default" | |
-color selection "white" "gray" | |
-color status "white" "black" | |
-color subject "default" "default" | |
-color thread_number "gray" "default" | |
-color tilde "gray" "default" | |
-color tree "gray" "default" | |
-color underlinetext "white" "default" "underline" | |
-color url "brightblue" "default" | |
-color verbatim "white" "default" | |
- | |
-% These attributes are for terminals that cannot display color: | |
-mono article "none" | |
-mono author "none" | |
-mono boldtext "bold" | |
-mono cursor "bold" "reverse" | |
-mono date "none" | |
-mono description "none" | |
-mono error "blink" | |
-mono frame "reverse" | |
-mono from_myself "bold" | |
-mono group "bold" | |
-mono grouplens_display "none" | |
-mono header_name "bold" | |
-mono header_number "none" | |
-mono headers "none" | |
-mono high_score "bold" | |
-mono italicstext "bold" | |
-mono menu "reverse" | |
-mono menu_press "none" | |
-mono neg_score "none" | |
-mono normal "none" | |
-mono pgpsignature "none" | |
-mono pos_score "reverse" | |
-mono quotes "none" | |
-mono quotes1 "none" | |
-mono quotes2 "none" | |
-mono quotes3 "none" | |
-mono quotes4 "none" | |
-mono quotes5 "none" | |
-mono quotes6 "none" | |
-mono quotes7 "none" | |
-mono response_char "bold" | |
-mono selection "bold" | |
-mono signature "none" | |
-mono status "reverse" | |
-mono subject "none" | |
-mono thread_number "bold" | |
-mono tilde "bold" | |
-mono tree "none" | |
-mono underlinetext "underline" | |
-mono url "bold" | |
-mono verbatim "none" | |
- | |
-% vim:set ft=slrnrc: | |
diff --git a/slrn/config b/slrn/config | |
@@ -1,45 +0,0 @@ | |
-% user | |
-set username "jay" | |
-set hostname "jay.invalid" | |
-set realname "jay" | |
-set generate_message_id 0 | |
- | |
-% apps | |
-set editor_command "vim '+set tw=72' +%d '%s'" | |
-set Xbrowser "firefox '%s' &" | |
- | |
-% attrib | |
-set followup_string "On %D, %r <%f> wrote:" | |
-set reply_string "In %n, you wrote:" | |
- | |
-% paths | |
-set scorefile ".config/slrn/score" | |
-set spool_inn_root "/home/jay/.config/slrn/" | |
-set spool_root "/home/jay/.config/slrn/news" | |
-set spool_nov_root "/home/jay/.config/slrn/news" | |
-set read_active 1 | |
-set use_slrnpull 1 | |
-set server_object "spool" | |
- | |
-% mime | |
-charset display utf8 | |
-charset outgoing utf8 | |
- | |
-% display | |
-set confirm_actions 0 | |
-set sorting_method 9 | |
-set uncollapse_threads 1 | |
-set top_status_line " %n" | |
-set group_status_line "%D %-20g -- %L (%P)" | |
-set header_status_line "%p [%r/%t] %-20g -- %L (%P)" | |
-set art_status_line "%p %s %-20g -- %L (%P)" | |
-set overview_date_format "%d %b %Y %H:%M" | |
- | |
-visible_headers "Date:,From:,Newsgroups:,Subject:" | |
-header_display_format 0 "%F%B %21r %T%s %-26g %D %-5c" | |
- | |
-% keybinds | |
-setkey group "set_prefix_argument(4); () = select_group();" " | |
-setkey article create_score "K" | |
- | |
-include ".config/slrn/colors" | |
diff --git a/slrn/score b/slrn/score | |
@@ -1,26 +0,0 @@ | |
-% : Logical AND ie all tests must be passed (Conjunction) | |
-% :: Logical OR ie any of the tests are passed (Disjunction) | |
-% ~ Logical NOT ie an exception from the score rule (Negation) | |
-% = Stop score processing and award the score if the test is passed | |
-% * Wild card character | |
- | |
-[*] | |
- Score:: -9999 | |
- % | |
- % Kill all articles which are uppercase and contain $ sign | |
- Subject: \$ | |
- ~Subject: \c[a-z] | |
- % | |
- % Google groups are a source of, basically, all spam | |
- Message-ID: googlegroups | |
- % | |
- % Known spam remailer | |
- From: nobody@dizum\.com | |
- % | |
- % Prolific spammer | |
- From: doctor@doctor\.nl2k\.ab\.ca | |
- | |
-[eternal-september.*] | |
- Score:: -9999 | |
- From: Tigerbrother | |
- From: Dragonbrother | |
diff --git a/slrn/slrnpull.conf b/slrn/slrnpull.conf | |
@@ -1,50 +0,0 @@ | |
-default 0 0 0 | |
- | |
-eternal-september.info | |
-eternal-september.newusers | |
-eternal-september.talk | |
-eternal-september.support | |
-eternal-september.config | |
-eternal-september.test | |
-eternal-september.grouprequests | |
-eternal-september.where.are.all.the.newsgroups | |
-alt.2600 | |
-alt.2600.hackers | |
-alt.2600.hope | |
-alt.anonymous | |
-alt.culture.usenet | |
-alt.fan.countries.scotland | |
-alt.fan.usenet | |
-alt.gopher | |
-alt.linux | |
-alt.ph.uk | |
-alt.usenet.newbies | |
-comp.infosystems.gopher | |
-comp.mail.mutt | |
-comp.os.linux.announce | |
-comp.os.misc | |
-free.answers | |
-mailing.unix.mutt-users | |
-mailing.unix.slrn | |
-news.groups | |
-news.groups.proposals | |
-news.groups.questions | |
-news.software.nntp | |
-rec.radio.shortwave | |
-soc.culture.scottish | |
-uk.local.scot-highlands | |
-uk.radio.amateur | |
-uk.telecom | |
-comp.infosystems.gemini | |
-alt.comp.software.tools | |
-alt.conspiracy | |
-alt.cyberpunk | |
-alt.folklore.computers | |
-alt.hacker | |
-alt.hacking | |
-alt.os.linux.slackware | |
-alt.os.linux | |
-alt.privacy | |
-alt.radio.talk | |
-news.admin.peering | |
-alt.cypherpunks | |
diff --git a/suckless/dmenu/Makefile b/suckless/dmenu/Makefile | |
@@ -0,0 +1,39 @@ | |
+REPOSITORY = http://git.suckless.org/dmenu | |
+SRC_DIR = src | |
+PINNED_REVISION = HEAD | |
+PATCH_DIR = patches | |
+ | |
+all: $(SRC_DIR) | |
+ | |
+clean: reset | |
+ @if test -d $(SRC_DIR); then \ | |
+ $(MAKE) -C "${SRC_DIR}" -s clean; \ | |
+ git -C "${SRC_DIR}" clean -f; \ | |
+ fi | |
+ | |
+$(SRC_DIR): clone reset | |
+ @cp config.h $@ | |
+ $(MAKE) -C "${SRC_DIR}" -s | |
+ | |
+patch: $(PATCH_DIR)/* | |
+ @for file in $^ ; do \ | |
+ patch -d "${SRC_DIR}" < $${file}; \ | |
+ done | |
+reset: | |
+ @if [ -n "$(strip $(PINNED_REVISION))" ]; then \ | |
+ git -C "${SRC_DIR}" reset --hard $(PINNED_REVISION); \ | |
+ fi | |
+ | |
+clone: | |
+ @if ! test -d $(SRC_DIR); then \ | |
+ git clone $(REPOSITORY) $(SRC_DIR); \ | |
+ fi | |
+ | |
+update: clean | |
+ @git -C "${SRC_DIR}" pull | |
+ | |
+install: | |
+ $(MAKE) -C "${SRC_DIR}" -s install | |
+ | |
+ | |
+.PHONY: all clean update install reset clone | |
diff --git a/suckless/dmenu/config.h b/suckless/dmenu/config.h | |
@@ -0,0 +1,16 @@ | |
+static int topbar = 1; | |
+static const char *fonts[] = { | |
+ "Hack:pixelsize=14" | |
+}; | |
+static int centered = 1; | |
+static const char *prompt = "run »"; | |
+static const char *colors[SchemeLast][2] = { | |
+ [SchemeNorm] = { "#ffd7af", "#222222" }, | |
+ [SchemeSel] = { "#eeeeee", "#008000" }, | |
+ [SchemeOut] = { "#000000", "#00ffff" }, | |
+}; | |
+ | |
+static unsigned int lines = 0; | |
+static const char worddelimiters[] = " "; | |
+static int min_width = 800; | |
+static unsigned int border_width = 3; | |
diff --git a/suckless/dmenu/patches/01-dmenu-border-4.9.diff b/suckless/dmenu/p… | |
@@ -0,0 +1,36 @@ | |
+diff --git a/config.def.h b/config.def.h | |
+index 1edb647..dd3eb31 100644 | |
+--- a/config.def.h | |
++++ b/config.def.h | |
+@@ -21,3 +21,6 @@ static unsigned int lines = 0; | |
+ * for example: " /?\"&[]" | |
+ */ | |
+ static const char worddelimiters[] = " "; | |
++ | |
++/* Size of the window border */ | |
++static unsigned int border_width = 0; | |
+diff --git a/dmenu.c b/dmenu.c | |
+index 27b7a30..7c130fc 100644 | |
+--- a/dmenu.c | |
++++ b/dmenu.c | |
+@@ -684,9 +684,11 @@ setup(void) | |
+ swa.override_redirect = True; | |
+ swa.background_pixel = scheme[SchemeNorm][ColBg].pixel; | |
+ swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask; | |
+- win = XCreateWindow(dpy, root, x, y, mw, mh, 0, | |
++ win = XCreateWindow(dpy, root, x, y, mw, mh, border_width, | |
+ CopyFromParent, CopyFromParent, CopyFromParent, | |
+ CWOverrideRedirect | CWBackPixel | CWEventMask, &… | |
++ if (border_width) | |
++ XSetWindowBorder(dpy, win, scheme[SchemeSel][ColBg].pixel); | |
+ XSetClassHint(dpy, win, &ch); | |
+ | |
+ | |
+@@ -757,6 +759,8 @@ main(int argc, char *argv[]) | |
+ colors[SchemeSel][ColFg] = argv[++i]; | |
+ else if (!strcmp(argv[i], "-w")) /* embedding window id */ | |
+ embed = argv[++i]; | |
++ else if (!strcmp(argv[i], "-bw")) | |
++ border_width = atoi(argv[++i]); /* border width */ | |
+ else | |
+ usage(); | |
diff --git a/suckless/dmenu/patches/02-dmenu-center-20200111-8cd37e1.diff b/suc… | |
@@ -0,0 +1,120 @@ | |
+From 8cd37e1ab9e7cb025224aeb3543f1a5be8bceb93 Mon Sep 17 00:00:00 2001 | |
+From: Nihal Jere <[email protected]> | |
+Date: Sat, 11 Jan 2020 21:16:08 -0600 | |
+Subject: [PATCH] center patch now has adjustable minimum width | |
+ | |
+--- | |
+ config.def.h | 2 ++ | |
+ dmenu.1 | 3 +++ | |
+ dmenu.c | 39 ++++++++++++++++++++++++++++++++------- | |
+ 3 files changed, 37 insertions(+), 7 deletions(-) | |
+ | |
+diff --git a/config.def.h b/config.def.h | |
+index 1edb647..88ef264 100644 | |
+--- a/config.def.h | |
++++ b/config.def.h | |
+@@ -2,6 +2,8 @@ | |
+ /* Default settings; can be overriden by command line. */ | |
+ | |
+ static int topbar = 1; /* -b option; if 0, dmenu appear… | |
++static int centered = 0; /* -c option; centers dmenu on sc… | |
++static int min_width = 500; /* minimum width when centered… | |
+ /* -fn option overrides fonts[0]; default X11 font or font set */ | |
+ static const char *fonts[] = { | |
+ "monospace:size=10" | |
+diff --git a/dmenu.1 b/dmenu.1 | |
+index 323f93c..c036baa 100644 | |
+--- a/dmenu.1 | |
++++ b/dmenu.1 | |
+@@ -40,6 +40,9 @@ which lists programs in the user's $PATH and runs the result… | |
+ .B \-b | |
+ dmenu appears at the bottom of the screen. | |
+ .TP | |
++.B \-c | |
++dmenu appears centered on the screen. | |
++.TP | |
+ .B \-f | |
+ dmenu grabs the keyboard before reading stdin if not reading from a tty. This | |
+ is faster, but will lock up X until stdin reaches end\-of\-file. | |
+diff --git a/dmenu.c b/dmenu.c | |
+index 65f25ce..041c7f8 100644 | |
+--- a/dmenu.c | |
++++ b/dmenu.c | |
+@@ -89,6 +89,15 @@ calcoffsets(void) | |
+ break; | |
+ } | |
+ | |
++static int | |
++max_textw(void) | |
++{ | |
++ int len = 0; | |
++ for (struct item *item = items; item && item->text; item++) | |
++ len = MAX(TEXTW(item->text), len); | |
++ return len; | |
++} | |
++ | |
+ static void | |
+ cleanup(void) | |
+ { | |
+@@ -611,6 +620,7 @@ setup(void) | |
+ bh = drw->fonts->h + 2; | |
+ lines = MAX(lines, 0); | |
+ mh = (lines + 1) * bh; | |
++ promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0; | |
+ #ifdef XINERAMA | |
+ i = 0; | |
+ if (parentwin == root && (info = XineramaQueryScreens(dpy, &n))) { | |
+@@ -637,9 +647,16 @@ setup(void) | |
+ if (INTERSECT(x, y, 1, 1, info[i])) | |
+ break; | |
+ | |
+- x = info[i].x_org; | |
+- y = info[i].y_org + (topbar ? 0 : info[i].height - mh); | |
+- mw = info[i].width; | |
++ if (centered) { | |
++ mw = MIN(MAX(max_textw() + promptw, min_width), info[… | |
++ x = info[i].x_org + ((info[i].width - mw) / 2); | |
++ y = info[i].y_org + ((info[i].height - mh) / 2); | |
++ } else { | |
++ x = info[i].x_org; | |
++ y = info[i].y_org + (topbar ? 0 : info[i].height - mh… | |
++ mw = info[i].width; | |
++ } | |
++ | |
+ XFree(info); | |
+ } else | |
+ #endif | |
+@@ -647,11 +664,17 @@ setup(void) | |
+ if (!XGetWindowAttributes(dpy, parentwin, &wa)) | |
+ die("could not get embedding window attributes: 0x%lx… | |
+ parentwin); | |
+- x = 0; | |
+- y = topbar ? 0 : wa.height - mh; | |
+- mw = wa.width; | |
++ | |
++ if (centered) { | |
++ mw = MIN(MAX(max_textw() + promptw, min_width), wa.wi… | |
++ x = (wa.width - mw) / 2; | |
++ y = (wa.height - mh) / 2; | |
++ } else { | |
++ x = 0; | |
++ y = topbar ? 0 : wa.height - mh; | |
++ mw = wa.width; | |
++ } | |
+ } | |
+- promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0; | |
+ inputw = MIN(inputw, mw/3); | |
+ match(); | |
+ | |
+@@ -709,6 +732,8 @@ main(int argc, char *argv[]) | |
+ topbar = 0; | |
+ else if (!strcmp(argv[i], "-f")) /* grabs keyboard before r… | |
+ fast = 1; | |
++ else if (!strcmp(argv[i], "-c")) /* centers dmenu on screen… | |
++ centered = 1; | |
+ else if (!strcmp(argv[i], "-i")) { /* case-insensitive item m… | |
+ fstrncmp = strncasecmp; | |
+ fstrstr = cistrstr; | |
+-- | |
+2.24.1 | |
+ | |
diff --git a/suckless/dwm/Makefile b/suckless/dwm/Makefile | |
@@ -0,0 +1,35 @@ | |
+REPOSITORY = http://git.suckless.org/dwm | |
+SRC_DIR = src | |
+PINNED_REVISION = HEAD | |
+ | |
+all: $(SRC_DIR) | |
+ | |
+clean: reset | |
+ @if test -d $(SRC_DIR); then \ | |
+ cd $(SRC_DIR); \ | |
+ $(MAKE) -s clean; \ | |
+ git clean -f; \ | |
+ fi | |
+ | |
+$(SRC_DIR): clone reset | |
+ @cp config.h $@ | |
+ @cd $@ && $(MAKE) -s | |
+ | |
+reset: | |
+ @if [ -n "$(strip $(PINNED_REVISION))" ]; then \ | |
+ cd $(SRC_DIR) && git reset --hard $(PINNED_REVISION); \ | |
+ fi | |
+ | |
+clone: | |
+ @if ! test -d $(SRC_DIR); then \ | |
+ git clone $(REPOSITORY) $(SRC_DIR); \ | |
+ fi | |
+ | |
+update: clean | |
+ @cd $(SRC_DIR) && git pull | |
+ | |
+install: | |
+ $(MAKE) -C "${SRC_DIR}" -s install | |
+ | |
+ | |
+.PHONY: all clean update install reset clone | |
diff --git a/suckless/dwm/config.h b/suckless/dwm/config.h | |
@@ -0,0 +1,195 @@ | |
+/* See LICENSE file for copyright and license details. */ | |
+ | |
+/* appearance */ | |
+static const unsigned int borderpx = 2; | |
+static const unsigned int snap = 32; | |
+static const int lockfullscreen = 1; | |
+static const int showbar = 1; | |
+static const int topbar = 1; | |
+static const char *fonts[] = { "Hack:size=10" }; | |
+static const char dmenufont[] = "Hack:size=10"; | |
+static const char col_gray1[] = "#222222"; | |
+static const char col_gray2[] = "#444444"; | |
+static const char col_gray3[] = "#bbbbbb"; | |
+static const char col_gray4[] = "#eeeeee"; | |
+static const char col_cyan[] = "#222222"; | |
+static const char *colors[][3] = { | |
+ /* fg bg border */ | |
+ [SchemeNorm] = { col_gray3, col_gray1, col_cyan }, | |
+ [SchemeSel] = { col_gray4, col_cyan, col_gray2 }, | |
+}; | |
+ | |
+ | |
+/* custom functions */ | |
+static void togglefullscreen(const Arg *arg); | |
+static void bstack(Monitor *m); | |
+static void centeredfloatingmaster(Monitor *m); | |
+ | |
+/* custom defines for mouse buttons */ | |
+/* only 1-5 are defined in X11/X.h */ | |
+#define Button8 8 | |
+#define Button9 9 | |
+ | |
+/* tagging */ | |
+static const char *tags[] = { "1", "2", "3", "4", "5" }; | |
+ | |
+static Rule rules[] = { | |
+ /* class instance title tags mask isfloating monit… | |
+ { NULL, NULL, NULL, 0, False, -1 }, | |
+}; | |
+ | |
+/* layout(s) */ | |
+static const float mfact = 0.65; | |
+static const int nmaster = 1; | |
+static const int resizehints = 0; | |
+ | |
+static const Layout layouts[] = { | |
+ { ">M>", centeredfloatingmaster }, | |
+ { "[]=", tile }, | |
+ { "TTT", bstack }, | |
+ { "><>", NULL }, | |
+}; | |
+ | |
+#define MODKEY Mod1Mask | |
+#define TAGKEYS(KEY,TAG) \ | |
+{ MODKEY, KEY, view, {.ui = 1 << TAG} }, \ | |
+{ MODKEY|ControlMask, KEY, toggleview, {.ui = 1 << TAG} }, \ | |
+{ MODKEY|ShiftMask, KEY, tag, {.ui = 1 << TAG} }, \ | |
+{ MODKEY|ControlMask|ShiftMask, KEY, toggletag, {.ui = 1 << TAG} }, | |
+ | |
+#define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } } | |
+ | |
+/* commands */ | |
+static char dmenumon[2] = "0"; | |
+static const char *dmenucmd[] = { "dmenu_run", NULL }; | |
+static const char *termcmd[] = { "alacritty", NULL }; | |
+static const char *webcmd[] = { "firefox", NULL }; | |
+static const char *ytcmd[] = { "ytfzf", "-D", NULL }; | |
+static const char *gamecmd[] = { "/home/jay/bin/game_select.sh", NULL }; | |
+static const char *volup[] = { "pamixer", "-i", "5", NULL }; | |
+static const char *voldown[] = { "pamixer", "-d", "5", NULL }; | |
+ | |
+ | |
+static Key keys[] = { | |
+ /* modifier key function argument */ | |
+ { MODKEY, XK_p, spawn, {.v = dmenu… | |
+ { MODKEY, XK_space, spawn, {.v = termc… | |
+ { MODKEY, XK_f, spawn, {.v = webcm… | |
+ { MODKEY, XK_y, spawn, {.v = ytcmd… | |
+ { MODKEY, XK_g, spawn, {.v = gamec… | |
+ { MODKEY, XK_u, spawn, {.v = volup… | |
+ { MODKEY, XK_d, spawn, {.v = voldo… | |
+ { MODKEY, XK_j, focusstack, {.i = +1 } … | |
+ { MODKEY, XK_k, focusstack, {.i = -1 } … | |
+ { MODKEY, XK_h, setmfact, {.f = -0.05… | |
+ { MODKEY, XK_l, setmfact, {.f = +0.05… | |
+ { MODKEY, XK_Return, zoom, {0} }, | |
+ { MODKEY, XK_Tab, view, {0} }, | |
+ { MODKEY, XK_c, killclient, {0} }, | |
+ { MODKEY, XK_m, togglefullscreen, {0} }, | |
+ { MODKEY, XK_period, focusmon, {.i = +1 } … | |
+ { MODKEY, XK_comma, tagmon, {.i = +1 }… | |
+ { MODKEY, XK_b, togglebar, {0} }, | |
+ { MODKEY, XK_x, setlayout, {.v = &layo… | |
+ { MODKEY|ShiftMask, XK_x, setlayout, {.v = &layo… | |
+ TAGKEYS( XK_1, 0) | |
+ TAGKEYS( XK_2, 1) | |
+ TAGKEYS( XK_3, 2) | |
+ TAGKEYS( XK_4, 3) | |
+ TAGKEYS( XK_5, 4) | |
+ { MODKEY|ShiftMask, XK_q, quit, {0} }, | |
+}; | |
+ | |
+/* button definitions */ | |
+static Button buttons[] = { | |
+ { ClkRootWin, 0, Button8, spawn, … | |
+ { ClkRootWin, 0, Button9, spawn, … | |
+ }; | |
+ | |
+void | |
+togglefullscreen(const Arg *arg) | |
+{ | |
+ if (!selmon->sel) | |
+ return; | |
+ setfullscreen(selmon->sel, !selmon->sel->isfullscreen); | |
+} | |
+ | |
+static void | |
+bstack(Monitor *m) { | |
+ int w, h, mh, mx, tx, ty, tw; | |
+ unsigned int i, n; | |
+ Client *c; | |
+ | |
+ for (n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), n++); | |
+ if (n == 0) | |
+ return; | |
+ if (n > m->nmaster) { | |
+ mh = m->nmaster ? m->mfact * m->wh : 0; | |
+ tw = m->ww / (n - m->nmaster); | |
+ ty = m->wy + mh; | |
+ } else { | |
+ mh = m->wh; | |
+ tw = m->ww; | |
+ ty = m->wy; | |
+ } | |
+ for (i = mx = 0, tx = m->wx, c = nexttiled(m->clients); c; c = nexttil… | |
+ if (i < m->nmaster) { | |
+ w = (m->ww - mx) / (MIN(n, m->nmaster) - i); | |
+ resize(c, m->wx + mx, m->wy, w - (2 * c->bw), mh - (2 … | |
+ mx += WIDTH(c); | |
+ } else { | |
+ h = m->wh - mh; | |
+ resize(c, tx, ty, tw - (2 * c->bw), h - (2 * c->bw), 0… | |
+ if (tw != m->ww) | |
+ tx += WIDTH(c); | |
+ } | |
+ } | |
+} | |
+ | |
+void | |
+centeredfloatingmaster(Monitor *m) | |
+{ | |
+ unsigned int i, n, w, mh, mw, mx, mxo, my, myo, tx; | |
+ Client *c; | |
+ | |
+ /* count number of clients in the selected monitor */ | |
+ for (n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), n++); | |
+ if (n == 0) | |
+ return; | |
+ | |
+ /* initialize nmaster area */ | |
+ if (n > m->nmaster) { | |
+ /* go mfact box in the center if more than nmaster clients */ | |
+ if (m->ww > m->wh) { | |
+ mw = m->nmaster ? m->ww * m->mfact : 0; | |
+ mh = m->nmaster ? m->wh * 0.9 : 0; | |
+ } else { | |
+ mh = m->nmaster ? m->wh * m->mfact : 0; | |
+ mw = m->nmaster ? m->ww * 0.9 : 0; | |
+ } | |
+ mx = mxo = (m->ww - mw) / 2; | |
+ my = myo = (m->wh - mh) / 2; | |
+ } else { | |
+ /* go fullscreen if all clients are in the master area */ | |
+ mh = m->wh; | |
+ mw = m->ww; | |
+ mx = mxo = 0; | |
+ my = myo = 0; | |
+ } | |
+ | |
+ for(i = tx = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), … | |
+ if (i < m->nmaster) { | |
+ /* nmaster clients are stacked horizontally, in the center | |
+ * of the screen */ | |
+ w = (mw + mxo - mx) / (MIN(n, m->nmaster) - i); | |
+ resize(c, m->wx + mx, m->wy + my, w - (2*c->bw), | |
+ mh - (2*c->bw), 0); | |
+ mx += WIDTH(c); | |
+ } else { | |
+ /* stack clients are stacked horizontally */ | |
+ w = (m->ww - tx) / (n - i); | |
+ resize(c, m->wx + tx, m->wy, w - (2*c->bw), | |
+ m->wh - (2*c->bw), 0); | |
+ tx += WIDTH(c); | |
+ } | |
+} | |
diff --git a/suckless/herbe/Makefile b/suckless/herbe/Makefile | |
@@ -0,0 +1,40 @@ | |
+REPOSITORY = https://github.com/dudik/herbe.git | |
+SRC_DIR = src | |
+PINNED_REVISION = HEAD | |
+PATCH_DIR = patches | |
+ | |
+all: $(SRC_DIR) | |
+ | |
+clean: reset | |
+ @if test -d $(SRC_DIR); then \ | |
+ $(MAKE) -C "${SRC_DIR}" -s clean; \ | |
+ git -C "${SRC_DIR}" clean -f; \ | |
+ fi | |
+ | |
+$(SRC_DIR): clone reset | |
+ @cp config.h $@ | |
+ $(MAKE) -C "${SRC_DIR}" -s | |
+ | |
+reset: | |
+ @if [ -n "$(strip $(PINNED_REVISION))" ]; then \ | |
+ git -C "${SRC_DIR}" reset --hard $(PINNED_REVISION); \ | |
+ fi | |
+ | |
+patch: $(PATCH_DIR)/* | |
+ @for file in $^ ; do \ | |
+ patch -d "${SRC_DIR}" < $${file}; \ | |
+ done | |
+ | |
+clone: | |
+ @if ! test -d $(SRC_DIR); then \ | |
+ git clone $(REPOSITORY) $(SRC_DIR); \ | |
+ fi | |
+ | |
+update: clean | |
+ @git -C "${SRC_DIR}" pull | |
+ | |
+install: | |
+ $(MAKE) -C "${SRC_DIR}" -s install | |
+ | |
+ | |
+.PHONY: all clean update install reset clone | |
diff --git a/suckless/herbe/config.h b/suckless/herbe/config.h | |
@@ -0,0 +1,19 @@ | |
+static const char *background_color = "#222222"; | |
+static const char *border_color = "#008000"; | |
+static const char *font_color = "#ffd7af"; | |
+static const char *font_pattern = "Hack:pixelsize=12"; | |
+static unsigned line_spacing = 5; | |
+static unsigned int padding = 12; | |
+ | |
+static unsigned int width = 300; | |
+static unsigned int border_size = 3; | |
+static unsigned int pos_x = 30; | |
+static unsigned int pos_y = 60; | |
+ | |
+enum corners { TOP_LEFT, TOP_RIGHT, BOTTOM_LEFT, BOTTOM_RIGHT }; | |
+enum corners corner = TOP_RIGHT; | |
+ | |
+static unsigned int duration = 5; /* in seconds */ | |
+ | |
+#define DISMISS_BUTTON Button1 | |
+#define ACTION_BUTTON Button3 | |
diff --git a/sway/config b/sway/config | |
@@ -1,89 +0,0 @@ | |
-set $mod Mod1 | |
- | |
-# colour theme | |
-set $colour #013220 | |
- | |
-set $left h | |
-set $down j | |
-set $up k | |
-set $right l | |
- | |
-# apps | |
-set $term footclient -d none | |
-set $browser qutebrowser | |
-set $steam flatpak run --user com.valvesoftware.Steam | |
-set $menu bemenu-run -p '> ' --tb '$colour' --tf '#ffffff' --hf '#444444' | |
-set $vol pamixer | |
- | |
-# autostart | |
-exec foot --server | |
-exec wl-paste -t text --watch clipman store --no-persist | |
-exec mpd | |
-exec /usr/libexec/pipewire-launcher | |
- | |
-# apperance | |
-default_border none | |
-default_floating_border none | |
-workspace_layout tabbed | |
-font pango: Hack:style=Regular 2 | |
- | |
-# misc | |
-xwayland enable | |
- | |
-# Keyboard layout | |
-input * { | |
- xkb_layout "gb" | |
- xkb_variant "extd" | |
-} | |
- | |
-# monitors | |
-output HDMI-A-1 pos 0 0 res 1920x1080 | |
-output DP-1 pos 1920 0 res 1920x1080 | |
-focus output DP-1 | |
- | |
-# workspaces | |
-workspace 1 HDMI-A-1 | |
-workspace 2 HDMI-A-1 | |
-workspace 3 DP-1 | |
-workspace 4 DP-1 | |
- | |
-# Keybinds | |
-bindsym $mod+Space exec $term | |
-bindsym $mod+p exec $menu | |
-bindsym $mod+f exec $browser | |
-bindsym $mod+s exec $steam | |
-bindsym $mod+u exec $vol -i 5 | |
-bindsym $mod+d exec $vol -d 5 | |
- | |
-bindsym $mod+c kill | |
-bindsym $mod+Shift+c reload | |
-bindsym $mod+Shift+q exec swaymsg exit | |
- | |
-# Move your focus around | |
-bindsym $mod+$left focus left | |
-bindsym $mod+$down focus down | |
-bindsym $mod+$up focus up | |
-bindsym $mod+$right focus right | |
- | |
-# Or use $mod+[up|down|left|right] | |
-bindsym $mod+Left focus left | |
-bindsym $mod+Down focus down | |
-bindsym $mod+Up focus up | |
-bindsym $mod+Right focus right | |
- | |
-# Switch to workspace | |
-bindsym $mod+1 workspace number 1 | |
-bindsym $mod+2 workspace number 2 | |
-bindsym $mod+3 workspace number 3 | |
-bindsym $mod+4 workspace number 4 | |
- | |
-bindsym $mod+Shift+1 move container to workspace number 1 | |
-bindsym $mod+Shift+2 move container to workspace number 2 | |
-bindsym $mod+Shift+3 move container to workspace number 3 | |
-bindsym $mod+Shift+4 move container to workspace number 4 | |
- | |
-bindsym $mod+e layout toggle split | |
-bindsym $mod+m fullscreen | |
-bindsym $mod+w layout tabbed | |
- | |
-client.focused $colour $colour $colour |