Description
In a conversation, the "revert message" is actually reverting code, which is not said clearly or prompted with a warning. This is still okay since the user can revert the revert feature, until I accidentally clicked revert on an old conversation, which somehow broke my Git, resulting several files missing despite executing Git hard reset.
Currently I just learned to never use revert anymore to prevent damages like this, which is also not ideal.
There are several fixes may be applied:
- Prompt user with warning that revert conversation actually reverts code
- Separate "revert message" with "revert changes" (user can choose only revert conversation without reverting code)
- Remove "revert changes" entirely, since some changes are still good and can be carried to another conversation session
Plugins
None were used
OpenCode version
1.16.2
Steps to reproduce
- Go to a project that has multiple git commits with many session conversations
- Go to a rather old conversation
- In the old conversation, scroll up to an early dialog with file changes
- Click "Revert message", which messes your project up even with Git commits, mostly are deleted files
Description
In a conversation, the "revert message" is actually reverting code, which is not said clearly or prompted with a warning. This is still okay since the user can revert the revert feature, until I accidentally clicked revert on an old conversation, which somehow broke my Git, resulting several files missing despite executing Git hard reset.
Currently I just learned to never use revert anymore to prevent damages like this, which is also not ideal.
There are several fixes may be applied:
Plugins
None were used
OpenCode version
1.16.2
Steps to reproduce