dcop konsole
I'm trying to use a couple of commands to start konsole with a formatted prompt (PS1).
Heres what I have so far: konsole --script & dcop konsole-$! session-1 feedSession "PS1='\033[33;1m[\u \w]\$\033[0m '" This sends the text ["PS1='\033[33;1m[\u \w]\$\033[0m '"] to the session, but I can't figure out how to emulate an enter from the dcop interface (submit the text). Does anyone know how to do this? Thanks In Advance Bendeco |
You can also edit ~/.bashrc and insert PS1='\033[33;1m[\u \w]\$\033[0m' there, to change your prompt.
But for your problem: I managed to do your trick by typing konsole --script & dcop konsole-$! session-1 feedSession "PS1='\033[33;1m[\u \w]\$\033[0m ', then Enter, and then " and again Enter. (So type an Enter before the last quotes) -Frank |
I understand how that works and I got mine to do the same thing in a similar fashion. I guess I didn't phrase my question in a clear manor.
My problem is that I don't want to have to hit the enter key, but emulate the same affect that the enter key would provide by passing some command that I don't have knowledge of. This would make it possible to add the command to a script. Thanks for the reply... I hope this clears up my question. |
Sorry about the prior reply, but after playing around with it for a little while.
I realized that you're idea is the correct way to do this. I just had to add the last double quotation mark (") on a new line. In a script it would look something like this: Code:
#!/bin/bash Thanks again Frankmulder |
All times are GMT -5. The time now is 04:28 AM. |