-
Notifications
You must be signed in to change notification settings - Fork 1.3k
feat(cli): Add check-client command to verify bundle freshness #7517
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
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 449eb30 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
commit: |
built with Refined Cloudflare Pages Action⚡ Cloudflare Pages Deployment
|
0856f08
to
b4c6899
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, good start, but it needs to be quiet and fast, and not fancy in any way.
@wmertens I refactored code, it seems to look much better right now |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking a lot better, but can be even cleaner :)
Move all check-client related functions and constants into a single index.ts file to improve maintainability and reduce file fragmentation
Modify the check-client command to accept `src` and `dist` as arguments instead of hardcoding them. This change enhances flexibility and allows for more dynamic usage of the command across different adapters. The corresponding build scripts in various adapters' `package.json` files have been updated to pass these arguments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
starting to look really nice!
Remove redundant log steps and improve error handling in the client check process. This change focuses on reducing noise in the logs and ensuring clearer error messages.
@wmertens done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
almost there! 👍
done |
The function name `isNewerThan` was renamed to `hasNewer` to better reflect its purpose of checking if any files in the directory are newer than the given timestamp. This improves code readability and understanding.
What is it?
fixes: #7479
This commit adds a new CLI command that checks if the client bundle is up-to-date by:
Description
Checklist
pnpm change