Skip to content

How do I prevent an alternate screen from appearing when executing custom cmds? #1693

Answered by DusanLesan
dievilz asked this question in Q&A
Discussion options

You must be logged in to vote

It is enough to switch from shell prefix $ to shell-async prefix % like:

cmd delete %{{
	set -f
	printf "$fx\n"
	printf "delete?[y/n]"
	read ans
	[ "$ans" = "y" ] && rm -rf $fx
	lf -remote "send $id echo"
}}

edit: added echo at the end to clear status line

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@dievilz
Comment options

@DusanLesan
Comment options

Answer selected by dievilz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants