-
-
Notifications
You must be signed in to change notification settings - Fork 53
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
Adapt Shield's email2FA in Bonfire2 #501
Adapt Shield's email2FA in Bonfire2 #501
Conversation
For existing projects, this will also mean updating manually app/Config/Auth.php If you fail to do that and turn on the 2FA, you will get locked out of the website. To solve the problem, you will have to issue this command on db: DELETE FROM settings WHERE class="Config\Auth" AND key="actions" Does this count as breaking change, and should it be mentioned in the CHANGELOG, I wonder? |
I would definitely add a note about the breaking change on this. I would love to get this repo to a point where we can get an official 1.0 out. And then start actual versions, but I don't have an ounce of free time lately. |
@lonnieezell, I am thinking about a partial solution to breaking updates: have composer create a file in the project on install/update with last update date, and then add a php file that would be executed on composer update, where we could put time-based messages to be printed by composer, so user knows he needs to do something manually. I am thinking of adding this to scripts in composer.json: "post-update-cmd": [
"php post-update-messages.php"
] and then a file // Set the cutoff date or commit hash
$cutoffDate = new DateTime('2025-01-01 00:00:00');
$lastUpdateFile = 'last-update.txt';
// Check if the last update file exists
if (file_exists($lastUpdateFile)) {
$lastUpdateDate = new DateTime(file_get_contents($lastUpdateFile));
if ($lastUpdateDate >= $cutoffDate) {
// Exit if the last update was after the cutoff date
exit(0);
}
}
// Display the warning message
echo "Warning: After this update, you need to do some manual changes (like copying theme files or editing config files). Please see [documentation link] for details ....\n";
// Update the last update file
file_put_contents($lastUpdateFile, (new DateTime())->format(DateTime::ATOM)); Do you see any drawbacks to such approach? I think we could even automate this somehow, so that the script reads the dates from the file with breaking changes, so we do not need to specify the cutoffDate manually. |
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.
Needed:
- documentation update;
- (prior to this) script to inform users of breaking changes at the end of
composer update
run
8b7a0a9
to
fb5dbd9
Compare
Finishes the incomplete implementation in pr #416, fixes #352