Files
cline/sdk/examples/hooks/SessionShutdown.sh
T
Renee Huangandabeatrix e215d3d91c chore: rename example folders; fix references (#60)
* rename folders

* fix examples reorg references

* move over files

* having agent fixing and validating all examples are still working

* fix sidecar paths

---------

Co-authored-by: abeatrix <beatrix@cline.bot>
2026-05-07 20:38:04 -07:00

15 lines
428 B
Bash
Executable File

#!/usr/bin/env bash
# Cline Hook: SessionShutdown
# Logs when a session shuts down (normally or due to error)
# Copy to ~/.cline/hooks/SessionShutdown.sh and chmod +x
input=$(cat)
timestamp=$(echo "$input" | jq -r '.timestamp // "unknown"')
reason=$(echo "$input" | jq -r '.reason // "unknown"')
echo "🔌 Session shutdown at $timestamp" >&2
echo " Reason: $reason" >&2
# Lifecycle events are informational only
echo '{}'