Skip to content

Instantly share code, notes, and snippets.

@MinweiShen
Created January 1, 2016 20:23
Show Gist options
  • Save MinweiShen/939396ef075bdadd156d to your computer and use it in GitHub Desktop.
Save MinweiShen/939396ef075bdadd156d to your computer and use it in GitHub Desktop.
my slate configuration
# 定义查找窗口切换时显示在每个窗口图标的字符,类似于Vim的easymotion插件
alias showHintsLeftHand hint ASDFQWERT
alias showNormalHint hint QWERTASDFGZXCVYUIOPHJKLBNM
#KANA is remap to F18
#EISUU is remap to F19
# 一些位置定义:全屏,左半屏,右半屏等等
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
#move the window to some edge or center
bind a:f18 ${lefthalf}
bind x:f18 push bottom bar-resize:screenSizeY/2
bind w:f18 push top bar-resize:screenSizeY/2
bind d:f18 ${righthalf}
bind s:f18 ${full}
#move the window to some conner
bind q:f18 move screenOriginX;screenOriginY screenSizeX/2;screenSizeY/2
bind e:f18 move screenOriginX+screenSizeX/2;screenOriginY screenSizeX/2;screenSizeY/2
bind z:f18 move screenOriginX;screenOriginY+screenSizeY/2 screenSizeX/2;screenSizeY/2
bind c:f18 move screenOriginX+screenSizeX/2;screenOriginY+screenSizeY/2 screenSizeX/2;screenSizeY/2
#move the window to another window
bind right:f19 move screenOriginX+screenSizeX/4;screenOriginY+screenSizeY/4 screenSizeX/2;screenSizeY/2 1
bind left:f19 move screenOriginX+screenSizeX/4;screenOriginY+screenSizeY/4 screenSizeX/2;screenSizeY/2 0
#provide some hints
bind f:f18 ${showHintsLeftHand}
# undo
bind u:f18 undo
#open some window
bind 2:f18 toggle 'Finder'
bind 3:f18 toggle 'Google Chrome'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment