Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose commit body #12642

Merged
merged 1 commit into from
Jul 6, 2024
Merged

Expose commit body #12642

merged 1 commit into from
Jul 6, 2024

Conversation

PeskyPotato
Copy link
Contributor

Fixes #10905

Changes

This PR adds Body to the GitInfo struct type to expose the commit message's body as is available in bem/gitmapv1.4.0. If no commit body is present an empty string is returned.

Docs have been updated with the new parameter, I've included an email of the output as well.

Tests

No tests were added for this feature. I ran mage check after installing asciidoctor and there was no output, I assume this is good?

go test -run '' passes all tests.

I tested this against a local test site and it works as expected.

@PeskyPotato
Copy link
Contributor Author

PeskyPotato commented Jul 5, 2024

source and docs commit merged into one. af490d4

source/fileInfo.go Outdated Show resolved Hide resolved
Updated bep/gitmap to v1.4.0, to get commit message's Body.
Added Body to GitInfo struct. Docs upated with commit body example.

Fixes gohugoio#10905
@bep bep self-requested a review July 6, 2024 12:08
@bep bep merged commit 0ee2610 into gohugoio:master Jul 6, 2024
7 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.

Full Commit Message in .GitInfo
2 participants