Skip to content

Expose buildinfo so it can be used in, for example, api.pi4j.com#617

Merged
FDelporte merged 8 commits into
developfrom
expose-buildinfo
Feb 25, 2026
Merged

Expose buildinfo so it can be used in, for example, api.pi4j.com#617
FDelporte merged 8 commits into
developfrom
expose-buildinfo

Conversation

@FDelporte
Copy link
Copy Markdown
Member

No description provided.

Copy link
Copy Markdown

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 pull request refactors the internal build information logging functionality to expose it as a public API through a BuildInfo record. This enables external applications (e.g., api.pi4j.com) to programmatically access Pi4J library build information including branch, commit ID, version, and timestamp.

Changes:

  • Introduced a public BuildInfo record to encapsulate build information (branch, commit ID, version, timestamp)
  • Refactored getBuildInfo() from a private logging method to a public method that returns a BuildInfo instance
  • Added a log() method to the BuildInfo record to maintain existing logging behavior

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pi4j-core/src/main/java/com/pi4j/Pi4J.java Outdated
Comment thread pi4j-core/src/main/java/com/pi4j/Pi4J.java Outdated
Copy link
Copy Markdown
Contributor

Copilot AI commented Feb 24, 2026

@FDelporte I've opened a new pull request, #618, to work on those changes. Once the pull request is ready, I'll request review from you.

Copilot AI and others added 3 commits February 24, 2026 15:51
Comment thread pi4j-core/src/main/java/com/pi4j/Pi4J.java
@FDelporte FDelporte merged commit 04bcebe into develop Feb 25, 2026
4 checks passed
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.

5 participants