Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 18, 2025

Plan: Address PR Review Comments

  • Cache FormatDueDate and FormatAbsoluteDeadline calls to avoid redundant formatting
  • Add test cases for overdue goals (past dates/times)
  • Add test cases for year boundary edge cases (Dec 31 -> tomorrow)

Summary

All review comments have been addressed:

  1. Cached formatting calls - Pre-calculate formatted values to avoid calling FormatDueDate twice per goal
  2. Added overdue test cases - Tests for goals overdue by hours, days, and weeks
  3. Added year boundary test cases - Tests for Dec 31 -> Jan 1 transitions and cross-year scenarios

All tests pass (17 new test cases added).

Original prompt

Currently buzz today and tomrrow commands output a relative deadline column. Let's add an absolute deadline column too.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 18, 2025

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.


Comment @coderabbitai help to get the list of available commands and usage tips.

Copilot AI changed the title [WIP] Add absolute deadline column to buzz commands feat: add absolute deadline column to today and tomorrow commands Dec 18, 2025
Copilot AI requested a review from narthur December 18, 2025 21:18
@narthur narthur marked this pull request as ready for review December 18, 2025 21:59
Copilot AI review requested due to automatic review settings December 18, 2025 21:59
@github-actions
Copy link

github-actions bot commented Dec 18, 2025

🚀 Pre-release Build Ready

Test builds are ready! Install directly using the bin command:

# Install the pre-release
bin install https://github.com/PinePeakDigital/buzz/releases/tag/pr-198-latest buzz-pr-198
# Run the pre-release
buzz-pr-198
# Uninstall the pre-release
bin remove buzz-pr-198

Direct Download Links

Or download binaries directly from the pre-release page:

💡 No GitHub login required for downloads!

🗑️ This pre-release will be automatically deleted when the PR is closed.

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 enhances the buzz today and buzz tomorrow commands by adding an absolute deadline column alongside the existing relative deadline, making it easier for users to see both how much time remains and the exact date/time when goals are due.

Key changes:

  • Added FormatAbsoluteDeadline() function with context-aware formatting (time-only for today, "tomorrow" prefix for tomorrow, date+time for future dates)
  • Updated handleFilteredCommand() to calculate and display a fourth column with proper alignment
  • Added comprehensive test coverage for the new formatting function

Reviewed changes

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

File Description
beeminder.go Implements FormatAbsoluteDeadline() and FormatAbsoluteDeadlineAt() functions with timezone-aware date/time formatting logic
beeminder_test.go Adds TestFormatAbsoluteDeadline with test cases covering today, tomorrow, and future date formatting scenarios
main.go Updates handleFilteredCommand() to calculate column width for relative deadlines and add absolute deadline as fourth column
README.md Updates documentation and examples to show the new absolute deadline column in command outputs

@narthur
Copy link
Collaborator

narthur commented Dec 19, 2025

@copilot apply changes based on the comments in this thread

Copilot AI requested a review from narthur December 19, 2025 17:25
@narthur narthur merged commit fdfae5f into main Dec 22, 2025
2 checks passed
@narthur narthur deleted the copilot/add-absolute-deadline-column branch December 22, 2025 16:07
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