Skip to content

Instantly share code, notes, and snippets.

@giantorth
giantorth / cyberpunk.sh
Created September 3, 2025 12:37
Updates Cyberpunk 2077 resolution in UserSettings.json to match the PRIMARY display in Linux
#!/bin/bash
# cyberpunk.sh
# Updates Cyberpunk 2077 resolution in UserSettings.json to match the PRIMARY display in Linux
#
# Set LAUNCH OPTIONS in steam to: /path/of/script/cyberpunk.sh %COMMAND%
# Don't forget to make script executable: chmod +x cyberpunk.sh
# 1. Get current resolution of the primary display using xrandr
resolution=$(xrandr | awk '/ connected primary / {print $4}' | cut -d+ -f1)
@giantorth
giantorth / disco.sh
Last active September 3, 2025 12:37
Updates Disco Elysium resolution in Settings.json to match the PRIMARY display
#!/bin/bash
# disco.sh
# Updates Disco Elysium resolution in Settings.json to match the PRIMARY display in Linux
#
# Set LAUNCH OPTIONS in steam to: /path/of/script/disco.sh %COMMAND%
# Don't forget to make script executable: chmod +x disco.sh
# 1. Get current resolution of the primary display using xrandr
resolution=$(xrandr | awk '/ connected primary / {print $4}' | cut -d+ -f1)
@giantorth
giantorth / fade_media_with_lights-1.0.yaml
Last active October 7, 2024 13:40
Fade Home Assistant media player entity with the lights
blueprint:
name: Fade Media Player Volume Based on Light
description: Adjusts the volume of a media player based on the state of a light.
domain: automation
input:
light_entity:
name: Light Entity
description: The light entity to monitor.
selector:
entity:
@giantorth
giantorth / LMS-Autoskip_stuck_playlist.yaml
Last active October 31, 2023 15:36
Logitech Media Service autoskip stuck playlist
blueprint:
name: Autoskip LMS track
description: Automatically skip tracks on LMS players when stuck at the end that do not advance
domain: automation
input:
media_player:
name: Media Player
description: Media player to monitor
selector:
entity: