Skip to content

Instantly share code, notes, and snippets.

@neohunter
Created Sep 1, 2016
Embed
What would you like to do?
Slate config
config defaultToCurrentScreen true
config nudgePercentOf screenSize
config resizePercentOf screenSize
config secondsBetweenRepeat 0.1
config checkDefaultsOnLoad true
config focusCheckWidthMax 3000
config windowHintsDuration 5
config windowHintsSpread true
config windowHintsOrder persist
config windowHintsShowIcons true
config windowHintsIgnoreHiddenWindows false
alias hyper ctrl;shift;alt;cmd
# Monitor Aliases
alias mon-main 0
alias mon-external 1
# Misc Aliases
alias showHintsLeftHand hint AOEUIYQJKX
alias showNormalHint hint AOEUIDHTNSYXFBPKGMCW
alias full move screenOriginX;screenOriginY screenSizeX;screenSizeY
alias restore sequence activate-snapshot default-snp delete
alias save snapshot default-snp
# Push Bindings - alinear a la derecha izquierda - arriba - abajo
#bind d:${hyper} push right bar-resize:screenSizeX/2
#bind a:${hyper} push left bar-resize:screenSizeX/3
#bind w:${hyper} push up bar-resize:screenSizeY/2
#bind s:${hyper} push down bar-resize:screenSizeY/2
bind d:${hyper} push right center
bind a:${hyper} push left center
bind w:${hyper} push up center
bind x:${hyper} push down center
bind s:${hyper} chain sequence ${restore} > move screenOriginX+((screenSizeX-windowSizeX)/2);screenOriginY+((screenSizeY-windowSizeY)/2) windowSizeX;windowSizeY > ${save} | ${full}
bind q:${hyper} corner top-left center
bind e:${hyper} corner top-right center
bind z:${hyper} corner bottom-left center
bind c:${hyper} corner bottom-right center
# Align vertically at the left
bind f:${hyper} chain sequence ${save} > push left bar-resize:screenSizeX/4 | push left bar-resize:screenSizeX/8 | ${restore}
bind g:${hyper} chain sequence ${save} > push right bar-resize:screenSizeX/4 | push right bar-resize:screenSizeX/8 | ${restore}
# Nudge Bindings
bind ':${hyper} nudge +5% +0
bind l:${hyper} nudge -5% +0
bind p:${hyper} nudge +0 -5%
bind ;:${hyper} nudge +0 +5%
# Throw to other screen Bindings
#bind 1:${hyper} throw 0
#bind 2:${hyper} throw 1 resize
# Resize Bindings
bind right:${hyper} resize +5% +0
bind left:${hyper} resize -5% +0
bind up:${hyper} resize +0 -5%
bind down:${hyper} resize +0 +5%
# Focus Bindings
# bind ':${hyper} focus right
# bind l:${hyper} focus left
# bind p:${hyper} focus up
# bind ;:${hyper} focus down
#bind up:cmd;alt focus behind
#bind down:cmd;alt focus behind
# Abstract positions
alias full move screenOriginX;screenOriginY screenSizeX;screenSizeY
alias lefthalf move screenOriginX;screenOriginY screenSizeX/2;screenSizeY
alias righthalf move screenOriginX+screenSizeX/2;screenOriginY screenSizeX/2;screenSizeY
alias rightmost move screenOriginX+screenSizeX*0.4;screenOriginY screenSizeX*0.6;screenSizeY
alias rightless move screenOriginX+screenSizeX*0.6;screenOriginY screenSizeX*0.4;screenSizeY
alias leftmost move screenOriginX;screenOriginY screenSizeX*0.6;screenSizeY
alias leftless move screenOriginX;screenOriginY screenSizeX*0.4;screenSizeY
# Concrete positions
alias 1-full move screenOriginX;screenOriginY screenSizeX;screenSizeY ${mon-main}
alias 1-left move screenOriginX;screenOriginY screenSizeX/2;screenSizeY ${mon-main}
alias 1-right move screenOriginX+screenSizeX/2;screenOriginY screenSizeX/2;screenSizeY ${mon-main}
alias 2-left move screenOriginX;screenOriginY screenSizeX/2;screenSizeY ${mon-external}
alias 2-right move screenOriginX+screenSizeX/2;screenOriginY screenSizeX/2;screenSizeY ${mon-external}
alias 2-righttop move screenOriginX+screenSizeX/2;screenOriginY screenSizeX/2;screenSizeY/2 ${mon-external}
alias 2-rightbottom move screenOriginX+screenSizeX/2;screenOriginY+screenSizeY/2 screenSizeX/2;screenSizeY/2 ${mon-external}
# 2 Monitor layout
layout 2monitors 'iTerm':MAIN_FIRST ${2-rightbottom} | ${1-left}
layout 2monitors 'Safari':REPEAT ${1-full}
layout 2monitors 'Nightly':REPEAT ${1-full}
layout 2monitors 'Sublime Text 2':REPEAT ${1-full}
layout 2monitors 'MacVim':REPEAT ${1-full}
layout 2monitors 'Mail':MAIN_FIRST ${2-left}
layout 2monitors 'Path Finder':MAIN_FIRST ${2-righttop}
layout 2monitors 'Xcode':REPEAT ${1-full}
layout 2monitors 'Eclipse':REPEAT ${1-full}
layout 2monitors 'iTunes':REPEAT ${1-full}
# 1 Monitor layout
layout 1monitor 'iTerm':MAIN_FIRST ${1-right}
layout 1monitor 'Sublime Text 2':MAIN_FIRST ${1-left}
layout 1monitor 'MacVim':MAIN_FIRST ${1-left}
layout 1monitor 'Safari':REPEAT ${1-full}
layout 1monitor 'Nightly':REPEAT ${1-full}
layout 1monitor 'Mail':MAIN_FIRST ${1-full}
layout 1monitor 'Path Finder':MAIN_FIRST ${1-full}
layout 1monitor 'Xcode':REPEAT ${1-full}
layout 1monitor 'Eclipse':REPEAT ${1-full}
layout 1monitor 'iTunes':REPEAT ${1-full}
# Default Layouts
default 2monitors resolutions:${mon-main};${mon-external};
default 1monitor resolutions:${mon-main}
# bind l:cmd layout 1monitor
# program keys
# bind c:cmd;alt focus 'Google Chrome'
# bind s:cmd;alt focus 'Sublime Text'
bind =:${hyper} shell '/usr/bin/subl ~/.slate'
bind r:${hyper} relaunch
bind u:${hyper} undo
# Window Hints
bind esc:${hyper} hint
#bind esc:ctrl grid padding:5 0:24,12
#bind tab:${hyper} switch
bind 1:${hyper} snapshot theName save-to-disk;stack
bind tab:${hyper} activate-snapshot theName delete
source ~/.slate-custom if_exists
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment