Extracted pmset config into steps/step_sleep.sh and call it from setup.sh, setup_ollama.sh, and setup_onyx.sh so both devices in a split setup stay awake.
10 lines
308 B
Bash
Executable file
10 lines
308 B
Bash
Executable file
#!/bin/bash
|
|
# Step: Prevent the machine from sleeping. Source common.sh before sourcing this file.
|
|
|
|
prevent_sleep() {
|
|
print_step "Preventing Sleep"
|
|
|
|
print_warning "Configuring power settings to prevent sleep..."
|
|
sudo pmset -a sleep 0 disksleep 0
|
|
print_success "Sleep prevention configured"
|
|
}
|