Skip to content

Add a step for syncing README.md to Docker Hub in container-image.yml #8

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

yhabteab
Copy link
Member

@yhabteab yhabteab commented Aug 5, 2025

@yhabteab yhabteab requested a review from julianbrost August 5, 2025 12:10
@cla-bot cla-bot bot added the cla/signed CLA is signed by all contributors of a PR label Aug 5, 2025
@yhabteab yhabteab force-pushed the sync-image-readme-md branch 3 times, most recently from 6454960 to 907df68 Compare August 5, 2025 13:07
@yhabteab yhabteab changed the title Add a reusable GHA for syncing README.md to Docker Hub Add a step for syncing README.md to Docker Hub in container-image.yml Aug 5, 2025
@yhabteab yhabteab force-pushed the sync-image-readme-md branch from 907df68 to c3615ec Compare August 5, 2025 13:24

# Check if the README file has been modified since the github.event.before reference point
# and write the result to the README_MODIFIED ENV variable.
if git diff --quite --exit-code ${{ github.event.before }} "${{ env.README_FILEPATH }}"; then

Choose a reason for hiding this comment

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

Suggested change
if git diff --quite --exit-code ${{ github.event.before }} "${{ env.README_FILEPATH }}"; then
if git diff --quiet --exit-code ${{ github.event.before }} "${{ env.README_FILEPATH }}"; then

Also, aren't the cases the wrong way around? Exit code 0 (i.e. true) means no difference.

@julianbrost
Copy link

Other idea (originating from Icinga/icinga2#10505 (comment)): The documentation mostly describes the latest tag, like the examples refer to something like icinga/icinga2 (implicitly :latest), so what about syncing when uploading that tag (i.e. on: release) instead of for pushes to the default branch?

@yhabteab yhabteab force-pushed the sync-image-readme-md branch from c3615ec to cadb12d Compare August 8, 2025 11:52
@yhabteab yhabteab requested a review from julianbrost August 8, 2025 11:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla/signed CLA is signed by all contributors of a PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants