scripting - Bash: Set up a new command on a new line without executing -


this question has answer here:

i'm trying write bash script output partially completed command can add parameters to, hit enter , run. want implemented in bash.

e.g.

~> ./test.sh ~> ls -al <cursor position here> 

the variable i've found that's close prompt_command variable, when set inside test.sh 'ls -al', execute once script has exited.

is there way stop immediate execution, can add, say, *.log?

how about

read -e -p"$pwd> " -i"ls -al " cmd; eval "$cmd" 

Comments

Popular posts from this blog

unity3d - Rotate an object to face an opposite direction -

angular - Is it possible to get native element for formControl? -

javascript - Why jQuery Select box change event is now working? -