mirror of
https://github.com/vim/vim.git
synced 2025-09-24 03:44:06 -04:00
patch 8.0.0779: :term without an argument uses empty buffer name
Problem: :term without an argument uses empty buffer name but runs the snell. Solution: Change the command to the shell earlier.
This commit is contained in:
@@ -199,6 +199,9 @@ ex_terminal(exarg_T *eap)
|
|||||||
term->tl_next = first_term;
|
term->tl_next = first_term;
|
||||||
first_term = term;
|
first_term = term;
|
||||||
|
|
||||||
|
if (cmd == NULL || *cmd == NUL)
|
||||||
|
cmd = p_sh;
|
||||||
|
|
||||||
if (buflist_findname(cmd) == NULL)
|
if (buflist_findname(cmd) == NULL)
|
||||||
curbuf->b_ffname = vim_strsave(cmd);
|
curbuf->b_ffname = vim_strsave(cmd);
|
||||||
else
|
else
|
||||||
@@ -227,9 +230,6 @@ ex_terminal(exarg_T *eap)
|
|||||||
|
|
||||||
set_term_and_win_size(term);
|
set_term_and_win_size(term);
|
||||||
|
|
||||||
if (cmd == NULL || *cmd == NUL)
|
|
||||||
cmd = p_sh;
|
|
||||||
|
|
||||||
/* System dependent: setup the vterm and start the job in it. */
|
/* System dependent: setup the vterm and start the job in it. */
|
||||||
if (term_and_job_init(term, term->tl_rows, term->tl_cols, cmd) == OK)
|
if (term_and_job_init(term, term->tl_rows, term->tl_cols, cmd) == OK)
|
||||||
{
|
{
|
||||||
|
@@ -769,6 +769,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
779,
|
||||||
/**/
|
/**/
|
||||||
778,
|
778,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user