Skip to content

Conversation

@gtrrz-victor
Copy link
Contributor

@gtrrz-victor gtrrz-victor commented Jan 27, 2026

  $ entire status                                                                                                                                                                          
  Enabled (manual-commit)                                                                                                                                                                              
                                                                                                                                                                                                       
  $ entire status --detailed                                                                                                                                                                             
  Enabled (manual-commit)                                                                                                                                                                              
                                                                                                                                                                                                       
  Project, enabled (manual-commit)                                                                                                                                                                     
  Local, enabled (manual-commit)    

Entire-Checkpoint: 7514bb56ca11


Note

Introduces a more informative entire status and consolidates settings loading.

  • Adds --detailed flag to status showing effective state first, then per-file: Project, ... and Local, ...
  • Short status now outputs Enabled/Disabled (strategy) (capitalized), removing source labels; tests updated accordingly
  • Refactors settings handling: new loadSettingsFromFile and applyDefaultStrategy; LoadEntireSettings uses them and merges local overrides
  • Adds helpers formatSettingsStatusShort/formatSettingsStatus; integrates into runStatus and new runStatusDetailed
  • Minor cleanups: remove nolint annotations, small hook no-op return change, and test expectations adjusted

Written by Cursor Bugbot for commit 2559369. This will update automatically on new commits. Configure here.

@gtrrz-victor gtrrz-victor requested a review from a team as a code owner January 27, 2026 02:46
Copilot AI review requested due to automatic review settings January 27, 2026 02:46
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a --long flag to the entire status command that provides detailed status information showing the effective settings plus separate status for project and local settings files. Without the flag, the command shows only the effective (merged) status.

Changes:

  • Added --long boolean flag to status command that shows detailed per-file settings
  • Refactored status output to support both short (effective only) and long (effective + per-file) modes
  • Added loadSettingsFromFile helper function to load settings from individual files

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
cmd/entire/cli/setup.go Added --long flag to status command, split status logic into runStatus (short mode) and runStatusLong (detailed mode), added formatSettingsStatusShort function
cmd/entire/cli/config.go Added loadSettingsFromFile helper function to load settings from a specific file path
cmd/entire/cli/setup_test.go Updated all existing status tests to pass the new long parameter, added comprehensive test coverage for both short and long modes

…roject config

Entire-Checkpoint: 7514bb56ca11
@gtrrz-victor gtrrz-victor force-pushed the gtrrz-victor/improve-status-cmd-output branch from 1d4c494 to 5880bb5 Compare January 27, 2026 03:34
@khaong
Copy link
Contributor

khaong commented Jan 27, 2026

suggestion: --detailed instead of --long?

Copilot AI review requested due to automatic review settings January 27, 2026 04:12
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 6 comments.

Comments suppressed due to low confidence (1)

cmd/entire/cli/setup_test.go:562

  • This test only covers the long mode (long=true on line 546). For consistency with other test pairs like TestRunStatus_Enabled/TestRunStatus_Enabled_Long and TestRunStatus_BothProjectAndLocal/TestRunStatus_BothProjectAndLocal_Short, consider adding a corresponding TestRunStatus_LocalSettingsOnly_Short test or renaming this test to TestRunStatus_LocalSettingsOnly_Long to make it clear it's testing long mode specifically.
func TestRunStatus_LocalSettingsOnly(t *testing.T) {
	setupTestRepo(t)
	writeLocalSettings(t, `{"strategy": "auto-commit", "enabled": true}`)

	var stdout bytes.Buffer
	if err := runStatus(&stdout, true); err != nil {
		t.Fatalf("runStatus() error = %v", err)
	}

	output := stdout.String()
	// Should show effective status first
	if !strings.Contains(output, "Enabled (auto-commit)") {
		t.Errorf("Expected output to show effective 'Enabled (auto-commit)', got: %s", output)
	}
	// Should show per-file details
	if !strings.Contains(output, "Local, enabled") {
		t.Errorf("Expected output to show 'Local, enabled', got: %s", output)
	}
	if strings.Contains(output, "Project,") {
		t.Errorf("Should not show Project settings when only local exists, got: %s", output)
	}
}

gtrrz-victor and others added 2 commits January 27, 2026 15:29
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings January 27, 2026 04:31
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings January 27, 2026 04:38
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

@gtrrz-victor gtrrz-victor changed the title adds --long status command flag that prints diffs between local and project config adds --detailed status command flag that prints diffs between local and project config Jan 27, 2026
Entire-Checkpoint: 28a8bc758709
@gtrrz-victor gtrrz-victor force-pushed the gtrrz-victor/improve-status-cmd-output branch from e728858 to f8eeb9d Compare January 27, 2026 04:47
Copilot AI review requested due to automatic review settings January 27, 2026 22:34
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

khaong and others added 2 commits January 28, 2026 09:51
Copilot AI review requested due to automatic review settings January 27, 2026 22:53
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

gtrrz-victor and others added 2 commits January 28, 2026 10:20
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings January 27, 2026 23:21
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

@gtrrz-victor gtrrz-victor merged commit a02da0f into main Jan 28, 2026
10 checks passed
@gtrrz-victor gtrrz-victor deleted the gtrrz-victor/improve-status-cmd-output branch January 28, 2026 13:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants