Update 2023-11-23 13:23 OpenBSD/amd64-x13

This commit is contained in:
c0dev0id 2023-11-23 13:23:56 +01:00
parent d4c83cd571
commit 51276df8be
19 changed files with 216 additions and 120 deletions

View File

@ -176,3 +176,110 @@ XConsole*y: 870
XConsole*width: 620
XConsole*height: 160
XFontSel.printOnQuit: True
XFontSel.pattern: -*-*-medium-r-normal-*-*-*-*-*-*-*-iso10646-1
XFontSel*Font: lucidasanstypewriter-14
! -- XLOCK -- !
XLock.mode: blank
XLock.erasedelay: 4000
XLock.font: -b&h-lucida-medium-r-normal-sans-24-*-*-*-*-*-iso8859-1
!XLock.font: -*-times-*-*-*-*-18-*-*-*-*-*-*-*
!XLock.background: White
!XLock.foreground: Black
XLock.background: Black
XLock.foreground: White
!XLock.foreground: AntiqueWhite
XLock.nolock: off
XLock.inwindow: off
XLock.inroot: off
XLock.remote: off
XLock.mono: off
XLock.allowaccess: off
XLock.vtlock: off
XLock.allowroot: off
XLock.description: on
XLock.echokeys: off
XLock.enablesaver: on
XLock.resetsaver: on
XLock.grabmouse: on
XLock.install: on
XLock.mousemotion: off
XLock.sound: off
XLock.timeelapsed: off
XLock.usefirst: on
XLock.verbose: off
XLock.nice: 10
XLock.lockdelay: 0
XLock.unlockdelay: 0
XLock.timeout: 30
XLock.echokey: ?
!XLock.geometry: 64x64
!XLock.icongeometry: 4x4
XLock.icongeometry: 64x64
!XLock.icongeometry: 256x256
! For sound
XLock.locksound: /usr/lib/X11/xlock/sounds/complete.au
XLock.infosound: /usr/lib/X11/xlock/sounds/identify-please.au
XLock.validsound: /usr/lib/X11/xlock/sounds/thank-you.au
XLock.invalidsound: /usr/lib/X11/xlock/sounds/not-programmed.au
!XLock.locksound: complete.au
!XLock.infosound: identify-please.au
!XLock.validsound: thank-you.au
!XLock.invalidsound: not-programmed.au
! For bouboule, pyro, star, & worm modes
XLock.use3d: off
XLock.delta3d: 1.5
XLock.right3d: Blue
XLock.left3d: Red
XLock.both3d: Magenta
! For marquee & nose modes
!XLock.program: fortune -o
XLock.program: fortune -s
!XLock.program: fortune
!XLock.program: /usr/games/fortune -o
!XLock.program: /usr/games/fortune -s
!XLock.program: /usr/games/fortune
!XLock.program: finger
!XLock.messagesfile: fortune.dat
!XLock.messagefile: /etc/motd
!XLock.message: "Go away, no one is here"
!XLock.messagefont: -b&h-lucida-medium-r-normal-sans-24-*-*-*-*-*-iso8859-1
!XLock.messagefont: -*-times-*-*-*-*-18-*-*-*-*-*-*-*
! For modes with images
XLock.*.bitmap: bitmaps/m-xlock.xbm
XLock.*.bitmap: pixmaps/m-xlock.xpm
XLock.*.bitmap: /usr/lib/X11/xlock/bitmaps
! For mailbox check application
!XLock.mailCmd: /usr/ucb/mail -e
!XLock.mailCmd: /usr/bin/mail -e
!XLock.mailCmd: /usr/local/bin/chkmbox
!XLock.mailIcon:
!XLock.nomailIcon:
! 0 defaults to maximum defined value
XLock.logoutAuto: 0
! 0 defaults to maximum defined value
XLock.logoutButton: 0
XLock.username: Name:
XLock.password: Password:
XLock.info: Enter password to unlock; select icon to lock.
XLock.validate: Validating login...
XLock.invalid: Invalid login.
XLock.invalidCapsLock: Invalid login, Caps Lock on.
XLock.logoutButtonLabel: Click here to logout
XLock.logoutButtonHelp: \
You may log out this session if no terminals are available.\n\
WARNING: This will crash any open applications that the user\n\
has running. You should try to contact the user if possible\n\
before logging them out.
XLock.logoutFailedString: \
Logout attempt FAILED.\n\
Current user could not be automatically logged out.

