Daemon to run a program when CS:GO starts and stops
Project description
csgo_handler
Program that detects when CSGO is launched or closed and runs a script.
This program only works on Linux as it depends on inotify
.
Configuration
The configuration file location respects XDG, and will try the following paths, in this order:
$XDG_CONFIG_HOME/csgo_handler.yaml
$XDG_CONFIG_HOME/csgo_handler.yml
$XDG_CONFIG_HOME/csgo_handler/csgo_handler.yaml
$XDG_CONFIG_HOME/csgo_handler/csgo_handler.yml
$XDG_CONFIG_HOME/csgo_handler/config.yaml
$XDG_CONFIG_HOME/csgo_handler/config.yml
NOTE:
$XDG_CONFIG_HOME
will default to$HOME/.config
on most systems.- A lazy match is used, meaning the first file that exists will be used.
Example configuration
---
# Path to the 'csgo.sh' script
script_path: /opt/games/steamapps/common/Counter-Strike Global Offensive/csgo.sh
# Action to run when game starts
start_script:
- /bin/bash
- -c
- nvidia-settings -a 'DigitalVibrance[DFP-5]=1023'
# Action to run when game stops
stop_script:
- /bin/bash
- -c
- nvidia-settings -a 'DigitalVibrance[DFP-5]=0'
Command-line parameters
The following parameters are present:
Argument | Short argument | Explanation | Default | Example |
---|---|---|---|---|
--config |
-c |
Override config path | None |
csgo_handler -c /etc/csgo_handler.yaml |
--config_path |
-C |
Search for config files within this folder | None |
csgo_handler -C /etc/csgo_handler |
--daemon |
-D |
Run as a daemon | False |
csgo_handler -D |
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
csgo_handler-1.0.1.tar.gz
(15.8 kB
view hashes)
Built Distribution
Close
Hashes for csgo_handler-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f4b6462760b6d111dad18238292642caf137c6efe15ed17bfc5a1ceb0628c17e |
|
MD5 | 5c4271323cc52f60e290cb8a8a0741f1 |
|
BLAKE2b-256 | 4d01e75026cf068fa18428087a2541a21d60754845e2906e30d8a6630e9f68ae |