remove obsolete process tools

This commit is contained in:
Ollie Agent 2026-08-16 10:41:42 +02:00
parent 8567ddaa36
commit 36649367eb
10 changed files with 0 additions and 204 deletions

View File

@ -29,10 +29,6 @@
"skill_list",
"skill_load",
"subagent_generate",
"process_list",
"process_output",
"process_signal",
"process_dismiss",
"logseq",
"system_logs",
"browser_screencap",

View File

@ -1,24 +0,0 @@
#!/usr/bin/env bash
# args_json: {"type":"object","required":["pid"],"properties":{"pid":{"type":"string","description":"Process PID"}}}
# ollie:prompt
# ## process_dismiss
#
# Dismiss a finished detached process, removing it from the list.
#
# ```
# process_dismiss(pid="12345")
# ```
# ollie:end
set -euo pipefail
source "$(dirname "$0")/_lib/args.sh"
pid=$(arg_require "pid")
session="${OLLIE_SESSION_ID:?OLLIE_SESSION_ID not set}"
dbus-send --session --dest=org.ollie.SessionManager --type=method_call --print-reply \
/org/ollie/SessionManager org.ollie.SessionManager.DismissDetached \
"string:$session" "int32:$pid" 2>&1 | grep -q 'boolean true' && \
echo "Dismissed PID $pid" || \
{ echo "Failed to dismiss PID $pid (still running or not found)" >&2; exit 1; }

View File

@ -1,16 +0,0 @@
{
"description": "Dismiss a finished detached process, removing it from the list.",
"prompt": "## process_dismiss\n\nDismiss a finished detached process, removing it from the list.\n\n```\nprocess_dismiss(pid=\"12345\")\n```",
"args": {
"type": "object",
"required": [
"pid"
],
"properties": {
"pid": {
"type": "string",
"description": "Process PID"
}
}
}
}

View File

@ -1,38 +0,0 @@
#!/usr/bin/env bash
# ollie:parallel read
# args_json: {"type":"object","properties":{}}
# ollie:prompt
# ## process_list
#
# List background (detached) processes for this session.
#
# ```
# process_list()
# ```
#
# **Returns**: PID, command, start time, and status (running/exited) for each.
# ollie:end
set -euo pipefail
source "$(dirname "$0")/_lib/args.sh"
session="${OLLIE_SESSION_ID:?OLLIE_SESSION_ID not set}"
output=$(dbus-send --session --dest=org.ollie.SessionManager --type=method_call --print-reply \
/org/ollie/SessionManager org.ollie.SessionManager.ListDetached \
"string:$session" 2>&1)
entries=$(echo "$output" | grep 'string "' | sed 's/.*string "//;s/"$//' || true)
if [ -z "$entries" ]; then
echo "No detached processes."
exit 0
fi
printf '%-8s %-10s %-40s %s\n' 'PID' 'STATUS' 'COMMAND' 'STARTED'
printf '%-8s %-10s %-40s %s\n' '---' '------' '-------' '-------'
while IFS=$'\t' read -r pid cmd started status; do
started_fmt=$(date -d "@$started" '+%H:%M:%S' 2>/dev/null || echo "$started")
printf '%-8s %-10s %-40s %s\n' "$pid" "$status" "${cmd:0:40}" "$started_fmt"
done <<< "$entries"

View File

@ -1,9 +0,0 @@
{
"description": "List background (detached) processes for this session.",
"prompt": "## process_list\n\nList background (detached) processes for this session.\n\n```\nprocess_list()\n```\n\n**Returns**: PID, command, start time, and status (running/exited) for each.",
"args": {
"type": "object",
"properties": {}
},
"scope": "read"
}

View File

