Alexander Krotov
1732c3b350
Reduce the scope of clippy exceptions
...
This prevents creation of new overly complex functions.
2020-01-21 14:49:53 +01:00
Alexander Krotov
25842894d2
Rename job::Try into job::Status
2019-12-28 14:35:14 +00:00
Alexander Krotov
fe2011742d
Job error handling refactoring
2019-12-28 14:35:14 +00:00
Alexander Krotov
3f49492ccf
cargo fmt
2019-12-14 22:28:15 +01:00
Alexander Krotov
ad700b45d0
Make Imap.connect() async
2019-12-14 22:25:33 +01:00
B. Petersen
95fbc904d1
go to correct step so that param_autoconfig is actually used
2019-12-14 00:12:14 +01:00
B. Petersen
ce37a8dda2
use provider-database only if the user did not enter a server/port/whatever manually; this allows the user to override erroneous choices
2019-12-14 00:12:14 +01:00
holger krekel
e0499c9552
add preliminary support for offline-autoconfigure for nauta
2019-12-14 00:12:14 +01:00
Alexander Krotov
a7af4685f1
Log IMAP certificate checks configuration
2019-12-08 00:31:22 +01:00
Alexander Krotov
acef386403
Remove useless comment from the configure module
2019-12-03 06:22:05 +00:00
Alexander Krotov
15ba9b6295
Resultify outlk_autodiscover
2019-12-03 06:22:05 +00:00
Alexander Krotov
2f47cf0be5
Resultify moz_autoconfigure
2019-12-03 06:22:05 +00:00
Alexander Krotov
774106fc26
Move read_autoconf_file to its own module
2019-12-03 06:22:05 +00:00
holger krekel
f7f61e0f85
move imap errors into imap module
2019-12-01 20:50:31 +01:00
holger krekel
9d18db9cae
introduce a select_with_uidvalidity function that helps us during configuration to know about last_seen_uid
2019-11-30 23:53:35 +01:00
holger krekel
d14c6ea202
refine uid_next handling and rename and resultify configure_folder to ensure_configurer_folders
2019-11-30 23:53:35 +01:00
holger krekel
7be5fe925a
revert logic to get last_seen_uid
2019-11-30 23:53:35 +01:00
holger krekel
f87cb4231c
rename jobs to make "rg Markseen" and other searches for the job enum produce all places dealing with the enum
2019-11-28 19:42:24 +01:00
Alexander Krotov
430d4e5f6e
Replace DC_CREATE_MVBOX with boolean
2019-11-28 18:24:29 +01:00
holger krekel
a30fa710ad
resultify fetch and simplify fake_idle
2019-11-22 12:28:19 +01:00
holger krekel
eae9ad6f8b
remove context.inbox in favour of a context.inbox_thread following the mvbox_thread and sentbox_thread patterns. Also some streamlining of shutdown logic.
2019-11-22 12:28:19 +01:00
holger krekel
be533fa66a
resultify some imap operations
2019-11-22 12:28:19 +01:00
dignifiedquire
1687e8d26f
it compiles with async-imap, remove local dependency
2019-11-22 12:28:19 +01:00
Alexander Krotov
4732085421
Fix some clippy warnings
2019-11-19 19:52:13 +01:00
Alexander Krotov
f778957caf
Improve documentation and comments
2019-11-16 13:53:47 +01:00
B. Petersen
34f9961857
restore config-param if configure() fails
2019-11-06 22:59:14 +01:00
holger krekel
1cfeb730c3
try to fix some smtp todos and do better error logging
2019-11-03 21:36:01 +01:00
B. Petersen
cde2c9137f
make oauth2.get_addr work
...
oauth2.get_addr is used for gmail-oauth2
to retrieve the address really authorized in the oauth2 process.
2019-10-16 00:57:58 +02:00
holger krekel
1df6229e99
remove/push down some unsafe-fn
2019-10-08 17:37:37 +02:00
holger krekel
a94acef49b
cargo fmt
2019-10-07 13:39:01 +02:00
holger krekel
7f5b362eda
remove ok_to_continue and simplify/refactor imap and smtp connection trying
...
address @r10s review comments and also remove unneccessary "unsafe fn"
2019-10-07 13:39:01 +02:00
holger krekel
51534b2fae
move all alloc/free/stop/has/shall_stop*ongoing* methods to context
...
introduce stop_ongoing to bindings and test for cancelation of configure
2019-10-07 00:55:33 +02:00
Alexander Krotov
1b13107181
Return Option<String> from read_autoconf_file
2019-10-06 05:16:17 +03:00
B. Petersen
93f0f5ccae
rename sql-config-setters to set_raw_config*()
...
the rename is reasonable as the getter is called get_raw_config*()
and to make the functional difference to context.set|get_config() clearer.
2019-10-04 11:18:26 +02:00
B. Petersen
79b92727cc
prefer get_config_bool() where appropriate
...
for db input/output, we still use get_config_int() to convert to/from 0/1.
also for info() we prefer get_config_int() to show the real value.
2019-10-04 11:15:11 +02:00
B. Petersen
dca9afa10b
rename sql.get_config() to sql.get_raw_config() to make clearer that there is not default handling
2019-10-03 17:35:43 +02:00
B. Petersen
c6b2d640ae
prefer context.get_config() over context.sql.get_config() as the latter does not handle default values.
2019-10-03 17:15:40 +02:00
Alexander Krotov
130d485cac
Fix some clippy warnings
2019-10-03 14:30:40 +02:00
Dmitry Bogatov
8f6a0bbf09
Remove unused argument of DC_JOB_CONFIGURE_IMAP
2019-09-22 22:22:00 +02:00
B. Petersen
6a351de4f9
cargo fmt
2019-09-19 18:42:29 +02:00
B. Petersen
bbff1c9c3e
test that bad credentials do not panic
2019-09-19 18:42:29 +02:00
B. Petersen
bbb8144129
do not panic when 0 (=failure) is passed to the progress! macro
2019-09-19 17:00:01 +02:00
dignifiedquire
5486ac5b9f
refacor: use an enum for events
2019-09-15 23:40:08 +02:00
dignifiedquire
f31f341a50
feat: enforce Debug implementations and remove mod types
2019-09-15 16:36:31 +02:00
Alexander Krotov
51bf875826
Use DC_LP_* constants in configure module
2019-09-14 13:22:59 +03:00
Dmitry Bogatov
57daa0f7f0
Remove useless argument of logging macros
...
Previously, logging macros (info! warn! error!) accepted integer
argument (data1), that was passed to callback function verbatim. In all
call sites this argument was 0.
With this change, that data1 argument is no longer part of macro
interface, 0 is always passed to callback in internals of these macros.
2019-09-10 22:26:47 +00:00
Dmitry Bogatov
2dd3f169db
Use set_config_bool instead of set_config_int in boolean context
2019-09-10 22:26:47 +00:00
Dmitry Bogatov
b97b618b4b
Use sql.get_config_bool to simplify dc_is_configured
2019-09-10 22:26:47 +00:00
Dmitry Bogatov
1cdb9c733a
Change return type of `dc_is_configured' to bool
2019-09-10 19:08:55 +00:00
dignifiedquire
f3e53a05a6
refactor(loginparam): rename dc_loginparam -> login_param
2019-09-08 18:48:57 +02:00