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

Add a test for PRs that change README without updating the man page #243

Open
sparr opened this issue Jun 21, 2023 · 1 comment · May be fixed by #245
Open

Add a test for PRs that change README without updating the man page #243

sparr opened this issue Jun 21, 2023 · 1 comment · May be fixed by #245

Comments

@sparr
Copy link
Contributor

sparr commented Jun 21, 2023

Changes to README.rst require make man to update the man page in git-secrets.1. We should have a github action check that fails if a PR modifies one but not the other.

ginglis13 added a commit to ginglis13/git-secrets that referenced this issue Oct 10, 2023
Adds a check to CI on changes to either README.rst or git-secrets.1 that
will fail if changes are made to one but not the other.

Fixes: awslabs#243

Signed-off-by: ginglis13 <[email protected]>
ginglis13 added a commit to ginglis13/git-secrets that referenced this issue Oct 10, 2023
Adds a check to CI on changes to either README.rst or git-secrets.1 that
will fail if changes are made to one but not the other.

Also update action/checkout to v4

Fixes: awslabs#243

Signed-off-by: ginglis13 <[email protected]>
@ginglis13 ginglis13 linked a pull request Oct 10, 2023 that will close this issue
ginglis13 added a commit to ginglis13/git-secrets that referenced this issue Oct 10, 2023
Adds a check to CI on changes to either README.rst or git-secrets.1 that
will fail if changes are made to one but not the other.

Also update action/checkout to v4

Fixes: awslabs#243

Signed-off-by: ginglis13 <[email protected]>
@peterklein2024
Copy link

name: Check Man Page Update
on:
pull_request:
paths: [README.rst, 'man/git-secrets.1']
jobs:
check-man-page:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2; with: python-version: '3.x'
- run: pip install -r requirements.txt; diff=$(git diff --name-only ${{ github.event.before }} ${{ github.sha }} | grep -E 'README.rst|man/git-secrets.1' || true); [ -n "$diff" ] && { echo "Error: Changes to README.rst or man/git-secrets.1 require corresponding updates in the other file."; exit 1; }
did this with my site hope it helps u

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 a pull request may close this issue.

2 participants