summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.Xdefaults5
-rw-r--r--config.h1
-rwxr-xr-xst-copyout4
3 files changed, 8 insertions, 2 deletions
diff --git a/.Xdefaults b/.Xdefaults
index b4322ee..05b5e2e 100644
--- a/.Xdefaults
+++ b/.Xdefaults
@@ -7,6 +7,11 @@ st.font: Monospace-11;
! st.termname: st-256color
! st.borderpx: 2
+!! Set the background, foreground and cursor colors as below:
+*.background: #282828
+*.foreground: white
+*.cursorColor: white
+
/* !! gruvbox: */
/* *.color0: #1d2021 */
/* *.color1: #cc241d */
diff --git a/config.h b/config.h
index 6c77427..22e9d21 100644
--- a/config.h
+++ b/config.h
@@ -155,6 +155,7 @@ static unsigned int defaultattr = 11;
*/
ResourcePref resources[] = {
{ "font", STRING, &font },
+ { "fontalt0", STRING, &font2[0] },
{ "color0", STRING, &colorname[0] },
{ "color1", STRING, &colorname[1] },
{ "color2", STRING, &colorname[2] },
diff --git a/st-copyout b/st-copyout
index e40fedd..8eafc58 100755
--- a/st-copyout
+++ b/st-copyout
@@ -6,7 +6,7 @@
tmpfile=$(mktemp /tmp/st-cmd-output.XXXXXX)
trap 'rm "$tmpfile"' 0 1 15
sed -n "w $tmpfile"
-ps1="$(grep "\S" "$tmpfile" | tail -n 1 | cut -d' ' -f1)"
+ps1="$(grep "\S" "$tmpfile" | tail -n 1 | sed 's/^\s*//' | cut -d' ' -f1)"
chosen="$(grep -F "$ps1" "$tmpfile" | sed '$ d' | tac | dmenu -p "Copy which command's output?" -i -l 10 | sed 's/[^^]/[&]/g; s/\^/\\^/g')"
eps1="$(echo "$ps1" | sed 's/[^^]/[&]/g; s/\^/\\^/g')"
-awk "/^$chosen$/{p=1;print;next} p&&/^$eps1/{p=0};p" "$tmpfile" | xclip -selection clipboard
+awk "/^$chosen$/{p=1;print;next} p&&/$eps1/{p=0};p" "$tmpfile" | xclip -selection clipboard