View File

@ -2,9 +2,11 @@
# FONTS
#
SFONT="Cozette:pixelsize=13"
BFONT="CozetteHiDpi:pixelsize=26"
HFONT="LuxiMono-24"
SFONT="-slavfox-cozettehidpi-medium-r-normal--26-240-75-75-m-120-iso10646-1"
BFONT="-slavfox-cozette-medium-r-normal--13-120-75-75-m-60-iso10646-1"
HFONT="FuraCodeNerdFontMono:pixelsize=28"
DFONT="CozetteHidpi:pixelsize=26"
# TERMINALS
#
@ -15,22 +17,22 @@ HTERM="st -f ${HFONT}"
MICROFONT="-uw-ttyp0-medium-r-normal--13-150-75-75-c-80-iso10646-1"
MICROTERM="st -f ${MICROFONT}"
# DMENU
#
DFONT="Cozette:pixelsize=13"
# NOTION ORANGE
DMENUOPTS="-fn '$DFONT' -nb #181818 -nf #404040 -sf #FFA600 -sb #222222 -l 18 -i -f"
#DMENUOPTS="-fn '$DFONT' -nb #181818 -nf #707070 -sf #FFA600 -sb #222222 -l 18 -i -f"
# BSPWM
# DMENUOPTS="-fn '$DFONT' -nb #222222 -nf #707070 -sf #CCCCCC -sb #222222 -i -f"
#DMENUOPTS="-fn '$DFONT' -nb #222222 -nf #707070 -sf #CCCCCC -sb #222222 -i -f"
# SPECTRWM GREY
# DMENUOPTS="-fn $DFONT -nb #181818 -nf #999999 -sf #CCCCCC -sb #181818 -i -f"
DMENUOPTS="-fn $DFONT -nb #181818 -nf #999999 -sf #CCCCCC -sb #181818 -i -f"
DMENU_CMD="dmenu $DMENUOPTS"
DMENURUN_CMD="dmenu_run $DMENUOPTS"
notify_func() { /usr/local/bin/notify-send " $(date +%H:%M) $@ "; }
NOTIFY_CMD=notify_func
# DEVELOPMENT
#
# [ ! -d "${HOME}/.dev" ] && mkdir "${HOME}/.dev"

View File

@ -21,28 +21,28 @@ amused show | cut -d'/' -f5-
SEL="$( showlist | $DMENU_CMD -p Playlist -l 30)"
amused_shuffle() {(
notify-send "shuffle started in background";
$NOTIFY_CMD "shuffle started in background";
amused show | sort -R | amused load;
notify-send "shuffle finished";
$NOTIFY_CMD "shuffle finished";
)&}
amused_sort() {(
notify-send "sorting started in background"
$NOTIFY_CMD "sorting started in background"
amused show | sort -u | amused load
notify-send "sorting finished"
$NOTIFY_CMD "sorting finished"
)&}
amused_load_tank() {(
notify-send "loading started in background"
$NOTIFY_CMD "loading started in background"
amused load < /home/sdk/.music.all.txt
notify-send "loading finished"
$NOTIFY_CMD "loading finished"
)&}
amused_load_local() {(
notify-send "loading started in background"
$NOTIFY_CMD "loading started in background"
find ~/MusicSelection -type f | amused load
notify-send "loading finished"
$NOTIFY_CMD "loading finished"
)&}
amused_cmd() {
amused "${@}"
notify-send "$(amused status | head -1 | cut -d'/' -f5-)"
$NOTIFY_CMD "$(amused status | head -1 | cut -d'/' -f5-)"
}
case "${SEL}" in

BIN
.bin/cbar

Binary file not shown.

View File

@ -21,7 +21,7 @@ touch "${HISTFILE}"
read_input() {
local S=$( { echo "paste_from_clipboard"; tail -r ${HISTFILE}; } \
| awk '!seen[$0]++' \
| ${DMENU_CMD} -p "bookmark>")
| ${DMENU_CMD} -p "Bookmarks")
case "${S}" in
paste_from_clipboard) S=$(xclip -o | head -n 1); ;;

View File

@ -9,15 +9,19 @@
# [ -z "$SEL" ] || texec $SEL
. $HOME/.bin/_config
MAILBOXES=$(cd ~/.emails && find Mailboxes/*/ \
-mindepth 1 -maxdepth 1 -type d \
-not -path "*/tmp*" \
-not -path "*/cur*" \
-not -path "*/new*")
# MAILBOXES=$(cd ~/.emails && find Mailboxes/*/ \
# -mindepth 1 -maxdepth 1 -type d \
# -not -path "*/tmp*" \
# -not -path "*/cur*" \
# -not -path "*/new*")
MAILBOXES="$(print "t1 login sdk $(pass Internet/mail.codevoid.de | head -1)\nt1 list \"\" \"*\"\nt1 logout" \
| openssl s_client -quiet -connect mail.codevoid.de:993 -crlf - 2>/dev/null \
| grep "^\* LIST" | awk '{ print $NF }' | sort | dos2unix)"
HOST="imaps://mail.codevoid.de"
SEL=$(echo "$MAILBOXES" | $DMENU_CMD -p Mutt)
SEL=$(echo "$MAILBOXES" | $DMENU_CMD -l 12 -p Mailbox)
[ -z "$SEL" ] || texec "mutt -F $HOME/.mutt/rc-account-private -f $HOST/$SEL"

View File

@ -4,7 +4,6 @@
MAN1=$(man -s1 -k .)
MAN2=$(man -s2 -k .)
MAN3=$(man -s3 -k .)
MAN3P=$(man -s3p -k .)
MAN4=$(man -s4 -k .)
MAN5=$(man -s5 -k .)
MAN6=$(man -s6 -k .)
@ -14,11 +13,11 @@ MAN9=$(man -s9 -k .)
SEL=$(echo "$MAN1" "$MAN2" "$MAN3" "$MAN4" \
"$MAN5" "$MAN6" "$MAN7" "$MAN8" \
"$MAN9" "$MAN3P" | $DMENU_CMD -p "Man")
"$MAN9" "$MAN3P" | $DMENU_CMD -l 10 -p "Man")
[ -z "$SEL" ] && exit 0
N=$(echo "$SEL" | cut -d"(" -f2 | cut -d")" -f1)
M=$(echo "$SEL" | cut -d"(" -f1 | cut -d"," -f1)
bterm -e man -s $N $M
sterm -e man -s $N $M

View File

@ -18,12 +18,12 @@ password_out=$(pass "$password" 2> /dev/null)
printf "%s" "$password_out" | head -1 | xclip -r
# extract additional information
password_info=$(printf "%s" "$password_out" | grep -Ei 'login|user')
url_info=$(printf "%s" "$password_out" | grep -Ei '^url' | awk -F"[ :]*" '{ $1=""; print $0 }' )
password_info=$(printf "%s" "$password_out" | grep -Ei -m 1 'login|user|email')
#url_info=$(printf "%s" "$password_out" | grep -Ei '^url' | awk -F"[ :]*" '{ $1=""; print $0 }' )
# show desktop notification
if [[ -n $password_info ]]; then
notify-send "$(printf '%s' "$password_info")"
$NOTIFY_CMD "$(printf '%s' "$password_info")"
else
notify-send "No username provided."
$NOTIFY_CMD "No username provided."
fi

View File

@ -4,7 +4,7 @@
. $HOME/.bin/_config
cd /usr/ports
DIR=$( ls -1d */* mystuff/*/* | egrep -v '^pobj|^distfiles|^log|^plist|^packages|CVS|Makefile|\.tgz$' | dmenu -p "DIR:" $DMENUOPTS -l 20);
DIR=$( ls -1d */* mystuff/*/* | egrep -v '^pobj|^distfiles|^log|^plist|^packages|CVS|Makefile|\.tgz$' | $DMENU_CMD -p "Port" -l 20);
if [ ! -z "$DIR" ]; then
cd /usr/ports/$DIR
DIR2=$(printf "%s\n\n%s\n%s\n%s\n\nCVS %s\n" \
@ -13,7 +13,7 @@ if [ ! -z "$DIR" ]; then
"Maintainer: $(make show=MAINTAINER)" \
"Homepage: $(make show=HOMEPAGE)" \
"$(cvs log -Nl -rHEAD 2>&1 | awk '{ if ($0 ~ /^===/) p++; if (p == 1) print $0; if ($0 ~ /^---/) p++; }')" \
| dmenu -p "INFO:" $DMENUOPTS -l 20)
| $DMENU_CMD -p "Info" -l 20)
if [ ! -z "$DIR2" ]; then
case "$DIR2" in
Homepage*) firefox "$(make show=HOMEPAGE)" & ;;

