Add systemd service

This commit is contained in:
dec05eba
2024-10-27 14:08:47 +01:00
parent 80ff6582a9
commit c6b5ff05ec
4 changed files with 20 additions and 1 deletions

View File

@@ -1,6 +1,9 @@
# GPU Screen Recorder UI
A fullscreen overlay UI for [GPU Screen Recorder](https://git.dec05eba.com/gpu-screen-recorder/about/) in the style of ShadowPlay.
# Usage
Run `gsr-ui` and press `Alt+Z` to show/hide the UI. You can start the overlay UI at system startup by running `systemctl enable --now --user gpu-screen-recorder-ui`.
# Dependencies
GPU Screen Recorder UI uses meson build system so you need to install `meson` to build GPU Screen Recorder UI.

View File

@@ -0,0 +1,11 @@
[Unit]
Description=GPU Screen Recorder UI Service
[Service]
ExecStart=gsr-ui
KillSignal=SIGINT
Restart=on-failure
RestartSec=5s
[Install]
WantedBy=default.target

View File

@@ -59,3 +59,7 @@ executable(
install_subdir('images', install_dir : gsr_ui_resources_path)
install_subdir('fonts', install_dir : gsr_ui_resources_path)
if get_option('systemd') == true
install_data(files('extra/gpu-screen-recorder-ui.service'), install_dir : 'lib/systemd/user')
endif

1
meson_options.txt Normal file
View File

@@ -0,0 +1 @@
option('systemd', type : 'boolean', value : true, description : 'Install systemd service file')