Decouple screenshot script from Xmd, Xmd session from Mwm

This commit is contained in:
Sasha Koshka 2024-01-17 11:30:25 -05:00
parent b341fbe6ca
commit 45425c91d1
4 changed files with 18 additions and 3 deletions

View File

@ -49,6 +49,11 @@ in their respective subdirectories:
## Session
Xmd includes a startup script and assorted "glue code" to facilitate using it as
a desktop environment. It can be installed using `./install.sh` in the `session`
Xmd includes several scripts to facilitate using it as a desktop environment. It
can be installed using `./install.sh` in the `session` directory.
## Glue
Xmd includes some utility scripts to provide a standard interface for things
like screenshotting. These can be installed using `./install.sh` in the `glue`
directory.

View File

@ -1,5 +1,7 @@
#!/bin/sh
export XMD_SESSION_PID="$$"
export XMD_USERDIR="${HOME}/.Xmd"
mkdir -p "${XMD_USERDIR}"
@ -26,4 +28,4 @@ else
echo "!!! cant find $startupDir"
fi
exec mwm
sleep infinity

8
session/src/xmd-end-session Executable file
View File

@ -0,0 +1,8 @@
#!/bin/sh
if [ -z "$XMD_SESSION_PID" ]; then
echo "ERR session is not running (\$XMD_SESSION_PID not set)"
exit 1
fi
kill "$XMD_SESSION_PID"