upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorDanConwayDev <DanConwayDev@protonmail.com>2026-01-09 21:51:52 +0000
committerDanConwayDev <DanConwayDev@protonmail.com>2026-01-09 21:51:52 +0000
commit5570b9631e03c077faa95fbf1f068a4360d25bd7 (patch)
treee1ece058586e84e2b98b1de1188b4ff3cb5acdd6 /scripts
parent6a8346441ea605248e09858d0e6b9096a1c87259 (diff)
Fix production-sync-testing.md guide and sanitize-logs.sh script
- Fix shebang in sanitize-logs.sh from #!/bin/bash to #!/usr/bin/env bash for NixOS compatibility - Update sanitizer defaults from 100/20 to 200/100 chars for better log readability - Fix CLI argument names in guide: --sync-bootstrap-relay -> --sync-bootstrap-relay-url - Fix CLI argument names in guide: --git-path -> --git-data-path These issues were discovered during first-time testing of the production sync testing guide.
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/sanitize-logs.sh10
1 files changed, 5 insertions, 5 deletions
diff --git a/scripts/sanitize-logs.sh b/scripts/sanitize-logs.sh
index 123e72c..7225fe4 100755
--- a/scripts/sanitize-logs.sh
+++ b/scripts/sanitize-logs.sh
@@ -1,4 +1,4 @@
1#!/bin/bash 1#!/usr/bin/env bash
2# sanitize-logs.sh - Truncates verbose log lines for LLM analysis 2# sanitize-logs.sh - Truncates verbose log lines for LLM analysis
3# 3#
4# Usage: 4# Usage:
@@ -9,8 +9,8 @@
9set -euo pipefail 9set -euo pipefail
10 10
11# Default settings 11# Default settings
12HEAD_CHARS=100 12HEAD_CHARS=200
13TAIL_CHARS=20 13TAIL_CHARS=100
14MAX_LINE_LENGTH=$((HEAD_CHARS + TAIL_CHARS + 20)) # buffer for the ellipsis marker 14MAX_LINE_LENGTH=$((HEAD_CHARS + TAIL_CHARS + 20)) # buffer for the ellipsis marker
15 15
16# Parse arguments 16# Parse arguments
@@ -35,8 +35,8 @@ while [[ $# -gt 0 ]]; do
35 echo "Reads from stdin, writes to stdout." 35 echo "Reads from stdin, writes to stdout."
36 echo "" 36 echo ""
37 echo "Options:" 37 echo "Options:"
38 echo " --head-chars N Show first N chars of long lines (default: 100)" 38 echo " --head-chars N Show first N chars of long lines (default: 200)"
39 echo " --tail-chars N Show last N chars of long lines (default: 20)" 39 echo " --tail-chars N Show last N chars of long lines (default: 100)"
40 echo " --max-line N Lines shorter than this are unchanged (default: head+tail+20)" 40 echo " --max-line N Lines shorter than this are unchanged (default: head+tail+20)"
41 echo " -h, --help Show this help" 41 echo " -h, --help Show this help"
42 echo "" 42 echo ""