]> granicus.if.org Git - neomutt/commit
Unsubscribe after deleting an imap folder (#730)
authorseishinryohosha <seishinryohosha@users.noreply.github.com>
Fri, 22 Sep 2017 14:51:19 +0000 (16:51 +0200)
committerPietro Cerutti <gahr@gahr.ch>
Fri, 22 Sep 2017 14:51:19 +0000 (15:51 +0100)
commit9dc0ee067b71fc7678128bebe0b2fd30c9b3dd2d
treeb4a0e745dbec799b095a30fe62351d52b532f1f2
parent3e7a21f3b6853b6b7515eccba1c7acd63d265a1a
Unsubscribe after deleting an imap folder (#730)

* Unsubscribe after deleting an imap folder

Only added two line to `browser.c` in `_mutt_select_file` case `OP_DELETE_MAILBOX`.

* Fixed typo: Unsubsribe -> Unsubscribe

* Revert previous change

* Added unsubscribe-from command

* Added `unsubscribe-from` command (init.h)
* Added `parse_unsubscribe_from` prototype (init.h)
* Implemented `parse_unsubscribe_from` uses imap/imap.h Header (init.c)

Tokenize buffer and expand each token (path) and finally unsubscribe from it.
No pattern matching is done.

* Unsubscribe after deleting an imap folder

Only added two line to `browser.c` in `_mutt_select_file` case `OP_DELETE_MAILBOX`.

* Fixed typo: Unsubsribe -> Unsubscribe

* Revert previous change

* Added unsubscribe-from command

* Added `unsubscribe-from` command (init.h)
* Added `parse_unsubscribe_from` prototype (init.h)
* Implemented `parse_unsubscribe_from` uses imap/imap.h Header (init.c)

Tokenize buffer and expand each token (path) and finally unsubscribe from it.
No pattern matching is done.

* Unsubscribe after deleting an imap folder

Only added two line to `browser.c` in `_mutt_select_file` case `OP_DELETE_MAILBOX`.

* Fixed typo: Unsubsribe -> Unsubscribe

* Revert previous change

* Unsubscribe after deleting an imap folder

Only added two line to `browser.c` in `_mutt_select_file` case `OP_DELETE_MAILBOX`.

* Fixed typo: Unsubsribe -> Unsubscribe

* Revert previous change

* Added unsubscribe-from command

* Added `unsubscribe-from` command (init.h)
* Added `parse_unsubscribe_from` prototype (init.h)
* Implemented `parse_unsubscribe_from` uses imap/imap.h Header (init.c)

Tokenize buffer and expand each token (path) and finally unsubscribe from it.
No pattern matching is done.

* Added subscribe-to command and updated example

    * Added `subscribe-to` command (init.h)
    * Added `parse_subscribe_to` prototype (init.h)
    * Implemented `parse_subscribe_to` uses imap/imap.h Header (init.c)
    * Example now shows folder and subfolders

    Tokenize buffer and expand each token (path) and finally subscribe from it.
    No pattern matching is done.

* Added return check
It should be noted, that imap_subscribe(FOO, 0) /* unsubcribe */
won't return -1, if mailbox doesn't exists.

* Added return -1, and do not silently ignore

* Added braces to satisfy styleguides

* Added better user output

* Typo Successfull -> Successful

* Reverted back to one parameter only and errors into err.

* Reverted back to one parameter only.
* Better error messages
* Error messages are now stored inside struct Buffer *err

* Changed from strfcpy -> mutt_buffer_*

* Copy&Paste Error correction

* Cleanup

* set expandtab
* set tabstop=2
* merged mutt_buffer_addstr -> mutt_buffer_printf
* corrected "Corrupted buffer" -> mutt_debug(5, ...)
* Compared with clang-format to get sure

* Reverted back bool -> int, to change this in a later PR

inside `parse_unsubscribe_from(...)` and `parse_subscribe_to(...)`
for the `imap_subscribe(...)`-call.
init.c
init.h