Expand description
Subcommand handler implementations. Subcommand handler implementations for all atomwrite operations.
Modules§
- apply
- Patch application from stdin (unified diff, SEARCH/REPLACE, full file). Patch application from stdin: unified diff, SEARCH/REPLACE, full file. Workload: I/O-bound (stdin read + patch parse + atomic write).
- backup
- Standalone file backup with BLAKE3 checksums. Standalone file backup with timestamped copies and BLAKE3 checksums. Workload: I/O-bound (file copy + fsync).
- batch
- Batch operation execution from NDJSON manifest. Batch execution of multiple operations from an NDJSON manifest. Workload: I/O-bound (NDJSON parse + multi-file atomic writes).
- calc
- Math expression evaluation via fend. Math expression evaluation and unit conversion via fend. Workload: CPU-bound (expression parsing + evaluation).
- case
- v14 Tier 3: identifier case conversion (snake/camel/Pascal/kebab/SCREAMING).
v14 Tier 3 subcommand:
case— convert identifier case (snake_case, camelCase, PascalCase, kebab-case, SCREAMING_SNAKE_CASE) in source files. - copy
- Atomic file copy with checksum verification. Atomic file copy with BLAKE3 checksum verification. Workload: I/O-bound (file read + atomic write).
- count
- Line, match, and extension counting. File and line counting with optional grouping by extension. Workload: I/O-bound (parallel file walk + line counting).
- del
- v14 Tier 3: structured config key removal.
v14 Tier 3 subcommand:
del— remove a key at a dotted path in a structured config file (TOML or JSON) while preserving formatting. - delete
- File deletion with optional backup. File deletion with optional backup before removal. Workload: I/O-bound (unlink syscall + fsync).
- diff
- Unified diff between two files. File comparison with unified, stat, or changes-only output. Workload: CPU-bound (text diff algorithm + I/O).
- edit
- Surgical file editing by line or marker. Surgical file editing by line number, text marker, or exact match. Workload: I/O-bound (file read + fuzzy match + atomic write).
- extract
- Field extraction from NDJSON or text. Field extraction from NDJSON input or text columns. Workload: I/O-bound (stdin streaming + field selection).
- get
- v14 Tier 3: structured config value reader.
v14 Tier 3 subcommand:
get— read a value at a dotted path in a structured config file (TOML or JSON). - hash
- BLAKE3 checksum computation for files. Standalone BLAKE3 checksum computation for one or more files. Workload: CPU-bound (BLAKE3 hashing).
- list
- Directory listing with metadata. Directory listing with metadata, gitignore support, and depth control. Workload: I/O-bound (directory walk + stat per entry).
- move
- Atomic file move and rename. Atomic file move with cross-device fallback to copy-then-delete. Workload: I/O-bound (rename syscall + fsync).
- outline
- v14 Tier 3 (v0.1.12): tree-sitter S-expression query against a file.
v14 Tier 3 subcommand (v0.1.12):
outline— extract the high-level structure of a source file (functions, classes, structs, enums, traits, modules, top-level consts) as NDJSON. Usestree-sitter-language-pack. - query
- v14 Tier 3 (v0.1.12): tree-sitter S-expression query against a file.
v14 Tier 3 subcommand (v0.1.12):
query— walk a source file’s tree-sitter parse tree and emit AST nodes as NDJSON. Usestree-sitter-language-packfor parser provisioning (305 languages; downloads on first use; cache local). - read
- File reading with metadata and content. File reading with metadata, checksum, and optional content. Workload: I/O-bound (file read + NDJSON output).
- regex_
gen - Regex generation from examples via grex. Regex pattern generation from example strings via grex. Workload: CPU-bound (regex synthesis from examples).
- replace
- Parallel text replacement with atomic writes. Parallel text replacement across files with atomic writes. Workload: I/O-bound (file reading + regex matching + atomic write).
- rollback
- File restoration from backup. File restoration from a previous timestamped backup. Workload: I/O-bound (backup read + atomic write).
- scope
- Grammatical scoping with AST-based actions. Grammatical scoping: AST-based code selection and transformation. Workload: mixed I/O-bound + CPU-bound (file reading + AST traversal via ast-grep + atomic write).
- search
- Parallel file content search via ripgrep. Parallel file content search powered by the ripgrep engine. Workload: I/O-bound (file reading + regex matching via ripgrep engine).
- set
- v14 Tier 3: structured config value setter.
v14 Tier 3 subcommand:
set— modify a single key in a structured config file while preserving comments, key order, and formatting. - transform
- Structural AST code search and rewrite. Structural AST search and rewrite via ast-grep. Workload: mixed I/O-bound + CPU-bound (file reading + AST parsing via ast-grep + atomic write).
- write
- Atomic file creation and overwrite. Atomic file creation and overwrite from stdin content. Workload: I/O-bound (stdin read + atomic write).