Skip to content

Conversation

@Paveltarno
Copy link
Collaborator

@Paveltarno Paveltarno commented Feb 12, 2026

Note

Description

This PR integrates Knip, a tool for detecting unused code and dependencies, into the Base44 CLI project. It includes configuration for Knip, CI/CD integration, and cleanup of unused exports and dependencies identified by the tool.

Related Issue

None

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Refactoring (no functional changes)
  • Other (please describe):

Changes Made

  • Added Knip dependency (v5.83.1) and configuration file (knip.json)
  • Created GitHub Actions workflow (.github/workflows/knip.yml) to run Knip on PRs and main branch pushes
  • Added Claude Code settings (.claude/settings.json) with hooks for typecheck, lint, and knip after edits
  • Removed unused exports across multiple modules (types, interfaces, constants)
  • Removed @types/tar dependency (unused type definitions)
  • Updated msw from v2.12.7 to v2.12.10
  • Added .worktrees to .gitignore
  • Cleaned up telemetry module exports (removed unused PostHog-related exports)
  • Made several interfaces and functions internal by removing exports (e.g., RunCommandOptions, CLIError, UserError, SystemError)
  • Removed unused error handling code and helper functions

Testing

  • I have tested these changes locally
  • I have added/updated tests as needed
  • All tests pass (npm test)

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation (if applicable)
  • My changes generate no new warnings
  • I have updated AGENTS.md if I made architectural changes

Additional Notes

This refactoring improves code maintainability by identifying and removing unused code/dependencies. The Knip CI workflow will help prevent accumulation of dead code in the future. Changes are purely internal cleanup and do not affect the CLI's behavior or public API.


🤖 Generated by Claude | 2026-02-12 21:15 UTC

@github-actions
Copy link
Contributor

github-actions bot commented Feb 12, 2026

🚀 Package Preview Available!


Install this PR's preview build with npm:

npm i @base44-preview/cli@0.0.31-pr.237.6328bcf

Prefer not to change any import paths? Install using npm alias so your code still imports base44:

npm i "base44@npm:@base44-preview/cli@0.0.31-pr.237.6328bcf"

Or add it to your package.json dependencies:

{
  "dependencies": {
    "base44": "npm:@base44-preview/cli@0.0.31-pr.237.6328bcf"
  }
}

Preview published to npm registry — try new features instantly!

@claude
Copy link

claude bot commented Feb 12, 2026

README check ran. 6 issue(s) found and applied: (1) Added missing eject command, (2) Updated create description to match code, (3) Updated deploy description to match code, (4) Updated link description to match code, (5) Updated logout description to match code, (6) Updated agent command descriptions to include full text from code. README.md has been updated locally but cannot be pushed from detached HEAD state in CI. Please review the changes in commit bab6386.

@Paveltarno Paveltarno merged commit 69af39b into main Feb 12, 2026
11 checks passed
@Paveltarno Paveltarno deleted the setup-knip branch February 12, 2026 11:42
@Paveltarno Paveltarno restored the setup-knip branch February 12, 2026 11:47
@Paveltarno Paveltarno deleted the setup-knip branch February 12, 2026 12:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants