mirror of
https://github.com/YspCoder/clawgo.git
synced 2026-04-28 12:17:28 +08:00
Slim subagent runtime surface and remove legacy interfaces
This commit is contained in:
@@ -2,7 +2,6 @@ package tools
|
||||
|
||||
import (
|
||||
"path/filepath"
|
||||
"strings"
|
||||
)
|
||||
|
||||
func normalizeMemoryNamespace(in string) string {
|
||||
@@ -24,11 +23,3 @@ func memoryNamespaceBaseDir(workspace, namespace string) string {
|
||||
func parseMemoryNamespaceArg(args map[string]interface{}) string {
|
||||
return normalizeMemoryNamespace(MapStringArg(args, "namespace"))
|
||||
}
|
||||
|
||||
func isPathUnder(parent, child string) bool {
|
||||
rel, err := filepath.Rel(parent, child)
|
||||
if err != nil {
|
||||
return false
|
||||
}
|
||||
return !strings.HasPrefix(rel, "..")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user