mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Update the email regex so it accept the '+' sign. Fix https://github.com/YunoHost/issues/issues/1333.
This commit is contained in:
parent
c7347ef04f
commit
69e20fa114
1 changed files with 11 additions and 5 deletions
|
@ -100,6 +100,12 @@ user:
|
|||
-m:
|
||||
full: --mail
|
||||
help: (Deprecated, see --domain) Main unique email address
|
||||
extra:
|
||||
ask: ask_email
|
||||
required: True
|
||||
pattern: &pattern_email_without_plus
|
||||
- !!str ^[\w.-]+@([^\W_A-Z]+([-]*[^\W_A-Z]+)*\.)+([^\W\d_]{2,})$
|
||||
- "pattern_email_without_plus"
|
||||
-p:
|
||||
full: --password
|
||||
help: User password
|
||||
|
@ -158,9 +164,7 @@ user:
|
|||
-m:
|
||||
full: --mail
|
||||
extra:
|
||||
pattern: &pattern_email
|
||||
- !!str ^[\w.-]+@([^\W_A-Z]+([-]*[^\W_A-Z]+)*\.)+((xn--)?[^\W_]{2,})$
|
||||
- "pattern_email"
|
||||
pattern: *pattern_email_without_plus
|
||||
-p:
|
||||
full: --change-password
|
||||
help: New password to set
|
||||
|
@ -172,7 +176,9 @@ user:
|
|||
nargs: "*"
|
||||
metavar: MAIL
|
||||
extra:
|
||||
pattern: *pattern_email
|
||||
pattern: &pattern_email
|
||||
- !!str ^[\w\+.-]+@([^\W_A-Z]+([-]*[^\W_A-Z]+)*\.)+([^\W\d_]{2,})$
|
||||
- "pattern_email"
|
||||
--remove-mailforward:
|
||||
help: Mailforward addresses to remove
|
||||
nargs: "*"
|
||||
|
@ -182,7 +188,7 @@ user:
|
|||
nargs: "*"
|
||||
metavar: MAIL
|
||||
extra:
|
||||
pattern: *pattern_email
|
||||
pattern: *pattern_email_without_plus
|
||||
--remove-mailalias:
|
||||
help: Mail aliases to remove
|
||||
nargs: "*"
|
||||
|
|
Loading…
Add table
Reference in a new issue