diff --git a/.bin/_config b/.bin/_config index e3c2a72..7b0c208 100644 --- a/.bin/_config +++ b/.bin/_config @@ -4,10 +4,10 @@ # # FONTS # -DFONT="-xos4-terminus-medium-r-normal--26-200-72-72-c-100-iso10646-1" +DFONT="-xos4-terminus-medium-r-normal--18-200-72-72-c-100-iso10646-1" SFONT="-xos4-terminus-medium-r-normal--18-200-72-72-c-100-iso10646-1" -BFONT="-xos4-terminus-medium-r-normal--26-200-72-72-c-100-iso10646-1" -HFONT="-xos4-terminus-medium-r-normal--38-200-72-72-c-100-iso10646-1" +BFONT="-xos4-terminus-medium-r-normal--13-200-72-72-c-100-iso10646-1" +HFONT="-xos4-terminus-medium-r-normal--26-200-72-72-c-100-iso10646-1" # # TERMINALS @@ -21,10 +21,10 @@ HTERM="st -f ${HFONT}" # # NOTION ORANGE -# DMENUOPTS="-fn '$DFONT' -nb #121212 -nf #707070 -sf #FFA600 -sb #121212 -l 20 -i -f" +DMENUOPTS="-fn '$DFONT' -nb #121212 -nf #707070 -sf #FFA600 -sb #121212 -l 10 -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" diff --git a/.bin/cbar b/.bin/cbar index 9d275d0..322ed39 100755 Binary files a/.bin/cbar and b/.bin/cbar differ diff --git a/.bin/dexec_browser b/.bin/dexec_browser index a0c2132..48acc62 100755 --- a/.bin/dexec_browser +++ b/.bin/dexec_browser @@ -10,32 +10,26 @@ # 3. choose which browser to use # (can suggest a matching default) + +. ${HOME}/.bin/_config + HISTFILE="${HOME}/.browser_history" +touch "${HISTFILE}" -test -f ${HOME}/.bin/_config \ - && . ${HOME}/.bin/_config \ - || DMENU_CMD=dmenu - -test -f "${HISTFILE}" \ - || touch "${HISTFILE}" - -PICKLIST="\ -paste_from_clipboard -$(< "${HISTFILE}") -" - -# show filtered history file -# EXPECTS: $PICKLIST $HISTFILE $DMENU_CMD +# show history file +# EXPECTS: $HISTFILE $DMENU_CMD # PROVIDES: $INPUT read_input() { - local S=$(printf '%s\n' "${PICKLIST}" \ - | ${DMENU_CMD} -p "Bookmarks") + local S=$( { echo "paste_from_clipboard"; tail -r ${HISTFILE}; } \ + | awk '!seen[$0]++' \ + | ${DMENU_CMD} -p "Bookmarks") + case "${S}" in - paste_from_clipboard) - S=$(xclip -o \ - | head -n 1) ;; + paste_from_clipboard) S=$(xclip -o | head -n 1); ;; esac + [ -z "${S}" ] && exit 0 + INPUT="${S}" } @@ -175,7 +169,7 @@ choose_browser() { } save_history() { - printf '%s\n' "${INPUT}" >> "${HISTFILE}" + printf '%s\n' "${INPUT}" | sed 's/^ *//g;s/ *$//g' >> "${HISTFILE}" } # main program starts here. diff --git a/.kshrc b/.kshrc index 594b7f6..e6631fe 100644 --- a/.kshrc +++ b/.kshrc @@ -101,7 +101,7 @@ PASSWORD_STORE_ENABLE_EXTENSIONS=true export PASSWORD_STORE_ENABLE_EXTENSIONS # PORTS -MAKE_JOBS=8 +MAKE_JOBS=$(sysctl -n hw.ncpuonline) FETCH_PACKAGES=No export MAKE_JOBS FETCH_PACKAGES @@ -475,7 +475,7 @@ mygdb() { alias update-ksh="cd /usr/src/bin/ksh \ && doas make clean \ && doas make obj \ - && doas make \ + && doas make -j $MAKE_JOBS \ && doas make install" ########################################################################