Add an occ mail:account:update command
Additional occ command
The occ mail:account:update command can be used to update a single parameter or several at once using the desired input option.
Usage
Requires two arguments, to identify the account you want to edit:
- user-id
- name
Accepts all options included in mail:account:create eg: --imap-host --imap-port --imap-ssl-mode --imap-user --imap-password --smtp-host --smtp-port --smtp-ssl-mode --smtp-user --smtp-password
eg:
occ mail:account:update
Why
It can happen that some email's setting ( smtp servername, port, password...) changes in the course of time. It would be useful to be able to apply these new settings while preserving the parameters that remain unaffected.
In large installations, if you were to change a connection parameter to the company mail server, it would be wasteful to do this manually or by deleting and recreating accounts.
Thanks for opening your first pull request in this repository! :v:
Thanks so much for updating your PR, it looks good! I'm not sure I will get to it this week but I will make sure to test your code as soon as possible. Great work!
Thanks so much for updating your PR, it looks good! I'm not sure I will get to it this week but I will make sure to test your code as soon as possible. Great work!
Great. Thank you so much. No rush for us.
@MaadixNet friendly ping on the requested changes above
Hey, please don't merge this yet; since the design of this PR has changed a bit, it'd probably be a mistake to merge it without the ability to change the name and the email for a particular account.
Sending patch via email so submitter can update it.
Hey, please don't merge this yet; since the design of this PR has changed a bit, it'd probably be a mistake to merge it without the ability to change the name and the email for a particular account.
Sending patch via email so submitter can update it.
Pushed changes to include name field in command
Hey, this is still missing the email argument, should be there tomorrow IIUC.
Hi, Now it should be ready. All arguments included.
Psalm needs a baseline entry similar to https://github.com/nextcloud/mail/blob/8352d8acf08d1dbb5e203667999548b9f7795719/tests/psalm-baseline.xml#L46-L50 so it stops reporting the unknown Symfony command class
Thanks everyone! :heart:
Thank you very much !!
Hello, I noticed that this MR is not included in the v1.15.0 line which is the latest for e.g. NC 24, is that expected? I noticed it is availble in v1.12.8 and in v2.X lines.
Cheers,