Can someone please tell me how to do that?

Code: Select all
echo standby 0 | cec-client -s -d 1
Code: Select all
[Unit]
Description=Run CEC command to turn the TV off
DefaultDependencies=no
Before=umount.target
[Service]
Type=oneshot
ExecStart=echo standby 0 | cec-client -s -d 1
[Install]
WantedBy=poweroff.target halt.target