Pierwszy commit - inicjalizacja projektu
This commit is contained in:
32
claude_markdown.sh
Executable file
32
claude_markdown.sh
Executable file
@@ -0,0 +1,32 @@
|
||||
#!/bin/bash
|
||||
INPUT="$1"
|
||||
OUTPUT="$2"
|
||||
|
||||
cat > "$OUTPUT" << 'MD_START'
|
||||
---
|
||||
title: "Claude Code Conversation - modb_orno3"
|
||||
author: "Claude & User"
|
||||
date: "25 stycznia 2026"
|
||||
geometry: margin=2cm
|
||||
---
|
||||
|
||||
MD_START
|
||||
|
||||
jq -r '
|
||||
select(.type == "user" or .type == "assistant") |
|
||||
if .type == "user" then
|
||||
"\n## 👤 User Query\n\n```\n" + (.message.content // "") + "\n```\n"
|
||||
elif .type == "assistant" then
|
||||
"\n## 🤖 Claude Response\n\n" + (
|
||||
if (.message.content | type) == "array" then
|
||||
(.message.content[] | select(.type == "text") | .text)
|
||||
else
|
||||
(.message.content // "")
|
||||
end
|
||||
) + "\n"
|
||||
else
|
||||
empty
|
||||
end
|
||||
' "$INPUT" >> "$OUTPUT"
|
||||
|
||||
echo "✓ Markdown saved to: $OUTPUT"
|
||||
Reference in New Issue
Block a user