Results 1 to 4 of 4
Hi,
I need help with a bash script. I'm writing one that will run only in a screen session. and sometimes it'll output some garbage that i'd like to see ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 10-27-2012 #1Just Joined!
- Join Date
- Jun 2011
- Posts
- 9
How can I turn off screen logging from a bash script ?
Hi,
I need help with a bash script. I'm writing one that will run only in a screen session. and sometimes it'll output some garbage that i'd like to see when looking at the screen session, but it's totally unneccessary to put it in the session logs. I'm using the built in screen logging. Now I know I can disable/reenable it by c-a H keys, but I need to do that from the script so it can disable the logging before displaying the garbage, and reenable it after it's displayed.
Thank you in advance for any help.
Best regards
Szafran
- 10-27-2012 #2Trusted Penguin
- Join Date
- May 2011
- Posts
- 3,700
Hi,
I believe you can send keystrokes to the screen terminal using screen's "stuff" command. I'm not sure if you can send keybinds (e.g. c-a H), but maybe...check it out in the screen man page.
- 10-27-2012 #3Just Joined!
- Join Date
- Jun 2011
- Posts
- 9
Thanks for the info, I belive I've tried that allready.
But anyways. This is what is spits out:
So I think that stuff command can only be used in the rc file, and I need something that I can use from bash script.Code:szafran@NAS:~$ stuff stuff: command not found
- 10-27-2012 #4Trusted Penguin
- Join Date
- May 2011
- Posts
- 3,700


Reply With Quote

