This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--init.lua | |
function monitorChangedCallback() | |
hs.execute('~/.wakeup', true) | |
end | |
monitorWatcher = hs.screen.watcher.newWithActiveScreen(monitorChangedCallback):start() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"encoding/json" | |
"github.com/google/uuid" | |
) | |
type Person struct { | |
Name string | |
Age uint8 |