* Read a GIT_AUTHOR_NAME, GIT_AUTHOR_EMAIL AND GIT_AUTHOR_DATE from a * file with shell quoting into struct strvec. Returns -1 on * error, 0 otherwise. */
| 1024 | * error, 0 otherwise. |
| 1025 | */ |
| 1026 | static int read_env_script(struct strvec *env) |
| 1027 | { |
| 1028 | char *name, *email, *date; |
| 1029 | |
| 1030 | if (read_author_script(rebase_path_author_script(), |
| 1031 | &name, &email, &date, 0)) |
| 1032 | return -1; |
| 1033 | |
| 1034 | strvec_pushf(env, "GIT_AUTHOR_NAME=%s", name); |
| 1035 | strvec_pushf(env, "GIT_AUTHOR_EMAIL=%s", email); |
| 1036 | strvec_pushf(env, "GIT_AUTHOR_DATE=%s", date); |
| 1037 | free(name); |
| 1038 | free(email); |
| 1039 | free(date); |
| 1040 | |
| 1041 | return 0; |
| 1042 | } |
| 1043 | |
| 1044 | static char *get_author(const char *message) |
| 1045 | { |
no test coverage detected