4 * This is split up from the rest of git so that we might do
5 * something different on Windows, for example.
8 static void run_pager(const char *pager)
10 execlp(pager, pager, NULL);
11 execl("/bin/sh", "sh", "-c", pager, NULL);
14 void setup_pager(void)
18 const char *pager = getenv("PAGER");
24 else if (!*pager || !strcmp(pager, "cat"))
36 /* return in the child */
44 /* The original process turns into the PAGER */
49 setenv("LESS", "-S", 0);
51 die("unable to execute pager '%s'", pager);