+static void madmutt_init_shell(char *buf, ssize_t len)
+{
+ struct passwd *pw = getpwuid(getuid());
+
+ if (pw) {
+ m_strcpy(buf, len, pw->pw_shell);
+ _mutt_expand_path(buf, len, pw->pw_shell, 0);
+ } else {
+ m_strcpy(buf, len, getenv("SHELL") ?: "/bin/sh");
+ }
+}
+
+static const struct {
+ const char *key;
+ void (*fun)(char *buf, ssize_t len);
+} madmutt_module_vars2[] = {
+ { "shell", madmutt_init_shell },
+ /*
+ ** .pp
+ ** Command to use when spawning a subshell. By default, the user's login
+ ** shell from \fT/etc/passwd\fP is used.
+ */
+};
+