Temporary, moving from adam-sp
This commit is contained in:
parent
10bf5cdb0c
commit
450f4b01a8
@ -15,23 +15,43 @@
|
|||||||
c-electric-paren
|
c-electric-paren
|
||||||
c-electric-semi&comma
|
c-electric-semi&comma
|
||||||
c-electric-slash
|
c-electric-slash
|
||||||
|
c-electric-star
|
||||||
c-indent-line-or-region
|
c-indent-line-or-region
|
||||||
comment-dwim
|
comment-dwim
|
||||||
|
counsel-yank-pop
|
||||||
|
delete-indentation
|
||||||
|
downcase-region
|
||||||
electric-newline-and-maybe-indent
|
electric-newline-and-maybe-indent
|
||||||
electric-verilog-colon
|
electric-verilog-colon
|
||||||
electric-verilog-semi
|
electric-verilog-semi
|
||||||
electric-verilog-tab
|
electric-verilog-tab
|
||||||
|
ess-smart-comma
|
||||||
|
forward-sexp
|
||||||
|
hydra--universal-argument
|
||||||
hydra-mc/mc/edit-lines
|
hydra-mc/mc/edit-lines
|
||||||
indent-for-tab-command
|
indent-for-tab-command
|
||||||
kill-region
|
kill-region
|
||||||
markdown-exdent-or-delete
|
markdown-exdent-or-delete
|
||||||
|
markdown-outdent-or-delete
|
||||||
|
org-beginning-of-line
|
||||||
|
org-end-of-line
|
||||||
|
org-force-self-insert
|
||||||
|
org-return-indent
|
||||||
|
org-self-insert-command
|
||||||
|
org-yank
|
||||||
reindent-then-newline-and-indent
|
reindent-then-newline-and-indent
|
||||||
|
sgml-slash
|
||||||
|
sh-assignment
|
||||||
yas-expand
|
yas-expand
|
||||||
))
|
))
|
||||||
|
|
||||||
(setq mc/cmds-to-run-once
|
(setq mc/cmds-to-run-once
|
||||||
'(
|
'(
|
||||||
TeX-view
|
TeX-view
|
||||||
|
avy-goto-char
|
||||||
|
counsel-M-x
|
||||||
|
count-lines-page
|
||||||
|
handle-switch-frame
|
||||||
hydra--digit-argument
|
hydra--digit-argument
|
||||||
hydra-mc-manual/body
|
hydra-mc-manual/body
|
||||||
hydra-mc-manual/lambda-<return>
|
hydra-mc-manual/lambda-<return>
|
||||||
|
@ -77,7 +77,12 @@
|
|||||||
(toggle-read-only 1)))
|
(toggle-read-only 1)))
|
||||||
|
|
||||||
(add-hook 'compilation-start-hook
|
(add-hook 'compilation-start-hook
|
||||||
(lambda (x) (setq-local scroll-up-aggressively 0.0))))
|
(lambda (x) (setq-local scroll-up-aggressively 0.0)))
|
||||||
|
(defun compile-chooser (command-alist)
|
||||||
|
(let ((command (ivy-completing-read
|
||||||
|
"Command: " (mapcar 'car command-alist)
|
||||||
|
:require-match t)))
|
||||||
|
(compile (assoc-default command command-alist)))))
|
||||||
|
|
||||||
(use-package verilog-mode
|
(use-package verilog-mode
|
||||||
:defer
|
:defer
|
||||||
@ -90,6 +95,7 @@
|
|||||||
verilog-linter "verilator --lint-only")
|
verilog-linter "verilator --lint-only")
|
||||||
(add-hook 'verilog-mode-hook (lambda () (setq indent-tabs-mode nil)))
|
(add-hook 'verilog-mode-hook (lambda () (setq indent-tabs-mode nil)))
|
||||||
(add-to-list 'company-keywords-alist (cons 'verilog-mode verilog-keywords)))
|
(add-to-list 'company-keywords-alist (cons 'verilog-mode verilog-keywords)))
|
||||||
|
; (font-lock-add-keywords 'verilog-mode '("[0-9]+'[bBdDhH][0-9]+" . '(:foreground "teal"))))
|
||||||
|
|
||||||
(use-package python
|
(use-package python
|
||||||
:defer
|
:defer
|
||||||
@ -175,6 +181,7 @@
|
|||||||
|
|
||||||
(setq org-confirm-babel-evaluate nil)
|
(setq org-confirm-babel-evaluate nil)
|
||||||
(add-to-list 'org-babel-load-languages '(dot . t))
|
(add-to-list 'org-babel-load-languages '(dot . t))
|
||||||
|
(add-to-list 'org-babel-load-languages '(R . t))
|
||||||
(add-to-list 'org-src-lang-modes '("dot" . graphviz-dot)))
|
(add-to-list 'org-src-lang-modes '("dot" . graphviz-dot)))
|
||||||
|
|
||||||
(use-package windmove
|
(use-package windmove
|
||||||
@ -331,6 +338,7 @@
|
|||||||
(use-package cat-mode :quelpa
|
(use-package cat-mode :quelpa
|
||||||
(cat-mode :fetcher github :repo "ad1217/emacs-cat-mode")
|
(cat-mode :fetcher github :repo "ad1217/emacs-cat-mode")
|
||||||
:config
|
:config
|
||||||
|
(load-file "~/.emacs.d/cat-mode/cat-mode.el")
|
||||||
(cat-mode 1)
|
(cat-mode 1)
|
||||||
(bind-key "C-x C-M-C" 'kill-this-cat-kill-terminal)
|
(bind-key "C-x C-M-C" 'kill-this-cat-kill-terminal)
|
||||||
(eval-after-load "ibuffer"
|
(eval-after-load "ibuffer"
|
||||||
@ -356,6 +364,14 @@
|
|||||||
:bind ("C-S-<right>" . forward-mark)
|
:bind ("C-S-<right>" . forward-mark)
|
||||||
:bind ("C-S-<down>" . show-marks))
|
:bind ("C-S-<down>" . show-marks))
|
||||||
|
|
||||||
|
;; (use-package evil :ensure
|
||||||
|
;; :config
|
||||||
|
;; (evil-mode 1))
|
||||||
|
|
||||||
|
(use-package evil-exchange :ensure
|
||||||
|
:config
|
||||||
|
(evil-exchange-install))
|
||||||
|
|
||||||
;;;; optional external packages
|
;;;; optional external packages
|
||||||
(use-package arduino-mode
|
(use-package arduino-mode
|
||||||
:mode "\\.pde\\'"
|
:mode "\\.pde\\'"
|
||||||
@ -406,7 +422,7 @@
|
|||||||
|
|
||||||
(use-package markdown-mode
|
(use-package markdown-mode
|
||||||
:config
|
:config
|
||||||
(setq markdown-command "markdown_py -x markdown.extensions.wikilinks -x markdown.extensions.smarty -x markdown.extensions.extra -x latex -x markdown.extensions.sane_lists -x markdown.extensions.toc -x markdown_checklist.extension -c ~/.emacs.d/markdownConfig.yml"
|
(setq markdown-command "markdown_py -x markdown.extensions.wikilinks -x markdown.extensions.smarty -x markdown.extensions.extra -x markdown.extensions.sane_lists -x markdown.extensions.toc"
|
||||||
markdown-enable-math t)
|
markdown-enable-math t)
|
||||||
:bind (:map markdown-mode-map
|
:bind (:map markdown-mode-map
|
||||||
("<tab>" . markdown-demote)
|
("<tab>" . markdown-demote)
|
||||||
@ -453,9 +469,10 @@
|
|||||||
("^(D) " 0 '(:foreground "light green"))
|
("^(D) " 0 '(:foreground "light green"))
|
||||||
("^(Y) " 0 '(:foreground "light grey"))
|
("^(Y) " 0 '(:foreground "light grey"))
|
||||||
("([A-Z]+)" . font-lock-builtin-face)
|
("([A-Z]+)" . font-lock-builtin-face)
|
||||||
("\\([a-zA-Z0-9_-]+\\):\\([a-zA-Z0-9._-]+\\)" . font-lock-variable-name-face)
|
("\\([a-zA-Z0-9_-]+\\):\\([+a-zA-Z0-9._-]+\\)" . font-lock-variable-name-face)
|
||||||
("+\\w+" . font-lock-function-name-face)
|
(" \\+\\w+" . font-lock-function-name-face)
|
||||||
(" @\\w+" . font-lock-type-face)
|
(" @\\w+" . font-lock-type-face)
|
||||||
|
("\\([/a-zA-Z0-9_-]+\\):\\([+a-zA-Z0-9._-]+\\)" 0 '(:foreground "red"))
|
||||||
("#important" 0 '(:foreground "orange red")) ; special tag
|
("#important" 0 '(:foreground "orange red")) ; special tag
|
||||||
("#waiting" 0 '(:foreground "dark orange")) ; special tag
|
("#waiting" 0 '(:foreground "dark orange")) ; special tag
|
||||||
("#\\w+" . font-lock-comment-face)
|
("#\\w+" . font-lock-comment-face)
|
||||||
@ -469,6 +486,7 @@
|
|||||||
(find-file (concat (match-string 1 line) "/" (match-string 2 line))))))
|
(find-file (concat (match-string 1 line) "/" (match-string 2 line))))))
|
||||||
|
|
||||||
(use-package latex
|
(use-package latex
|
||||||
|
:defer
|
||||||
:bind (:map LaTeX-mode-map
|
:bind (:map LaTeX-mode-map
|
||||||
("C-z" . latex-save-and-compile)
|
("C-z" . latex-save-and-compile)
|
||||||
("C-c e" . tex-close-latex-block))
|
("C-c e" . tex-close-latex-block))
|
||||||
@ -527,7 +545,12 @@
|
|||||||
:config
|
:config
|
||||||
(setq pkgbuild-user-full-name "Adam Goldsmith"
|
(setq pkgbuild-user-full-name "Adam Goldsmith"
|
||||||
pkgbuild-user-mail-address "contact@adamgoldsmith.name"
|
pkgbuild-user-mail-address "contact@adamgoldsmith.name"
|
||||||
pkgbuild-makepkg-command "PKGEXT='.pkg.tar' makepkg -mf"))
|
pkgbuild-makepkg-command "PKGEXT='.pkg.tar' makepkg -mf"
|
||||||
|
pkgbuild-commands `(("namcap package" . "NAME=$(ls *.pkg.tar* | sort | tail -n1); echo \"Running namcap on $NAME\"; namcap $NAME")
|
||||||
|
("namcap pkgbuild" . "namcap PKGBUILD")
|
||||||
|
("makepkg" . ,pkgbuild-makepkg-command)))
|
||||||
|
(defun pkgbuild-compile () (interactive) (compile-chooser pkgbuild-commands))
|
||||||
|
(define-key pkgbuild-mode-map (kbd "C-c z") 'pkgbuild-compile))
|
||||||
|
|
||||||
(use-package mmm-mode
|
(use-package mmm-mode
|
||||||
:config
|
:config
|
||||||
@ -573,6 +596,24 @@
|
|||||||
(setq company-tern-property-marker "⚫")
|
(setq company-tern-property-marker "⚫")
|
||||||
(add-hook 'js2-mode-hook (lambda () (tern-mode t))))
|
(add-hook 'js2-mode-hook (lambda () (tern-mode t))))
|
||||||
|
|
||||||
|
(use-package nm
|
||||||
|
:config
|
||||||
|
(defun nm-read ()
|
||||||
|
"Mark message as read."
|
||||||
|
(interactive)
|
||||||
|
(nm-apply-to-result (lambda (q)
|
||||||
|
(notmuch-tag q '("-unread"))))
|
||||||
|
(nm-update-tags)
|
||||||
|
(forward-line))
|
||||||
|
(define-key nm-mode-map "N" 'nm-read))
|
||||||
|
|
||||||
|
;; (use-package company-emacs-eclim
|
||||||
|
;; :config
|
||||||
|
;; (require 'eclimd)
|
||||||
|
;; (setq eclim-executable "/usr/lib/eclipse/eclim")
|
||||||
|
;; (company-emacs-eclim-setup)
|
||||||
|
;; (global-eclim-mode 1))
|
||||||
|
|
||||||
;;; Local Variables
|
;;; Local Variables
|
||||||
(add-to-list 'safe-local-eval-forms '(outline-hide-body))
|
(add-to-list 'safe-local-eval-forms '(outline-hide-body))
|
||||||
;; Local Variables:
|
;; Local Variables:
|
||||||
|
11
.emacs.d/snippets/c-mode/guards
Normal file
11
.emacs.d/snippets/c-mode/guards
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# -*- mode: snippet; require-final-newline: nil -*-
|
||||||
|
# name: guards
|
||||||
|
# key: gaurds
|
||||||
|
# expand-env: (gaurd-name (upcase (replace-regexp-in-string "\\." "_" (file-name-nondirectory (buffer-file-name)))))
|
||||||
|
# --
|
||||||
|
#ifndef ${1:`(upcase (file-name-nondirectory (file-name-sans-extension (buffer-file-name))))`_H}
|
||||||
|
#define $1
|
||||||
|
|
||||||
|
$0
|
||||||
|
|
||||||
|
#endif /* $1 */
|
Loading…
Reference in New Issue
Block a user