rtk-ai / rtk-ai/rtk

feat: add built-in compact filters for yarn and sequelize-cli

Open
#1,920 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

area:cli enhancement help wanted priority:medium
Dominant language
Rust
Stars
81.1k
Forks
5.1k
Avg merge
4d 21h
Merged PRs (30d)
35

Description

RTK already has built-in filters for pnpm, npm, and prisma. Four common tools
in the Node.js ecosystem are missing native support:

  • yarn — widely used package manager (classic and berry)
  • sequelize — Sequelize CLI for database migrations
  • ts-node-dev — TypeScript dev server with hot reload
  • nodemon — generic dev server with file watching

Currently these require manual TOML filters in ~/.config/rtk/filters.toml.
Adding them as built-in filters would benefit the broader Node.js user base.

Suggested filter behavior

yarn (classic + berry)

Strip:

  • Version header: yarn install v1.x.x
  • Phase lines: [1/4] Resolving packages..., [2/4] Fetching..., etc.
  • Berry noise: ➤ YN0000: · Yarn, resolution/fetch/link step lines
  • Info lines: info Direct dependencies, info All dependencies
  • Blank lines

Keep: warnings, errors, success, Done in Xs

sequelize (sequelize-cli)

Strip:

  • CLI header: Sequelize CLI [Node: x, CLI: x, ORM: x]
  • Loaded configuration file "..."
  • Using environment "..."
  • Migrating lines: == migration_name: migrating ===

Keep: migrated confirmations, errors, warnings

ts-node-dev

Strip:

  • Version header: [INFO] HH:MM:SS ts-node-dev ver. x.x.x (using ts-node ver. x.x.x, typescript ver. x.x.x)
  • [INFO] HH:MM:SS Using ts-node version...
  • Blank lines

Keep: restart notifications, compilation errors, runtime errors

nodemon

Strip:

  • Version line: [nodemon] x.x.x
  • [nodemon] to restart at any time, enter \rs``
  • [nodemon] watching path(s): ...
  • [nodemon] watching extensions: ...
  • [nodemon] ignoring: ...
  • Blank lines

Keep: restart events ([nodemon] restarting due to changes...), errors, crash messages

Estimated savings

Based on local usage across 4 tools:

  • yarn install: ~60-70% token reduction
  • sequelize db:migrate: ~50% token reduction
  • ts-node-dev dev server: ~40% token reduction (header noise removed)
  • nodemon: ~30% token reduction (watching/config lines removed)

Current workaround

For reference, the TOML filters currently used locally:

[filters.yarn]
description = "yarn install/build - compact output (classic + berry)"
match_command = "^yarn\\b"
strip_ansi = true
strip_lines_matching = [
  "^\\s*$",
  "^yarn install v",
  "^\\[1/\\d\\]", "^\\[2/\\d\\]", "^\\[3/\\d\\]", "^\\[4/\\d\\]",
  "^info Direct dependencies",
  "^info All dependencies",
  "^info This module",
  "^➤ YN0000: · Yarn",
  "^➤ YN0000: .*(Resolution|Fetch|Link) step",
  "^➤ YN0000: [┌└│]",
]
max_lines = 40
on_empty = "yarn: ok"

[filters.sequelize]
description = "Sequelize CLI migrations - errors and final status only"
match_command = "^sequelize\\b"
strip_ansi = true
strip_lines_matching = [
  "^\\s*$",
  "^Sequelize CLI \\[",
  "^Loaded configuration",
  "^Using environment",
  "^== .+: migrating =+$",
] 
max_lines = 30
on_empty = "sequelize: ok"

[filters.ts-node-dev]
description = "ts-node-dev - strip version header, keep restarts and errors"
match_command = "^ts-node-dev\\b"
strip_ansi = true
strip_lines_matching = [
  "^\\s*$",
  "^\\[INFO\\] \\d{2}:\\d{2}:\\d{2} ts-node-dev ver\\.",
  "^\\[INFO\\] \\d{2}:\\d{2}:\\d{2} Using ts-node",
] 
max_lines = 30

[filters.nodemon]
description = "nodemon - strip watching/config lines, keep restarts and errors"
match_command = "^nodemon\\b"
strip_ansi = true
strip_lines_matching = [
  "^\\s*$",
  "^\\[nodemon\\] \\d+\\.\\d+\\.\\d+$",
  "^\\[nodemon\\] to restart",
  "^\\[nodemon\\] watching",
  "^\\[nodemon\\] ignoring",
]
max_lines = 20

Environment

- RTK version: rtk --version
- Use case: Claude Code sessions, Node.js/TypeScript projects with Express + Sequelize

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the existing built-in pnpm, npm, and prisma filters and their tests, then compare them with the workaround filters in ~/.config/rtk/filters.toml. Add built-in handling for yarn, sequelize, ts-node-dev, and nodemon with the listed noise-removal and preservation rules; done means each command produces compact output while retaining warnings, errors, and status messages.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, rust, typescript
Domain
cli, tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.