Re: [PATCH v3 7/7] send-email: suppress leading and trailing whitespaces before alias expansion

2015-06-10 Thread Matthieu Moy
Remi Lespinet remi.lespi...@ensimag.grenoble-inp.fr writes: As alias file formats supported by git send-email doesn't take whitespace into account, it is useless to consider whitespaces in alias name. remove leading and trailing whitespace before expanding s/remove/Remove/ allow to

[PATCH v3 7/7] send-email: suppress leading and trailing whitespaces before alias expansion

2015-06-10 Thread Remi Lespinet
Matthieu Moy matthieu@grenoble-inp.fr writes: Actually, once you have this, PATCH 6/7 becomes useless, right? (at least, the test passes if I revert it) It seems to me that doing this space trimming just once, inside or right after split_at_commas would be clearer. You're right, I put

[PATCH v3 7/7] send-email: suppress leading and trailing whitespaces before alias expansion

2015-06-10 Thread Remi Lespinet
Matthieu Moy matthieu@grenoble-inp.fr writes: Junio C Hamano gits...@pobox.com writes: Remi Lespinet remi.lespi...@ensimag.grenoble-inp.fr writes: I agree, I'd like to put it right after split_at_commas in a separate function trim_list. Is it a good idea even if the function is one

Re: [PATCH v3 7/7] send-email: suppress leading and trailing whitespaces before alias expansion

2015-06-10 Thread Junio C Hamano
Matthieu Moy matthieu@grenoble-inp.fr writes: Junio C Hamano gits...@pobox.com writes: Remi Lespinet remi.lespi...@ensimag.grenoble-inp.fr writes: I agree, I'd like to put it right after split_at_commas in a separate function trim_list. Is it a good idea even if the function is one

Re: [PATCH v3 7/7] send-email: suppress leading and trailing whitespaces before alias expansion

2015-06-10 Thread Matthieu Moy
Junio C Hamano gits...@pobox.com writes: Remi Lespinet remi.lespi...@ensimag.grenoble-inp.fr writes: I agree, I'd like to put it right after split_at_commas in a separate function trim_list. Is it a good idea even if the function is one line long ? Hmph, if I have A, B, C and call a

Re: [PATCH v3 7/7] send-email: suppress leading and trailing whitespaces before alias expansion

2015-06-10 Thread Matthieu Moy
Junio C Hamano gits...@pobox.com writes: Matthieu Moy matthieu@grenoble-inp.fr writes: Junio C Hamano gits...@pobox.com writes: Hmph, if I have A, B, C and call a function that gives an array of addresses, treating the input as comma-separated addresses, I would expect (A, B, C) to be

Re: [PATCH v3 7/7] send-email: suppress leading and trailing whitespaces before alias expansion

2015-06-10 Thread Junio C Hamano
Remi Lespinet remi.lespi...@ensimag.grenoble-inp.fr writes: I agree, I'd like to put it right after split_at_commas in a separate function trim_list. Is it a good idea even if the function is one line long ? Hmph, if I have A, B, C and call a function that gives an array of addresses,

[PATCH v3 7/7] send-email: suppress leading and trailing whitespaces before alias expansion

2015-06-09 Thread Remi Lespinet
As alias file formats supported by git send-email doesn't take whitespace into account, it is useless to consider whitespaces in alias name. remove leading and trailing whitespace before expanding allow to recognize strings like alias or alias\t passed by --to, --cc, --bcc options or by the git