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

Improve the --force flag on the php hyde publish:homepage command #67

Closed
caendesilva opened this issue Apr 7, 2022 · 3 comments · Fixed by #84
Closed

Improve the --force flag on the php hyde publish:homepage command #67

caendesilva opened this issue Apr 7, 2022 · 3 comments · Fixed by #84
Assignees

Comments

@caendesilva
Copy link
Member

Right now you always need to supply the --force flag on the php hyde publish:homepage command, even on new installations.

This is a bit jarring and could be improved using the principle of least astonishment. The reason the force flag is there to protect against accidental overrides, however it does not really matter if you override a default page. I suggest we start keeping a JSON cache of default file hashes. When running the publish command, we compare the hash of the current file. If it matches any of the default files we can force the publish. Otherwise, we add a notice to let the user know why their file was not published, and that they can use --force.

@caendesilva
Copy link
Member Author

@caendesilva caendesilva self-assigned this Apr 9, 2022
@caendesilva
Copy link
Member Author

@caendesilva
Copy link
Member Author

Fixed in upcoming PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant