personal blog
git clone git://
Log | Files | Refs | README

commit f3958ba1c6ae7937438eadbc1a3842c0c12074e4
parent 767c23b074dcdf1b34703cb218984e1d8aac9dad
Author: pyratebeard <>
Date:   Thu, 20 Oct 2022 22:54:29 +0100

Merge branch 'main' into smoke_me_a_kipper

MMakefile | 10++++++++++
Aentry/ | 28++++++++++++++++++++++++++++
2 files changed, 38 insertions(+), 0 deletions(-)

diff --git a/Makefile b/Makefile @@ -18,6 +18,16 @@ endif endif endif +ifeq ($(DRAFT_ARGS), ) + DRAFT_ARGS := $(shell git branch --show-current) +endif +ifeq ($(VIEW_ARGS), ) + VIEW_ARGS := $(shell git branch --show-current) +endif +ifeq ($(PUB_ARGS), ) + PUB_ARGS := $(shell git branch --show-current) +endif + prog: # ... # ... diff --git a/entry/ b/entry/ @@ -0,0 +1,28 @@ +I didn't know that [vim](TK){target="_blank" rel="noreferrer"} could open a terminal in a window split. + +Usually I have vim in a [tmux](TK){target="_blank" rel="noreferrer"} session so can split the tmux window to get a terminal. Occasionally I would use `:shell`, which opens a shell in the current terminal but backgrounds vim so you have to exit the shell to return. This is useful but it can be beneficial to keep your buffer open while running a command, and vim may not be in a tmux session. + +As of vim 8 the terminal feature is natively supported. Neovim also has this feature natively. To see if your vim has this feature incant the following +``` +:echo has('terminal') +``` + +If the output is `1` then you have it. + +To simply open a terminal in a split incant +``` +:terminal +``` +or +``` +:term +``` + +You can append a command, which once completed will open the output in a buffer ready for editing. + +This is a cool feature, and I will probably use it quite a bit. It is great fun to be constantly learning vim, even finding features that have been around for a while. + +For more information on the terminal feature check out the help page +``` +:help terminal +```