added scripts folder to gitea

This commit is contained in:
lucca
2026-06-11 13:47:48 -04:00
commit f8130bd7d0
91 changed files with 1868 additions and 0 deletions
+6
View File
@@ -0,0 +1,6 @@
import sys
from windowsVidModeFunctions import *
monProfile("1280x960@120i")
os.system("~/sh/monitormodes/reset")
os.system("sudo /usr/bin/ddcutil setvcp --sn HTJM400760 60 6 &")
scriptRun("D:/Scripts/controlmymonitor/controlmymonitor.exe /SetValue HTJM400760 60 6")
+6
View File
@@ -0,0 +1,6 @@
import sys
from windowsVidModeFunctions import *
os.system("xrandr --output HDMI-3 --off")
monProfile("4monitors")
os.system("sudo /usr/bin/ddcutil setvcp --sn HTJM400760 60 9 &")
scriptRun("D:/Scripts/controlmymonitor/controlmymonitor.exe /SetValue HTJM400760 60 9 " )
+4
View File
@@ -0,0 +1,4 @@
#!/bin/bash
bluetoothctl disconnect 9B:40:B0:7F:F9:9F
#bluetoothctl power off
notify-send "bluetooth headset disconnected"
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
bluetoothctl power on
sleep 5
bluetoothctl connect 9B:40:B0:7F:F9:9F
notify-send "bluetooth headset connected"
+2
View File
@@ -0,0 +1,2 @@
#!/bin/bash
ssh -J gpc xmonad-rad xset -display :0 dpms force off
+4
View File
@@ -0,0 +1,4 @@
#!/bin/bash
sudo /usr/bin/ddcutil setvcp --sn HTJM400760 60 7 &
sshLucka("lucka@gaming-win 'D: && /Scripts/controlmymonitor/controlmymonitor.exe /SetValue HTJM400760 60 6'")
+4
View File
@@ -0,0 +1,4 @@
#!/bin/bash
sudo /usr/bin/ddcutil setvcp --sn HTJM400760 60 7 &
ssh vrtest@gaming-pc 'D: && /Scripts/controlmymonitor/controlmymonitor.exe /SetValue HTJM400760 60 6'
+3
View File
@@ -0,0 +1,3 @@
#!/bin/bash
~/sh/gamingpc/vmswap.sh ltsc2021-nv-mp
~/sh/gamingpc/vmswap.sh tv-rad-vg-mp
+2
View File
@@ -0,0 +1,2 @@
ssh 192.168.0.2 sudo /sbin/poweroff
notify-send "gaming pc turned off"
+3
View File
@@ -0,0 +1,3 @@
notify-send "switching to gaming hi-spec vm..."
ssh 192.168.0.2 /home/lucka/sh/vm/ltsc2021-nv-high
notify-send "switched to gaming hi-spec vm"
+3
View File
@@ -0,0 +1,3 @@
notify-send "switching to gaming vm..."
ssh 192.168.0.2 /home/lucka/sh/vm/ltsc2021-nv
notify-send "switched to gaming vm"
+4
View File
@@ -0,0 +1,4 @@
#!/bin/bash
notify-send "switching to media vm..."
ssh 192.168.0.2 /home/lucka/sh/vm/tv-nv
notify-send "switched to media vm"
+3
View File
@@ -0,0 +1,3 @@
notify-send "switching to nvidia workstation vm..."
ssh 192.168.0.2 /home/lucka/sh/vm/xmonad-nv
notify-send "switched to nvidia workstation vm"
+3
View File
@@ -0,0 +1,3 @@
ssh 192.168.0.2 virsh -c qemu:///system shutdown xmonad-rad
notify-send "powered off workstation VM"
+3
View File
@@ -0,0 +1,3 @@
ssh 192.168.0.2 virsh -c qemu:///system start xmonad-rad
notify-send "powered on workstation VM"
+2
View File
@@ -0,0 +1,2 @@
wakeonlan D0:50:99:C3:29:4D
notify-send "gaming pc turned on"
+2
View File
@@ -0,0 +1,2 @@
ssh 192.168.0.2 sudo /sbin/reboot
notify-send "gaming pc rebooted"
+5
View File
@@ -0,0 +1,5 @@
newvm=$1
echo $newvm
notify-send "switching to $newvm vm..."
ssh gaming-pc /home/lucka/sh/vm/swap-nv $newvm
notify-send "switched to $newvm vm"
+3
View File
@@ -0,0 +1,3 @@
import sys
from windowsVidModeFunctions import *
monProfile(sys.argv[1])
+39
View File
@@ -0,0 +1,39 @@
import os
import time
#Functions, hotkeys are at the bottom
def scriptRun(batchcode):
sshLucka(f"lucka@gaming-win 'echo {batchcode} > script.bat && schtasks /Run /TN script'")
def monProfile(profile):
scriptRun(f"D:/scripts/MonitorProfileSwitcher_v0700\MonitorSwitcher.exe -load:C:/Users/vmtest/AppData/Roaming/MonitorSwitcher/Profiles/{profile}.xml")
def sshLucka(command):
os.system(f"sudo -u lucka ssh -i /home/lucka/.ssh/id_rsa {command}")
def monitorLin():
sshLucka("lucka@workstation-rad sudo /usr/bin/ddcutil setvcp --sn HTJM400760 60 7 &")
sshLucka("lucka@gaming-win 'D: && /Scripts/controlmymonitor/controlmymonitor.exe /SetValue HTJM400760 60 6'")
def monitorWin():
sshLucka("lucka@workstation-rad sudo /usr/bin/ddcutil setvcp --sn HTJM400760 60 6 &")
sshLucka("lucka@gaming-win 'D: && /Scripts/controlmymonitor/controlmymonitor.exe /SetValue HTJM400760 60 5'")
def res640x480():
scriptRun("res 640 480 120 p")
def res1280x960():
monProfile("1280x960@120i")
def res1600x1200():
monProfile("1600x1200@100i")
def res1600x900():
monProfile("1600x900@120i")
def res800x600():
monProfile("800x600@100p")
def res960x720():
scriptRun("res 960 720 120 i")
def linScreenOff():
sshLucka("lucka@workstation-rad DISPLAY=:0 xset dpms force off")
def res1280x720():
scriptRun("res 1280 720 60 p")
def wegaOnly():
monProfile("wegaOnly")
time.sleep(1)
scriptRun("res 720 540 119 i")
def svideoOnly():
monProfile("SVIDEO")
+3
View File
@@ -0,0 +1,3 @@
notify-send "switching to nvidia workstation vm..."
ssh 192.168.0.2 /home/lucka/sh/vm/xmonad-nv
notify-send "switched to nvidia workstation vm"
+1
View File
@@ -0,0 +1 @@
D:/Scripts/controlmymonitor/controlmymonitor.exe /SetValue HTJM400760 60 6
+3
View File
@@ -0,0 +1,3 @@
import sys
from windowsVidModeFunctions import *
monProfile(sys.argv[1])
+8
View File
@@ -0,0 +1,8 @@
import os
def scriptRun(batchcode):
sshCommand(f"vrtest@gaming-pc 'echo {batchcode} > script.bat && schtasks /Run /TN script'")
def monProfile(profile):
scriptRun(f"D:/scripts/MonitorProfileSwitcher_v0700/MonitorSwitcher.exe -load:C:/Users/vrtest/AppData/Roaming/MonitorSwitcher/Profiles/{profile}.xml")
def sshCommand(command):
os.system(f"ssh {command}")