View File

@ -1,5 +1,7 @@
#!/bin/sh
. /home/sdk/.dbus_address
MSG="It's $(/bin/date +"%H:%M"). Drink some water!"
/usr/local/bin/notify-send "$MSG"
. /home/sdk/.bin/_config
MSG="Drink some water!"
$NOTIFY_CMD "$MSG"

View File

@ -1,6 +1,11 @@
#!/bin/ksh -xe
umask 022
ARGS="$@"
trap abort 1 2 3 6 9 11
abort() { echo "Abort with >$0 $ARGS< on $(date)" >> /tmp/obsdmake.log; }
JOBS="${JOBS:=$(sysctl -n hw.ncpuonline)}"
export GLOBAL_AUTOCONF_CACHE="/var/ccache/config.cache"
@ -24,6 +29,8 @@ if [ -z "$1" ]; then
exit 2
fi
echo "Start with >$0 $ARGS< on $(date)" >> /tmp/obsdmake.log
doas mkdir -p /usr/obj /usr/xobj
doas chown build /usr/obj /usr/xobj
@ -124,4 +131,6 @@ case "$1" in
release) mkrelease; ;;
all) mkkernel; mkbase; mkxenocara; ;;
esac
echo "Finished with >$0 $ARGS< on $(date)" >> /tmp/obsdmake.log
sync

27
.bin/s
View File

@ -1,27 +0,0 @@
#!/bin/sh
. ~/.bin/_config
[ ! -z "$1" ] && EXTRA="-q $1"
F=$(find /usr/src /usr/xenocara/ /usr/www/ -type f \
-not -path "*/CVS/*" \
-not -path "*/.git/*" \
-not -path "/usr/src/gnu/*" \
\( -name "*.c" \
-o -name "*.h" \
-o -name "*.pl" \
-o -name "*.inc" \
-o -name "patch-*" \
-o -name "DESCR*" \
-o -name "PLIST*" \
-o -name "PLIST*" \
-o -name "Makefile*" \
\) \
-not -name "*.orig" \
-not -name "*.openbsd.orig" \
| while IFS= read -r l; do echo "${#l} $((++n)) $l"; done \
| sort -n -k 1 \
| cut -d" " -f3- \
| fzf -e -1 -0 +s $EXTRA --preview="cat {1}")
set -xe
R="$(readlink -f "$F")"
test -z "$R" || vim "$R"
echo "$(dirname "$R")"

View File

@ -17,7 +17,7 @@ WID=$(wmctrl -x -l scratchpad | fgrep '.scratchpad' | cut -d" " -f1)
if [ -z "$WID" ]
then
sterm -c scratchpad -g 161x38+$GAP+$GAP &
sterm -c scratchpad -g 134x29+$GAP+$GAP &
WID=$(wmctrl -x -l scratchpad | fgrep '.scratchpad' | cut -d" " -f1)
else
# check if window is iconfified or on another WS (or both)
@ -27,9 +27,9 @@ else
#wmctrl -i -r $WID -t $(xprop -root _NET_CURRENT_DESKTOP | cut -d'=' -f2)
wmctrl -i -r $WID -t $_SWM_WS
# remove hidden flag
wmctrl -i -r $WID -b remove,hidden,sicky
wmctrl -i -R $WID -b remove,hidden,sicky
# activate (give focus)
wmctrl -i -a $WID
# wmctrl -i -a $WID
else
# window is visible => hide
wmctrl -i -r $WID -b add,hidden

View File

@ -20,4 +20,4 @@ test -f /usr/local/bin/pngcrush \
_SWM_WS=-1 texec "upload \"$file\""
# NOTIFY
notify-send "$(xclip -o)"
$NOTIFY_CMD "$(xclip -o)"

View File

@ -1,3 +1,3 @@
#!/bin/sh
xpick -h | tr -d '\n' | xclip
notify-send "Copied: $(xclip -o)"
$NOTIFY_CMD "Copied: $(xclip -o)"

View File

@ -17,15 +17,15 @@ color_focus_maximized_free = rgb:ff/6A/00
color_focus_free = rgb:77/77/77
color_unfocus = rgb:47/47/47
color_unfocus_free = rgb:47/47/47
tile_gap = 0
region_padding = 0
disable_border = 0
tile_gap = 12
region_padding = 12
disable_border = 1
# +--------------------------------------------------
# | BAR SETTINGS
# +--------------------------------------------------
bar_enabled = 0
bar_border_width = 4
bar_enabled = 1
bar_border_width = 2
bar_border = rgb:18/18/18
bar_border_unfocus = rgb:18/18/18
bar_border_free = rgb:18/18/18
@ -35,7 +35,7 @@ bar_color_selected = rgb:18/24/28
bar_font_color = rgb:99/99/99,rgb:ff/6A/00,red
bar_font_color_selected = rgb:ff/ff/ff
bar_font_color_free = rgb:99/99/99
bar_font = FuraCodeNerdFont-11
bar_font = CozetteHidpi:pixelsize=26
bar_action = cbar
bar_action_expand = 0
bar_at_bottom = 0
@ -60,7 +60,7 @@ bar_at_bottom = 0
# ++ A literal +
# +@ Prefix for text markup sequences
bar_format = +S +L  +R   +I   +M  +W +|1R +A %Y-%m-%d %H:%M
bar_format = +S WS:+I/+R  H:+M  +W +|2R +A %b %d %H:%M
#bar_format = +I +S (+M) +|1R +A %Y-%m-%d %H:%M
# +--------------------------------------------------
@ -68,32 +68,20 @@ bar_format = +S +L  +R   +I   +M  +W +|1R +A %
# +--------------------------------------------------
workspace_indicator = listall,markcurrent,markactive,markempty,markurgent,noindexes
workspace_mark_active = ''
#workspace_mark_active = ''
workspace_mark_current = '+@fg=1;+@fg=0;'
workspace_mark_empty = ''
workspace_mark_urgent = '+@fg=2;+@fg=0;'
workspace_mark_active = '[A]'
workspace_mark_current = '+@fg=1;[C]+@fg=0;'
workspace_mark_empty = '[ ]'
workspace_mark_urgent = '+@fg=2;[I]+@fg=0;'
workspace_limit = 10
stack_mark_horizontal = ''
stack_mark_horizontal_flip = ''
stack_mark_vertical = ''
stack_mark_vertical_flip = ''
stack_mark_max = ''
stack_mark_floating = '~'
stack_mark_horizontal = 'D'
stack_mark_horizontal_flip = 'U'
stack_mark_vertical = '>'
stack_mark_vertical_flip = '<'
stack_mark_max = 'M'
stack_mark_floating = 'F'
verbose_layout = 0
urgent_enabled = 1
# name = ws[1]:1
# name = ws[2]:2
# name = ws[3]:3
# name = ws[4]:4
# name = ws[5]:5
# name = ws[6]:6
# name = ws[7]:7
# name = ws[8]:8
# name = ws[9]:9
# name = ws[10]:10
# +--------------------------------------------------
# | FOCUS BEHAVIOR
# +--------------------------------------------------
@ -111,7 +99,7 @@ click_to_raise = 1
# | QUIRKS
# +--------------------------------------------------
quirk[scratchpad] = FLOAT + ANYWHERE + FOCUSPREV + FOCUSONMAP_SINGLE
quirk[scratchpad] = FLOAT + ANYWHERE
quirk[XConsole:xconsole] = FLOAT + ANYWHERE + NOFOCUSCYCLE + NOFOCUSONMAP
# +--------------------------------------------------
@ -136,11 +124,11 @@ bind[hterm] = MOD+Control+Return
program[irssi] = texec x
bind[irssi] = MOD+Shift+X
program[Super] = dexec_super
bind[Super] = Super_L
program[man] = dexec_mail
bind[man] = MOD+Shift+M
program[mutt] = texec mutt
bind[mutt] = MOD+Shift+M
program[vpn] = dexec_vpn
bind[vpn] = MOD+V
program[omutt] = texec mutt-openbsd-all
bind[omutt] = MOD+Shift+O
@ -151,6 +139,9 @@ bind[exec] = MOD+D
program[ssh] = dexec_ssh
bind[ssh] = MOD+S
program[ports] = dexec_port
bind[ports] = MOD+Shift+S
program[audio] = dexec_audio
bind[audio] = MOD+O

