Skip to content

Search Files Node

Data/Files/Operations

Searches the text files below a directory for a literal string or regular expression and returns each matching line with its line number and surrounding lines. Works on every store type. Binary files and files above the size limit are skipped, and lines longer than 1,000 characters are shortened.

path_search_filesdata
Inputs10
Outputs4
Security exposure8/10
Packagedata

Ratings

Scores range from 0 to 10. Higher values mean more impact, exposure, or operational weight.

SecurityAttack surface and exposure impact.
8/10High
PrivacyPotential sensitivity of processed data.
8/10High
PerformanceRuntime or resource pressure.
6/10Medium
GovernancePolicy, audit, or compliance impact.
8/10High
ReliabilityOperational stability considerations.
9/10High
CostExternal or compute cost impact.
9/10High

Input Pins

10

Input

Execution
exec_in

Initiate Execution

Directory

Struct
directory

Directory to search recursively

FlowPathFlowPath3 fields
pathstringrequired
store_refstringrequired
cache_store_refstring | null
Schema enforced

Pattern

String
pattern

Text or regular expression to search for

Regex

Boolean
is_regex

Treat the pattern as a regular expression

Default false

Case Sensitive

Boolean
case_sensitive

Match upper and lower case exactly

Default false

Include

String Array
include

Only search paths matching one of these globs, e.g. *.rs or src/**/*.{ts,tsx}. A glob without / matches any path segment. Empty searches all files

Default []

Exclude

String Array
exclude

Skip paths matching one of these globs, e.g. node_modules or **/*.min.js

Default []

Max File Size

Integer
max_file_size

Skip files larger than this many bytes

Default 1048576

Max Results

Integer
max_results

Stop after this many matching lines

Default 200

Context Lines

Integer
context_lines

Lines to include before and after each match

Default 2
Range 0 to 20

Output Pins

4

Output

Execution
exec_out

Done with the Execution

Matches

Struct Array
matches

Matching lines with path, line number and context

FileSearchMatchFileSearchMatch6 fields
pathstringrequired

Path relative to the searched directory

fileFlowPathrequired

The matching file, ready for Read to String and other file nodes

pathstringrequired
store_refstringrequired
cache_store_refstring | null
line_numberinteger:uint64required

1-based line number

format uint64min 0
linestringrequired
beforeArray<string>required
itemsstringarray item
afterArray<string>required
itemsstringarray item
Schema enforced

Truncated

Boolean
truncated

True when more matches exist than Max Results allowed

Files Scanned

Integer
files_scanned

Number of text files that were searched

Node Info

Internal name
path_search_files
Category
Data/Files/Operations