Skip to content

Instantly share code, notes, and snippets.

View zadykian's full-sized avatar

Sasha Zadykian zadykian

View GitHub Profile
@zadykian
zadykian / run-go-tools.sh
Created October 14, 2024 19:04
Shell script to run go tools
#!/bin/bash
# Check if a file path is provided
if [ -z "$1" ]; then
echo "Error: No file path provided."
echo "Usage: $0 <file-path>"
exit 1
fi
FILE=$1
@zadykian
zadykian / ConfigureMonitors.vbs
Last active October 13, 2024 17:00
ControlMyMonitor Setup
Set WshShell = CreateObject("WScript.Shell")
WshShell.CurrentDirectory = CreateObject("Scripting.FileSystemObject").GetParentFolderName(WScript.ScriptFullName)
displays = Array("\\.\DISPLAY1\Monitor0", "\\.\DISPLAY2\Monitor0")
For Each display In displays
resetCmd = ".\ControlMyMonitor.exe /SetValue " & display & " 04 1"
WshShell.Run resetCmd, 0, True
brightnessCmd = ".\ControlMyMonitor.exe /SetValue " & display & " 10 60"
@zadykian
zadykian / init.lua
Created September 28, 2024 21:09
Automatic Reset + Brightness Adjustment for ASM-160QCC monitors
--init.lua
function monitorChangedCallback()
hs.execute('~/.wakeup', true)
end
monitorWatcher = hs.screen.watcher.newWithActiveScreen(monitorChangedCallback):start()
package main
import (
"encoding/json"
"github.com/google/uuid"
)
type Person struct {
Name string
Age uint8