rejeep / prodigy.el

Manage external services from within Emacs
GNU General Public License v3.0
552 stars 39 forks source link

Add prodigy-clear-buffer command #44

Closed shosti closed 10 years ago

shosti commented 10 years ago

Closes #42.

I ended up deciding that k with an optional confirmation is probably safer and more intuitive than h k, since lots of modes use k for destructive operations. (Also, view-mode keybindings are surprisingly hard to override).

rejeep commented 10 years ago

Good call on the binding!

A few comments:

The mode map prodigy-view-mode-map does not exist.

I think that eventually, Prodigy view mode will have a decent feature set, so I think it would make sense to prefix functions with prodigy-view, for example prodigy-view-clear-buffer.

Related to the previous comment, I think we should collect all view functions under a specific section, for example:

  ^L
  ;;;; View mode functions
  ...
shosti commented 10 years ago

OK, PR updated. I think define-derived-mode automatically creates a keymap, but you're right that for clarity it's probably better to define it with defvar.

shosti commented 10 years ago

I added a really simple feature test as well;

rejeep commented 10 years ago

Great, thanks, merged!

I think define-derived-mode automatically creates a keymap

Ahh, ok, didn't know that.