Skip to main content

Definition

Assembly: CloudNimble.ClaudeEssentials.dll Namespace: CloudNimble.ClaudeEssentials.Hooks.Tools.Inputs Inheritance: System.Object

Syntax

Summary

Represents the input parameters for the Grep tool. The Grep tool is a powerful content search built on ripgrep.

Remarks

Supports full regex syntax (e.g., “log.*Error”, “function\s+\w+”). Filter files with glob parameter or type parameter.

Constructors

.ctor

Syntax

.ctor Inherited

Inherited from object

Syntax

Properties

CaseInsensitive

Gets or sets whether to perform case insensitive search.

Syntax

Property Value

Type: System.Nullable<bool>?

Glob

Gets or sets the glob pattern to filter files.

Syntax

Property Value

Type: string?

Remarks

Examples: “.js”, ”.

HeadLimit

Gets or sets the limit on output to first N lines/entries.

Syntax

Property Value

Type: System.Nullable<int>?

Remarks

Equivalent to ”| head -N”. Defaults to 0 (unlimited).

LinesAfter

Gets or sets the number of lines to show after each match.

Syntax

Property Value

Type: System.Nullable<int>?

Remarks

Requires output_mode: “content”, ignored otherwise.

LinesBefore

Gets or sets the number of lines to show before each match.

Syntax

Property Value

Type: System.Nullable<int>?

Remarks

Requires output_mode: “content”, ignored otherwise.

LinesContext

Gets or sets the number of lines to show before and after each match.

Syntax

Property Value

Type: System.Nullable<int>?

Remarks

Requires output_mode: “content”, ignored otherwise.

Multiline

Gets or sets whether to enable multiline mode.

Syntax

Property Value

Type: System.Nullable<bool>?

Remarks

When enabled, ’.’ matches newlines and patterns can span lines. Default: false.

Offset

Gets or sets the number of lines/entries to skip before applying head_limit.

Syntax

Property Value

Type: System.Nullable<int>?

Remarks

Equivalent to ”| tail -n +N | head -N”. Defaults to 0.

OutputMode

Gets or sets the output mode.

Syntax

Property Value

Type: string?

Remarks

Options: “content” (shows matching lines), “files_with_matches” (shows only file paths, default), “count” (shows match counts).

Path

Gets or sets the file or directory to search in.

Syntax

Property Value

Type: string?

Remarks

Defaults to current working directory if not specified.

Pattern

Gets or sets the regular expression pattern to search for in file contents.

Syntax

Property Value

Type: string

Remarks

Uses ripgrep syntax. Literal braces need escaping (use “interface{}” to find “interface” in Go code).

ShowLineNumbers

Gets or sets whether to show line numbers in output.

Syntax

Property Value

Type: System.Nullable<bool>?

Remarks

Requires output_mode: “content”, ignored otherwise. Defaults to true.

Type

Gets or sets the file type to search.

Syntax

Property Value

Type: string?

Remarks

Common types: js, py, rust, go, java, etc. More efficient than glob for standard file types.

Methods

Equals Inherited Virtual

Inherited from object

Syntax

Parameters

Returns

Type: bool

Equals Inherited

Inherited from object

Syntax

Parameters

Returns

Type: bool

GetHashCode Inherited Virtual

Inherited from object

Syntax

Returns

Type: int

GetType Inherited

Inherited from object

Syntax

Returns

Type: System.Type

MemberwiseClone Inherited

Inherited from object

Syntax

Returns

Type: object

ReferenceEquals Inherited

Inherited from object

Syntax

Parameters

Returns

Type: bool

ToString Inherited Virtual

Inherited from object

Syntax

Returns

Type: string?