View File

@ -1,6 +1,6 @@
asterisk = "*";
prompt = "";
font = "JetBrainsMono-10";
font = "CozetteHidpi:pixelsize=26";
bottom = false;
prompt_fg = "#FFFFFF";

39
.kshrc
View File

@ -433,7 +433,7 @@ portclean() {(
cd /usr/ports
doas rm -rf pobj/* plist logs packages bulk update distfiles/*
mkdir -p plist logs packages bulk update
doas chown -R sdk:_pbuild /usr/ports/
#doas chown -R sdk:_pbuild /usr/ports/
doas make fix-permissions
)}
pmark() { pwd > /var/cache/pmark; }
@ -561,30 +561,39 @@ doupload-gopher() {
# YOUTUBE-DL
########################################################################
YTDL_AGENT="Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4506.0 Safari/537.36"
YTDL_OPTS="-i --no-part --abort-on-unavailable-fragment --buffer-size 16K --fragment-retries 100 --http-chunk-size 10M"
ytdl() {
local FMT="bestvideo[ext=mp4][height<=1080]+bestaudio[ext=m4a]/best[ext=mp4]/best"
yt-dlp $YTDL_OPTS --user-agent "$YTDL_AGENT" -f "$FMT" "$@";
yt-dlp "$@";
}
ytdl_playlist() {
local FMT="bestvideo[ext=mp4][height<=1080]+bestaudio[ext=m4a]/best[ext=mp4]/best"
yt-dlp $YTDL_OPTS --user-agent "$YTDL_AGENT" -f "$FMT" -o '%(playlist_title)s/%(title)s.%(ext)s' "$@";
ytdl_playlist() {
yt-dlp \
-o '%(playlist_title)s/%(title)s.%(ext)s' \
"$@";
}
ytdl_channel() {
local FMT="bestvideo[ext=mp4]+bestaudio[ext=m4a]/best[ext=mp4]/best"
yt-dlp $YTDL_OPTS --user-agent "$YTDL_AGENT" --download-archive ytdl_channel.txt -f "$FMT" \
-o '%(upload_date)s - %(title)s.%(ext)s' "$@";
yt-dlp \
--download-archive ytdl_channel.txt \
-o '%(upload_date)s - %(title)s.%(ext)s' \
"$@";
}
ytdl_bandcamp() {
yt-dlp $YTDL_OPTS --user-agent "$YTDL_AGENT" -x --audio-format mp3 -i --embed-thumbnail \
--add-metadata -o '%(artist)s/%(album)s/%(track_number)02d - %(track)s.%(ext)s' "$@";
yt-dlp \
--extract-audio \
--audio-format mp3 \
--embed-thumbnail \
--add-metadata \
-o '%(artist)s/%(album)s/%(track_number)02d - %(track)s.%(ext)s' \
"$@";
}
ytdl_audio() {
yt-dlp $YTDL_OPTS --user-agent "$YTDL_AGENT" -f bestaudio --extract-audio --embed-thumbnail \
--add-metadata -o "%(title)s-%(id)s.%(ext)s" "$@";
yt-dlp \
-f bestaudio \
--extract-audio \
--embed-thumbnail \
--add-metadata \
-o "%(title)s-%(id)s.%(ext)s" \
"$@";
}
xdl() {
mkdir -p "$HOME/x/$1/"

View File

@ -49,7 +49,7 @@ set smarttab
set textwidth=72
" set colorcolumn=72
set formatprg=par\ -w72q
"set formatprg=par\ -w72q
set list
set listchars=tab:»·,trail:•