hookcmd

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 28, 2026 License: Apache-2.0 Imports: 4 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package hookcmd builds and recognizes Trace agent hook commands. Absolute executable paths keep hooks working when an agent starts with a minimal PATH.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Command

func Command(agent, event string) string

Command returns a shell command for one agent hook.

func IsTraceHook

func IsTraceHook(command, agent string) bool

IsTraceHook reports whether command is any Trace hook for agent.

func IsTraceHookFor

func IsTraceHookFor(command, agent, event string) bool

IsTraceHookFor reports whether command invokes the given agent event. It recognizes both legacy bare `trace hook ...` commands and absolute paths.

func Path

func Path() string

Path returns the current executable, resolved through symlinks where possible.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL