summaryrefslogtreecommitdiff
path: root/.bashrc
diff options
context:
space:
mode:
authorMike Crute <crutem@amazon.com>2019-04-18 09:01:45 -0700
committerMike Crute <crutem@amazon.com>2019-04-18 09:38:28 -0700
commit2c60241692cc3db0f00871ca36601893a3e7abe8 (patch)
tree39a7023badd1bbc0aac9314e356a5ad04cac6fa9 /.bashrc
parent56ee1874650433f7f54fef57f58b911ce58769fb (diff)
downloaddotfiles-2c60241692cc3db0f00871ca36601893a3e7abe8.tar.bz2
dotfiles-2c60241692cc3db0f00871ca36601893a3e7abe8.tar.xz
dotfiles-2c60241692cc3db0f00871ca36601893a3e7abe8.zip
Add reset_screens command
Diffstat (limited to '.bashrc')
-rw-r--r--.bashrc11
1 files changed, 11 insertions, 0 deletions
diff --git a/.bashrc b/.bashrc
index 2e8eb2c..0c6ae09 100644
--- a/.bashrc
+++ b/.bashrc
@@ -334,6 +334,17 @@ if have_command git; then
334 } 334 }
335fi 335fi
336 336
337if have_command xrandr; then
338 # This is a hack around a cheap implementation of screen management in
339 # awesome. Eventually that should be improved and this removed. It disables
340 # all display outputs know to xrandr and lets the display manager hook
341 # re-enable only those currently connected.
342 function reset_screens
343 {
344 xrandr $(xrandr -q | awk '/(disconnected|connected)/ { printf "--output " $1 " --off " }')
345 }
346fi
347
337if have_command systemctl; then 348if have_command systemctl; then
338 alias usystemctl="systemctl --user" 349 alias usystemctl="systemctl --user"
339 alias systemctl-failed-user-units="systemctl --user list-units --state=failed" 350 alias systemctl-failed-user-units="systemctl --user list-units --state=failed"