gnome-desktop-session-restore
This is a simple tool that restores the state of one or more Gnome workspaces. It is designed on Ubuntu 20.04 but should work with earlier versions but is as yet untested in older versions. It may also work on other Linux distros that also use Gnome workspaces.
This tools is written in Python and requires a Python interpreter. We also use
the wmctrl
tool to manage windows. These can be installed by running
install.sh
. This installation script uses apt
to install
dependencies thus it will only work on Debian-derived distros.
Run the installation script:
-
via
curl
:curl -so- https://raw.githubusercontent.com/K-and-R/gnome-desktop-session-restore/v0.1.0/install.sh | bash
-
via
wget
:wget -qO- https://raw.githubusercontent.com/K-and-R/gnome-desktop-session-restore/v0.1.0/install.sh | bash
The configuration file is ~/.gnome-desktop-session.json
. There is an example
file included in this repo which can be obtained from
GitHub and used as a starting point for configation:
curl -s https://raw.githubusercontent.com/K-and-R/gnome-desktop-session-restore/v0.1.0/session.json.example -o ~/.gnome-desktop-session.json
This configration file is meant to be modified. It is expected to be valid JSON. You can validate your JSON file using JSONLint.
NB: This configuration file is created by the install.sh
script, from the
example file, if it doesn't already exist.
Simply run: restore-gnome-desktop-session
To upgrade to a newer version, simply run the installation script for that newer version.
To remove this tool and its configuration file, run uninstall.sh
:
curl -so- https://raw.githubusercontent.com/K-and-R/gnome-desktop-session-restore/v0.1.0/uninstall.sh | bash
NB: The additional packages installed by the install.sh
script (curl
,
python
, and wmctrl
) will not be removed automatically and will need to be
removed manually if they are no longer wanted:
sudo apt remove curl python wmctrl