@ -1,34 +0,0 @@
#!/usr/bin/env bash
# ollie:parallel read
# args_json: {"type":"object","required":["pid"],"properties":{"pid":{"type":"string","description":"Process PID"}}}
# ollie:prompt
# ## process_output
#
# Read output from a detached background process (last 64KB ring buffer).
#
# ```
# process_output(pid="12345")
# ```
# ollie:end
set -euo pipefail
source "$(dirname "$0")/_lib/args.sh"
pid=$(arg_require "pid")
session="${OLLIE_SESSION_ID:?OLLIE_SESSION_ID not set}"
# Find agent (use first agent in session)
agent=$(ollie-9p ls "session/$session/agent" 2>/dev/null | grep -v '^new$' | head -1)
[ -z "$agent" ] && { echo "error: no agent in session" >&2; exit 1; }
result=$(ollie-9p read "session/$session/agent/$agent/proc/$pid" 2>&1) || {
echo "(no output captured yet)"
exit 0
}
if [ -z "$result" ]; then
echo "(no output captured yet)"
else
echo "$result"
fi

View File

@ -1,17 +0,0 @@
{
"description": "Read output from a detached background process (last 64KB ring buffer).",
"prompt": "## process_output\n\nRead output from a detached background process (last 64KB ring buffer).\n\n```\nprocess_output(pid=\"12345\")\n```",
"args": {
"type": "object",
"required": [
"pid"
],
"properties": {
"pid": {
"type": "string",
"description": "Process PID"
}
}
},
"scope": "read"
}

View File

@ -1,38 +0,0 @@
#!/usr/bin/env bash
# args_json: {"type":"object","required":["pid"],"properties":{"pid":{"type":"string","description":"Process PID"},"signal":{"type":"string","description":"Signal name: TERM (default) or KILL"}}}
# ollie:prompt
# ## process_signal
#
# Send a signal to a detached background process.
#
# ```
# process_signal(pid="12345", signal="TERM")
# ```
# ollie:end
set -euo pipefail
source "$(dirname "$0")/_lib/args.sh"
pid=$(arg_require "pid")
signal=$(arg_get "signal" "TERM")
session="${OLLIE_SESSION_ID:?OLLIE_SESSION_ID not set}"
# Find agent (use first agent in session)
agent=$(ollie-9p ls "session/$session/agent" 2>/dev/null | grep -v '^new$' | head -1)
[ -z "$agent" ] && { echo "error: no agent in session" >&2; exit 1; }
proc_path="session/$session/agent/$agent/proc/$pid"
case "$signal" in
TERM|KILL)
# Remove the proc file to signal termination
ollie-9p rm "$proc_path" 2>/dev/null && \
echo "Signal $signal sent to PID $pid" || \
{ echo "Failed to signal PID $pid (process may have already exited)" >&2; exit 1; }
;;
*)
echo "error: unsupported signal: $signal (use TERM or KILL)" >&2
exit 1
;;
esac

View File

@ -1,20 +0,0 @@
{
"description": "Send a signal to a detached background process.",
"prompt": "## process_signal\n\nSend a signal to a detached background process.\n\n```\nprocess_signal(pid=\"12345\", signal=\"TERM\")\n```",
"args": {
"type": "object",
"required": [
"pid"
],
"properties": {
"pid": {
"type": "string",
"description": "Process PID"
},
"signal": {
"type": "string",
"description": "Signal name: TERM (default) or KILL"
}
}
}
}

View File

@ -197,10 +197,6 @@ install-data:
install -m755 data/tools/image_read {{cfg}}/tools/image_read
install -m755 data/tools/memory_recall {{cfg}}/tools/memory_recall
install -m755 data/tools/memory_remember {{cfg}}/tools/memory_remember
install -m755 data/tools/process_dismiss {{cfg}}/tools/process_dismiss
install -m755 data/tools/process_list {{cfg}}/tools/process_list
install -m755 data/tools/process_output {{cfg}}/tools/process_output
install -m755 data/tools/process_signal {{cfg}}/tools/process_signal
install -m755 data/tools/subagent_spawn {{cfg}}/tools/subagent_spawn
install -m755 data/tools/logseq {{cfg}}/tools/logseq
install -m755 data/tools/skill_list {{cfg}}/tools/skill_list