Created
August 15, 2018 19:41
-
-
Save sjl/124c4eff0273e8d0b477bfecf11774f8 to your computer and use it in GitHub Desktop.
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
(defcommand screen-single () () | |
(loop with laptop = "eDP1" | |
with extern = "DP1" | |
for (output commands) in `((,laptop ("--primary")) | |
(,extern ("--off")) | |
(,laptop ("--preferred"))) | |
do (uiop:run-program `("xrandr" "--output" ,output ,@commands)))) | |
(defcommand screen-multi () () | |
(loop with laptop = "eDP1" | |
with extern = "DP1" | |
for (output commands) in `((,laptop ("--preferred")) | |
(,extern ("--on")) | |
(,extern ("--preferred")) | |
;; (,extern ("--mode" "2560x1440")) | |
(,extern ("--left-of" ,laptop)) | |
(,extern ("--primary"))) | |
do (uiop:run-program `("xrandr" "--output" ,output ,@commands)))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment