Skip to content

Add GitHub Action to check image upload sizes - #857

Closed
rahulsunil2 wants to merge 2 commits into
openfga:mainfrom
rahulsunil2:rahulsunil2/limit-image-size
Closed

rahulsunil2 wants to merge 2 commits into
openfga:mainfrom
rahulsunil2:rahulsunil2/limit-image-size

Conversation

@rahulsunil2

@rahulsunil2 rahulsunil2 commented Sep 30, 2024

Copy link
Copy Markdown

Add GitHub Action to check image upload sizes

Description

This PR introduces a new GitHub Action workflow that automatically checks the size of image files (jpg, jpeg, png, gif) uploaded in pull requests. The workflow enforces a maximum file size limit of 5MB for all new or modified images. If any image exceeds this limit, the workflow will fail and provide a list of oversized images, helping to maintain repository size and ensure efficient loading of images in the project.

Key features of this workflow:

  • Triggers on pull requests that modify image files
  • Checks only new or modified images
  • Enforces a 5MB size limit (configurable via environment variable)
  • Provides clear error messages with file names and sizes for any oversized images
  • Allows the workflow to pass if all images are within the size limit

References

Review Checklist

  • I have clicked on "allow edits by maintainers".
  • I have added documentation for new/changed functionality in this PR or in a PR to openfga.dev [Provide a link to any relevant PRs in the references section above]
  • The correct base branch is being used, if not main
  • I have added tests to validate that the change in functionality is working as expected

@rahulsunil2
rahulsunil2 requested review from a team as code owners September 30, 2024 19:07
@linux-foundation-easycla

linux-foundation-easycla Bot commented Sep 30, 2024

Copy link
Copy Markdown

CLA Signed


The committers listed above are authorized under a signed CLA.

@rahulsunil2

Copy link
Copy Markdown
Author

This fixes: #633

@curfew-marathon

Copy link
Copy Markdown
Contributor

This PR has had no human activity for 90 days, so it has been marked lifecycle/stale.

This is automated backlog grooming, not a judgment on the work.

What happens next, unless there is activity:

  • In 30 days, it will move to lifecycle/closing-soon
  • 30 days after that, it will be closed

To keep it open, push a commit or leave a comment, and the clock will reset. For work that should not auto-close, such as an RFC or long-running experiment, ask a maintainer to add lifecycle/frozen.

@curfew-marathon curfew-marathon added the lifecycle/stale No human activity in 90 days label Jul 3, 2026
@curfew-marathon

Copy link
Copy Markdown
Contributor

This PR has had no human activity for 30 days since being marked lifecycle/stale, so it has now been marked lifecycle/closing-soon.

It will be closed in 30 days unless there is new activity.

If the work still matters, this is the moment to say so: leave a comment, push a commit, or ask a maintainer to add lifecycle/frozen if it should be kept open long-term.

If this work is no longer being pursued, no action is needed.

@curfew-marathon curfew-marathon added lifecycle/closing-soon Final warning before auto-close and removed lifecycle/stale No human activity in 90 days labels Aug 8, 2026
@curfew-marathon

Copy link
Copy Markdown
Contributor

Closing this after 60 days with no human activity since it was marked lifecycle/stale.

This is housekeeping, not a verdict on the change. The work is not lost: if it is still relevant, you can ask for this PR to be reopened or open a fresh PR.

Thanks for putting the time in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lifecycle/closing-soon Final warning before auto-close

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants