Skip to content

Feature/code search#13

Merged
tmaffia merged 5 commits intomainfrom
feature/code-search
Dec 13, 2025
Merged

Feature/code search#13
tmaffia merged 5 commits intomainfrom
feature/code-search

Conversation

@tmaffia
Copy link
Owner

@tmaffia tmaffia commented Dec 13, 2025

Summary

This PR introduces major new functionality for repository browsing and code searching, alongside significant improvements to the PR review workflow. It adds two new commands (browse and search) and refactors the pr review command to support both interactive and flag-based workflows.

Key Changes

New Features

browse Command: Added bb browse to quickly open the current repository (or a specific workspace/repo) in the default web browser.
search code Command: Added bb search code to perform code searches across the workspace directly from the CLI.
Supports filtering by file extension (--extension).
Supports scoping to a specific repository (--repo).
Customizable result limits (--limit).

Improvements

Enhanced pr review: The bb pr review command has been refactored to support direct action flags, allowing for non-interactive usage:
--approve: Approve a PR immediately.
--request-changes: Request changes on a PR.
--comment: Post a comment (requires --body).
Retains the existing interactive mode if no flags are provided.
API Client: Added search_code method and improved get_file_content to detect and error gracefully when Bitbucket returns a directory listing as JSON instead of file text.
Documentation: Updated README.md with usage examples for the new commands and configuration.

Fixes & Refactoring

Extracted source URL building logic into the API client for better reusability.
Improved error handling for file viewing commands.

How to Test

Browse: Run bb browse to open the current repo. Run bb browse workspace/repo to open a remote one.
Search: Run bb search code "struct" --extension rs to search for Rust structs.
PR Review:
Run bb pr review --approve on an open PR to test the flag.
Run bb pr review to test the interactive menu.

@tmaffia tmaffia merged commit f345864 into main Dec 13, 2025
1 check passed
@tmaffia tmaffia deleted the feature/code-search branch December 13, 2025 04:18
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.

1 participant