Mercurial > vim
comparison src/option.c @ 161:6df0106fc595
updated for version 7.0049
author | vimboss |
---|---|
date | Mon, 07 Feb 2005 22:01:03 +0000 |
parents | 72aefd4c1e0d |
children | 8b0ee9d57d7f |
comparison
equal
deleted
inserted
replaced
160:7c0820eed232 | 161:6df0106fc595 |
---|---|
2591 /* Be Vi compatible by default */ | 2591 /* Be Vi compatible by default */ |
2592 p_cp = TRUE; | 2592 p_cp = TRUE; |
2593 | 2593 |
2594 /* | 2594 /* |
2595 * Find default value for 'shell' option. | 2595 * Find default value for 'shell' option. |
2596 * Don't use it if it is empty. | |
2596 */ | 2597 */ |
2597 if ((p = mch_getenv((char_u *)"SHELL")) != NULL | 2598 if (((p = mch_getenv((char_u *)"SHELL")) != NULL && *p != NUL) |
2598 #if defined(MSDOS) || defined(MSWIN) || defined(OS2) | 2599 #if defined(MSDOS) || defined(MSWIN) || defined(OS2) |
2599 # ifdef __EMX__ | 2600 # ifdef __EMX__ |
2600 || (p = mch_getenv((char_u *)"EMXSHELL")) != NULL | 2601 || ((p = mch_getenv((char_u *)"EMXSHELL")) != NULL && *p != NUL) |
2601 # endif | 2602 # endif |
2602 || (p = mch_getenv((char_u *)"COMSPEC")) != NULL | 2603 || ((p = mch_getenv((char_u *)"COMSPEC")) != NULL && *p != NUL) |
2603 # ifdef WIN3264 | 2604 # ifdef WIN3264 |
2604 || (p = default_shell()) != NULL | 2605 || ((p = default_shell()) != NULL && *p != NUL) |
2605 # endif | 2606 # endif |
2606 #endif | 2607 #endif |
2607 ) | 2608 ) |
2608 set_string_default("sh", p); | 2609 set_string_default("sh", p); |
2609 | 2610 |
2610 #ifdef FEAT_WILDIGN | 2611 #ifdef FEAT_WILDIGN |
2611 /* | 2612 /* |
2612 * Set the default for 'backupskip' to include environment variables for | 2613 * Set the default for 'backupskip' to include environment variables for |