emacs updates
This commit is contained in:
parent
f2801cae75
commit
14543a1024
@ -23,7 +23,7 @@
|
|||||||
;; If there is more than one, they won't work right.
|
;; If there is more than one, they won't work right.
|
||||||
'(package-selected-packages
|
'(package-selected-packages
|
||||||
(quote
|
(quote
|
||||||
(vue-mode jedi-direx multi-web-mode web-mode quack elpy importmagic py-autopep8 flycheck excorporate ivy nginx-mode helm-projectile projectile json-mode jinja2-mode company-terraform terraform-mode yaml-mode company racer rust-mode magit theme-looper myterminal-controls meta-presenter which-key dired-launch material-theme neotree undo-tree ztree buffer-move powerline ace-window ace-jump-mode multiple-cursors helm))))
|
(csharp-mode dired-dups swift-mode highlight-indent-guides rainbow-delimiters vue-mode multi-web-mode web-mode quack elpy importmagic py-autopep8 flycheck excorporate ivy nginx-mode helm-projectile projectile json-mode jinja2-mode company-terraform terraform-mode yaml-mode company racer rust-mode magit theme-looper myterminal-controls meta-presenter which-key dired-launch material-theme neotree undo-tree ztree buffer-move powerline ace-window ace-jump-mode multiple-cursors helm))))
|
||||||
(custom-set-faces
|
(custom-set-faces
|
||||||
;; custom-set-faces was added by Custom.
|
;; custom-set-faces was added by Custom.
|
||||||
;; If you edit it by hand, you could mess it up, so be careful.
|
;; If you edit it by hand, you could mess it up, so be careful.
|
||||||
|
@ -4,10 +4,9 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
(defvar dwlisp-mode-hook nil)
|
|
||||||
(add-to-list 'auto-mode-alist '("\\.lisp\\'" . dwlisp-mode))
|
|
||||||
|
|
||||||
(define-derived-mode dwlisp-mode
|
(setq lisp-body-indent 2)
|
||||||
lisp-mode "dwlisp"
|
|
||||||
"major mode for dwlisp"
|
;cc mode
|
||||||
(setq lisp-body-indent 2))
|
(setq c-default-style "linux"
|
||||||
|
c-basic-offset 4)
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
;Change title-bar text
|
;Change title-bar text
|
||||||
(setq frame-title-format
|
(setq frame-title-format
|
||||||
"%b %F")
|
"%F %b ")
|
||||||
|
|
||||||
;Disable menu-bar
|
;Disable menu-bar
|
||||||
(menu-bar-mode -1)
|
(menu-bar-mode -1)
|
||||||
@ -21,3 +21,11 @@
|
|||||||
|
|
||||||
;line numbers
|
;line numbers
|
||||||
(global-linum-mode)
|
(global-linum-mode)
|
||||||
|
|
||||||
|
;; ITERM2 MOUSE SUPPORT
|
||||||
|
(unless window-system
|
||||||
|
(require 'mouse)
|
||||||
|
(xterm-mouse-mode t)
|
||||||
|
(defun track-mouse (e))
|
||||||
|
(setq mouse-sel-mode t)
|
||||||
|
)
|
||||||
|
@ -22,6 +22,7 @@
|
|||||||
(global-whitespace-mode)
|
(global-whitespace-mode)
|
||||||
(setq whitespace-line-column 500)
|
(setq whitespace-line-column 500)
|
||||||
|
|
||||||
|
(add-hook 'before-save-hook 'delete-trailing-whitespace)
|
||||||
;Enable winner-mode
|
;Enable winner-mode
|
||||||
(winner-mode t)
|
(winner-mode t)
|
||||||
|
|
||||||
@ -70,3 +71,27 @@
|
|||||||
(setq clean-buffer-list-kill-never-regexps
|
(setq clean-buffer-list-kill-never-regexps
|
||||||
(append '("^\\*EMMS Playlist\\*.*$")
|
(append '("^\\*EMMS Playlist\\*.*$")
|
||||||
clean-buffer-list-kill-never-regexps-init))
|
clean-buffer-list-kill-never-regexps-init))
|
||||||
|
|
||||||
|
|
||||||
|
;https://stackoverflow.com/questions/43765/pin-emacs-buffers-to-windows-for-cscope
|
||||||
|
(defun toggle-window-dedicated ()
|
||||||
|
|
||||||
|
"Toggle whether the current active window is dedicated or not"
|
||||||
|
|
||||||
|
(interactive)
|
||||||
|
|
||||||
|
(message
|
||||||
|
|
||||||
|
(if (let (window (get-buffer-window (current-buffer)))
|
||||||
|
|
||||||
|
(set-window-dedicated-p window
|
||||||
|
|
||||||
|
(not (window-dedicated-p window))))
|
||||||
|
|
||||||
|
"Window '%s' is dedicated"
|
||||||
|
|
||||||
|
"Window '%s' is normal")
|
||||||
|
|
||||||
|
(current-buffer)))
|
||||||
|
|
||||||
|
(global-set-key (kbd "<f12>") 'toggle-window-dedicated)
|
||||||
|
@ -56,27 +56,15 @@
|
|||||||
(setq company-minimum-prefix-length 2)
|
(setq company-minimum-prefix-length 2)
|
||||||
|
|
||||||
(global-company-mode)
|
(global-company-mode)
|
||||||
;; (defvar company-mode-whitelist
|
|
||||||
;; '(
|
|
||||||
;; js-mode-hook
|
|
||||||
;; python-mode-hook
|
|
||||||
;; rust-mode-hook
|
|
||||||
;; lisp-mode-hook
|
|
||||||
;; terraform-mode-hook
|
|
||||||
;; org-mode-hook
|
|
||||||
;; ))
|
|
||||||
;; (mapc (lambda (h)
|
|
||||||
;; (add-hook h #'company-mode))
|
|
||||||
;; company-mode-whitelist)
|
|
||||||
|
|
||||||
|
|
||||||
;Set up ace-jump-mode
|
;Set up ace-jump-mode
|
||||||
(autoload 'ace-jump-mode
|
(autoload 'ace-jump-mode
|
||||||
"ace-jump-mode"
|
"ace-jump-mode"
|
||||||
"Emacs quick move minor mode"
|
"Emacs quick move minor mode"
|
||||||
t)
|
t)
|
||||||
(autoload 'ace-jump-mode-pop-mark
|
(autoload 'ace-jump-mode-pop-mark
|
||||||
"ace-jump-mode"
|
"ace-jump-mode"
|
||||||
"Ace jump back:-"
|
"Ace jump back:-"
|
||||||
t)
|
t)
|
||||||
|
|
||||||
@ -85,6 +73,7 @@
|
|||||||
(setq powerline-default-separator
|
(setq powerline-default-separator
|
||||||
'slant)
|
'slant)
|
||||||
|
|
||||||
|
|
||||||
;Configure theme-looper
|
;Configure theme-looper
|
||||||
(theme-looper-set-theme-set '(deeper-blue
|
(theme-looper-set-theme-set '(deeper-blue
|
||||||
wheatgrass
|
wheatgrass
|
||||||
@ -144,3 +133,10 @@
|
|||||||
|
|
||||||
;;flycheck
|
;;flycheck
|
||||||
(setq flycheck-flake8-maximum-line-length 500)
|
(setq flycheck-flake8-maximum-line-length 500)
|
||||||
|
|
||||||
|
|
||||||
|
(add-hook 'prog-mode-hook 'rainbow-delimiters-mode)
|
||||||
|
|
||||||
|
(require 'semantic)
|
||||||
|
(semantic-mode 1)
|
||||||
|
(global-semantic-stickyfunc-mode 1)
|
||||||
|
150
slate.js
150
slate.js
@ -52,6 +52,14 @@ var full = slate.operation("move", {
|
|||||||
width: "screenSizeX",
|
width: "screenSizeX",
|
||||||
height: "screenSizeY"
|
height: "screenSizeY"
|
||||||
});
|
});
|
||||||
|
|
||||||
|
var fullDubble = slate.operation("move", {
|
||||||
|
x: "screenOriginX",
|
||||||
|
y: "screenOriginY",
|
||||||
|
width: "screenSizeX*2",
|
||||||
|
height: "screenSizeY"
|
||||||
|
});
|
||||||
|
|
||||||
var topLeft = S.op("corner", {
|
var topLeft = S.op("corner", {
|
||||||
"direction": "top-left",
|
"direction": "top-left",
|
||||||
"width": "screenSizeX/2",
|
"width": "screenSizeX/2",
|
||||||
@ -60,7 +68,7 @@ var topLeft = S.op("corner", {
|
|||||||
var topLeftShort = S.op("corner", {
|
var topLeftShort = S.op("corner", {
|
||||||
"direction": "top-left",
|
"direction": "top-left",
|
||||||
"width": "screenSizeX/2",
|
"width": "screenSizeX/2",
|
||||||
"height": "screenSizeY/4"
|
"height": "screenSizeY*0.40"
|
||||||
});
|
});
|
||||||
|
|
||||||
var topRight = S.op("corner", {
|
var topRight = S.op("corner", {
|
||||||
@ -76,7 +84,7 @@ var bottomLeft = S.op("corner", {
|
|||||||
var bottomLeftTall = S.op("corner", {
|
var bottomLeftTall = S.op("corner", {
|
||||||
"direction": "bottom-left",
|
"direction": "bottom-left",
|
||||||
"width": "screenSizeX/2",
|
"width": "screenSizeX/2",
|
||||||
"height": "screenSizeY*0.63"
|
"height": "screenSizeY*0.6"
|
||||||
});
|
});
|
||||||
|
|
||||||
var bottomRight = S.op("corner", {
|
var bottomRight = S.op("corner", {
|
||||||
@ -196,6 +204,14 @@ var threeMonitorLayout = slate.layout("threeMonitor", {
|
|||||||
"repeat": true,
|
"repeat": true,
|
||||||
"ignore-fail": true
|
"ignore-fail": true
|
||||||
},
|
},
|
||||||
|
"Firefox": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen1);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"repeat": true,
|
||||||
|
"ignore-fail": true
|
||||||
|
},
|
||||||
"PyCharm Community Edition": {
|
"PyCharm Community Edition": {
|
||||||
"operations": [function(wo) {
|
"operations": [function(wo) {
|
||||||
wo.doOperation(moveScreen2);
|
wo.doOperation(moveScreen2);
|
||||||
@ -234,10 +250,129 @@ var threeMonitorLayout = slate.layout("threeMonitor", {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
var fourMonitorLayout = slate.layout("fourMonitor", {
|
||||||
|
"Slack": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen0);
|
||||||
|
wo.doOperation(topLeftShort);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": true,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"Microsoft Outlook": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen0);
|
||||||
|
wo.doOperation(bottomLeftTall);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": false,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"Google Play Music Desktop Player": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen0);
|
||||||
|
wo.doOperation(bottomRight);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": false,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"VMware Fusion": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen1);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": true,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"Google Chrome": {
|
||||||
|
"operations": [googleChromeLayout],
|
||||||
|
"repeat": true,
|
||||||
|
"ignore-fail": true
|
||||||
|
},
|
||||||
|
"Firefox": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen0);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"repeat": true,
|
||||||
|
"ignore-fail": true
|
||||||
|
},
|
||||||
|
"PyCharm Community Edition": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen2);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": true,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"WebStorm": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen2);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": true,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"Xcode": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen2);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": true,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"Android Studio": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen2);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": true,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"Emacs": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen3);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": true,
|
||||||
|
"repeat": true
|
||||||
|
},
|
||||||
|
"iTerm2": {
|
||||||
|
"operations": [function(wo) {
|
||||||
|
wo.doOperation(moveScreen1);
|
||||||
|
wo.doOperation(full);
|
||||||
|
}],
|
||||||
|
"main-first": true,
|
||||||
|
"ignore-fail": true,
|
||||||
|
"repeat": true
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
slate.bind("a:ctrl,alt,cmd", slate.operation("layout", {
|
|
||||||
name: threeMonitorLayout
|
slate.bind("f:ctrl,cmd", fullDubble)
|
||||||
}));
|
|
||||||
|
slate.bind("a:ctrl,alt,cmd", function(wo){
|
||||||
|
|
||||||
|
if (slate.screenCount() == 3) {
|
||||||
|
slate.operation("layout", {
|
||||||
|
name: threeMonitorLayout
|
||||||
|
}).run();
|
||||||
|
}
|
||||||
|
if (slate.screenCount() == 4) {
|
||||||
|
slate.operation("layout", {
|
||||||
|
name: fourMonitorLayout
|
||||||
|
}).run();
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -248,6 +383,11 @@ if (slate.screenCount() == 3) {
|
|||||||
name: threeMonitorLayout
|
name: threeMonitorLayout
|
||||||
}).run();
|
}).run();
|
||||||
}
|
}
|
||||||
|
if (slate.screenCount() == 4) {
|
||||||
|
slate.operation("layout", {
|
||||||
|
name: fourMonitorLayout
|
||||||
|
}).run();
|
||||||
|
}
|
||||||
|
|
||||||
slate.log("screen count " + slate.screenCount());
|
slate.log("screen count " + slate.screenCount());
|
||||||
slate.eachScreen(function(screenObject) {
|
slate.eachScreen(function(screenObject) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user