refactor: extract shared modules from monolithic files#1
Merged
Conversation
…WrapperDetection - Create permissionChecker.ts with shared matchingRulesForInput (was duplicated in bash and PS) - Create commandWrapperDetection.ts with stripSafeWrappers, stripWrappersFromArgv, stripAllLeadingEnvVars, BINARY_HIJACK_VARS, SAFE_ENV_VARS, ANT_ONLY_SAFE_ENV_VARS - bashPermissions.ts: 2598 → 2182 lines (-16%) - powershellPermissions.ts: 1648 → 1624 lines (matchingRulesForInput now shared) - Update importers: shouldUseSandbox.ts, pathValidation.ts Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…anagePlugins Extract ~270 lines of unified items computation (useUnifiedItems) and the UnifiedInstalledItem type definition (unifiedTypes.ts) from the 2214-line ManagePlugins component. Also removes unused imports (getPluginEditableScopes, getFlaggedPlugins). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Extract ~110 lines of pure utility functions (toDraft, presetToDraft, profileSummary, GitHub credential helpers, Codex OAuth helpers) into providerManagerHelpers.ts from the 1535-line ProviderManager component. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Extract ~290 lines of pure functions (regex patterns, token extraction, suggestion application, shell completion, directory completion) into typeaheadHelpers.ts from the 1040-line useTypeahead hook. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Extract ~190 lines of pure functions (classifyToolError, OTel source mapping, MCP server lookup, image paste ID computation) into toolExecutionHelpers.ts from the 1589-line toolExecution module. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Bot automático roda em todo pull_request + manual via workflow_dispatch. Anti-alucinação: dois passes (review + verification). Requer secret OPENROUTER_API_KEY no repo. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sem parênteses, `&&` tem precedência maior que `||`, fazendo o filtro
aceitar erros com source===pluginId sem verificar 'plugin' in e primeiro.
Adicionado parênteses: ('plugin' in e && e.plugin === name) || ...
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Owner
Author
Code Review Manual — feat/refactor-monolithsStatus: ✅ Aprovado com 1 fix commitado [HIGH] CORRIGIDO — Bug de precedência em
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Extração de módulos compartilhados identificados pelo code-review-graph. Fase 1: permissions (commandWrapperDetection + permissionChecker). Fase 2: UI hooks (useUnifiedItems, providerManagerHelpers). Fase 3: typeaheadHelpers. Fase 4: toolExecutionHelpers. 15 arquivos, +1563/-1358 linhas, zero regressões TS.