howl icon indicating copy to clipboard operation
howl copied to clipboard

Feature Request: Save file from buffer list

Open Janfel opened this issue 4 years ago • 1 comments

As you can close a buffer from the buffer list with Ctrl+w, it would be nice to also be able to save it with Ctrl+s. This seems to be a perfect fit for being implemented on top of the changes proposed in issue #331.

Janfel avatar Aug 22 '19 23:08 Janfel

I was looking into this and realized there's some inconsistency in how close and save are implemented. Specifically close_buffer is available on the howl.app but save_buffer isn't. It is implemented as a command where the interaction happens in input and handler. However for close the interaction happens in app\close_buffer so the command is just:

   handler: ->
    buffer = app.editor.buffer
    app\close_buffer buffer

This makes it simple to call app\close_buffer from inside the buffer list interaction. I think for consistency we should first add the save_buffer and save_buffer_as to app.

shalabhc avatar Oct 25 '19 13:10 shalabhc