Skip to content

Instantly share code, notes, and snippets.

@spiashko
Created November 6, 2020 23:25
Show Gist options
  • Star 10 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save spiashko/3cec1ef083a8dbeb68c6ffa589ae53fc to your computer and use it in GitHub Desktop.
Save spiashko/3cec1ef083a8dbeb68c6ffa589ae53fc to your computer and use it in GitHub Desktop.
# Always use the integrated graphics card while running on battery power
sudo pmset -b gpuswitch 0
# Always use the discrete graphics card while running on battery power
sudo pmset -b gpuswitch 1
# Switch between discrete and integrated graphics cards automatically while running on battery power
sudo pmset -b gpuswitch 2
@taupo2022
Copy link

The -a, -b, -c, -u flags determine whether the settings apply to battery ( -b ), charger (wall power) ( -c ), UPS ( -u ) or all ( -a ).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment