simonwalz / screen-save

A tool to make screen sessions persistent = survive system reboot.
MIT License
26 stars 4 forks source link

group #8

Closed 3d7l closed 1 year ago

3d7l commented 1 year ago

Thanks for this tool.

One question: does it also save/restore "group" window or only regular window ?

simonwalz commented 1 year ago

This tool just saves the windows (and not the layout or any split settings).

I think you can setup these options globally in your ~/.screenrc file, but I have not really tested this.

Sample file:

# cat ~/.screenrc
startup_message off
defutf8 on

# split in four zones and show windows 1 - 4:
split
select 1
split -v
focus next
select 2
focus next
select 3
split -v
focus next
select 4

Does this help you?

3d7l commented 1 year ago

Thanks for your answer.

I was thinking about the logical "group" feature, the one you start with this command: screen //group I think the feature was introduced in version 4.2.0 (from https://fossies.org/linux/screen/ChangeLog)

Regarding persisting the layout, your example is very useful. It is indeed the best way to go.

Thanks

simonwalz commented 1 year ago

Okay. Cool feature. I was not aware of that. The current implementation does not restore these groups.

An implementation might be hard, because the group command can not be queried via the screen command:

> screen -S 7151 -p 1 -Q group                                   ~ 
group command cannot be queried.
3d7l commented 1 year ago

Thanks for your explanation.

The windows inside a group window are saved, which is the most important (group aggregations can then be re-created with a few keystrokes).