Hacked a bit Thursday and this weekend and put together Hotwire 0.444. For the impatient, you can skip directly to the Google Group and download. The cool thing about this release is that it has initial undo support. I’ll talk more about that in a minute.
I think in general, there are 3 possible reasons you might add a modal dialog that requires a user action or choice to your application.
- Need username/password – Ok, but you better remember what I type.
- List infos – Things like the Eclipse new-class dialog. This one could be done inline too but it’s mostly fine as a dialog.
- It’s probably wrong – everything else.
In particular, I often notice that where a lot of the confirmation type dialogs (“Do you really want to foo?”) are used, it would make more sense to just do what I asked, and if it wasn’t what I really wanted, allow me to undo.
I am going to take a relatively extreme (and topical) example here; the default Fedora root .bashrc which has alias rm='rm -i'.
Is there a better way? Yes.
Click to undo!
This took all of maybe 20 minutes to implement for the cd and rm commands; it should be relatively straightforward to add undo support to Hotwire’s builtin mv command, and cp will likely have it once it’s written.
Some other new features for this release:
For more details, see the Google group post.