From 1f8bc0f275876872be5224c71cf9df513d4c1a24 Mon Sep 17 00:00:00 2001 From: Andrea Rogers Date: Mon, 30 Sep 2024 11:21:45 -0500 Subject: [PATCH 01/10] logging: timestamp helper --- logging.bash | 1 + 1 file changed, 1 insertion(+) diff --git a/logging.bash b/logging.bash index 466afb0..5372a58 100644 --- a/logging.bash +++ b/logging.bash @@ -6,3 +6,4 @@ dedcat() { (>&2 cat <<<"$@"); exit 1; } xcat() { (>&2 cat "$@"); exit 0; } excat() { (>&2 cat <<<"$@"); exit 0; } die() { errcho $@; exit 1; } +mktimestamp() { date '+%Y-%m-%d_%s'; } From 3fccfc023d5b3088a94acb99da9e5d03951781d8 Mon Sep 17 00:00:00 2001 From: Andrea Rogers Date: Mon, 30 Sep 2024 11:51:38 -0500 Subject: [PATCH 02/10] Makefile: Make installer actually work! There were some pretty stupid issues that past me didn't fix! Now, there shouldn't be an extra bin inside of your $PREFIX's bin! --- Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 8546d22..03765be 100644 --- a/Makefile +++ b/Makefile @@ -29,7 +29,7 @@ dist/bin: mkdir -pv $@ dist/bin/%.bash: %.bash - ln -s ../lib/bash-util/$*.bash $@ + ln -sf ../lib/bash-util/$*.bash $@ dist/bin/%: scripts/% dist/bin sed 's/^\(.\s\+\)\("\)*.\+\/util\//\1\2$(shell \ @@ -44,12 +44,12 @@ dist/lib/bash-util/%.bash: %.bash chmod 644 $@ $(PREFIX)/bin/util: - ln -s $(PREFIX)/lib/bash-util $(PREFIX)/bin/util + ln -sf $(PREFIX)/lib/bash-util $(PREFIX)/bin/util install: dist cd dist && \ for each in *; \ - do cp -rv "$$each" "$(PREFIX)/$$each"; \ + do cp -rv "$$each"/* "$(PREFIX)/$$each/"; \ done clean: From 2269df14d6fba39e4baf710e91ee05240b04d34b Mon Sep 17 00:00:00 2001 From: Andrea Rogers Date: Mon, 30 Sep 2024 11:55:01 -0500 Subject: [PATCH 03/10] [NEW] record-shell: record shell sessions for librecode We need to record shell sessions in a standardized way, so I made a script to accomplish this! --- scripts/record-shell | 47 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100755 scripts/record-shell diff --git a/scripts/record-shell b/scripts/record-shell new file mode 100755 index 0000000..7c254df --- /dev/null +++ b/scripts/record-shell @@ -0,0 +1,47 @@ +#!/usr/bin/env bash + +: ' + * Record sessions with Asciinema for the Librecode project! + ' + +read -d '' usage < Date: Mon, 30 Sep 2024 14:07:38 -0500 Subject: [PATCH 04/10] [NEW] record-call: Record my audio for calls with Julia Uses "pulse" default audio device on my PipeWire rig. Good enough! --- scripts/record-call | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100755 scripts/record-call diff --git a/scripts/record-call b/scripts/record-call new file mode 100755 index 0000000..09990ea --- /dev/null +++ b/scripts/record-call @@ -0,0 +1,34 @@ +#!/usr/bin/env bash + +: ' + * Record calls with Julia for future annotation 😻 + * (just the audio on my end) + ' + +read -d '' usage < Date: Tue, 1 Oct 2024 10:32:49 -0500 Subject: [PATCH 05/10] Makefile: Work on BusyBox! --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 03765be..edd3c34 100644 --- a/Makefile +++ b/Makefile @@ -33,7 +33,7 @@ dist/bin/%.bash: %.bash dist/bin/%: scripts/% dist/bin sed 's/^\(.\s\+\)\("\)*.\+\/util\//\1\2$(shell \ - sed 's/\([$\/]\)/\\\1/g' <<<$(PREFIX))\/lib\/bash-util\//' < $< > $@ + echo -n $(PREFIX) | sed 's/\([$\/]\)/\\\1/g')\/lib\/bash-util\//' < $< > $@ chmod 755 $@ dist/lib/bash-util: From 0529ea07d8c1127f7f25bb11ba18cfdea11f034f Mon Sep 17 00:00:00 2001 From: Andrea Rogers Date: Tue, 1 Oct 2024 13:10:07 -0500 Subject: [PATCH 06/10] scripts: Fix logging goof in recorders --- scripts/record-call | 6 +++--- scripts/record-shell | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/scripts/record-call b/scripts/record-call index 09990ea..5c36ad7 100755 --- a/scripts/record-call +++ b/scripts/record-call @@ -5,6 +5,8 @@ * (just the audio on my end) ' +. "$(dirname $0)/util/logging.bash" + read -d '' usage < Date: Tue, 1 Oct 2024 13:58:48 -0500 Subject: [PATCH 07/10] [NEW] resumaker: Andrea's unified resume maker --- scripts/resumaker | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 scripts/resumaker diff --git a/scripts/resumaker b/scripts/resumaker new file mode 100644 index 0000000..2ae8ab5 --- /dev/null +++ b/scripts/resumaker @@ -0,0 +1,41 @@ +#!/usr/bin/env bash + +: ' + * Generate my resume using pandoc! + ' + +. "$(dirname $0)/util/logging.bash" + +FONT="monofur for Powerline" + +read -d '' usage < Date: Thu, 3 Oct 2024 10:48:27 -0500 Subject: [PATCH 08/10] resumaker: new -t flag to output TeX --- scripts/resumaker | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/scripts/resumaker b/scripts/resumaker index 2ae8ab5..3eea463 100644 --- a/scripts/resumaker +++ b/scripts/resumaker @@ -6,17 +6,19 @@ . "$(dirname $0)/util/logging.bash" -FONT="monofur for Powerline" +FONT='monofur for Powerline' +EXTENSION='.pdf' read -d '' usage < Date: Sat, 19 Oct 2024 15:21:28 -0500 Subject: [PATCH 09/10] record-shell: Add spoopy stdin recording with "-i" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 🎃🕷🕸 Happy Halloween!! 👻🍬🍫 --- scripts/record-shell | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/scripts/record-shell b/scripts/record-shell index 5608ecf..c993dda 100755 --- a/scripts/record-shell +++ b/scripts/record-shell @@ -13,11 +13,16 @@ OPTIONS -h Display this help. EOUSAGE -while getopts 'h' opt; do +SPOOPY_STDIN='' + +while getopts 'hi' opt; do case "${opt}" in h) excat "$usage" ;; + i) + SPOOPY_STDIN='--stdin' + ;; *) dedcat "$usage" ;; @@ -45,4 +50,4 @@ esac rec_prefix="$HOME/librecode/sessions/mine/$ID/$SUB_ID" mkdir -p "$rec_prefix" -asciinema rec "$rec_prefix/$timestamp" +asciinema rec $SPOOPY_STDIN "$rec_prefix/$timestamp" From 6784b968bae2ba42b2612497b42008d690cca8ec Mon Sep 17 00:00:00 2001 From: Andrea Rogers Date: Thu, 14 Nov 2024 12:19:07 -0600 Subject: [PATCH 10/10] record-shell: Add -i to -h help. --- scripts/record-shell | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/record-shell b/scripts/record-shell index c993dda..1c3de53 100755 --- a/scripts/record-shell +++ b/scripts/record-shell @@ -7,10 +7,11 @@ . "$(dirname $0)/util/logging.bash" read -d '' usage <