diff --git a/custom/setup-editing.el b/custom/setup-editing.el index 17ec4dd..cdf770b 100644 --- a/custom/setup-editing.el +++ b/custom/setup-editing.el @@ -98,11 +98,4 @@ (require 'yasnippet) (yas-global-mode 1) -;; Move one window back command -(defun other-window-backward () - "Goto previous window" - (interactive) - (other-window -1)) -(global-set-key (kbd "\C-x p") 'other-window-backward) - (provide 'setup-editing) diff --git a/custom/setup-general.el b/custom/setup-general.el index 1d4563a..b7404bd 100644 --- a/custom/setup-general.el +++ b/custom/setup-general.el @@ -2,4 +2,51 @@ (global-set-key [f10] 'end-kbd-macro) (global-set-key [f11] 'call-last-kbd-macro) + +;; Package zygospore --- revert C-x 1 by pressing C-x 1 again +;; Doesn't work with sr-speedbar +(global-set-key (kbd "C-x 1") 'zygospore-toggle-delete-other-windows) + +;; Set 'M-g' to 'goto-line', it's faster and what we usually want +(global-set-key (kbd "M-g") 'goto-line) + +;; Set 'C-x r i' to 'string-insert-rectangle' +;; Easier than using 'M-x' and searching for it. +(global-set-key (kbd "C-x r i") 'string-insert-rectangle) + +;; hide the welcome screen +(setq inhibit-startup-message t) + +;; set garbage collection to higher value +;; see http://bling.github.io/blog/2016/01/18/why-are-you-changing-gc-cons-threshold/ +(setq gc-cons-threshold 100000000) + +;; important yes-or-no questions can be answered with y-or-n +(defalias 'yes-or-no-p 'y-or-n-p) + +;; maximize Emacs at startup +(add-to-list 'default-frame-alist '(fullscreen . maximized)) + +;; Save Emacs session +(desktop-save-mode 1) + +;; Move one window back command +(defun other-window-backward () + "Goto previous window" + (interactive) + (other-window -1)) +(global-set-key (kbd "\C-x p") 'other-window-backward) + +;; set my theme +(load-theme 'wombat) + +;; highlight line (hl-line) +(global-hl-line-mode 1) +(set-face-background hl-line-face "dark slate grey") + +;; smart mode line +(setq sml/no-confirm-load-theme t) +(setq sml/theme 'powerline) +(sml/setup) + (provide 'setup-general) diff --git a/custom/setup-org.el b/custom/setup-org.el new file mode 100644 index 0000000..d40ed36 --- /dev/null +++ b/custom/setup-org.el @@ -0,0 +1,3 @@ +;; TODO + +(provide 'setup-org) diff --git a/init.el b/init.el index a26e18b..15aeead 100644 --- a/init.el +++ b/init.el @@ -1,21 +1,3 @@ -;; hide the welcome screen -(setq inhibit-startup-message t) - -;; set garbage collection to higher value -;; see http://bling.github.io/blog/2016/01/18/why-are-you-changing-gc-cons-threshold/ -(setq gc-cons-threshold 100000000) - -;; important yes-or-no questions can be answered with y-or-n -(defalias 'yes-or-no-p 'y-or-n-p) - -;; set my theme -(load-theme 'wombat) - -;; maximize Emacs at startup -(add-to-list 'default-frame-alist '(fullscreen . maximized)) - -;; Save Emacs session -(desktop-save-mode 1) ;; add the custom dir to our load path (add-to-list 'load-path "~/.emacs.d/custom") @@ -51,7 +33,10 @@ flycheck-irony elpy py-autopep8 - magit + magit + org + smart-mode-line + smart-mode-line-powerline-theme helm helm-gtags helm-swoop @@ -74,12 +59,17 @@ ;; setup general (require 'setup-general) +;; setup general editing settings +(require 'setup-editing) + +;; setup org +(require 'setup-org) + ;; setup coding (require 'setup-coding) ;; setup gtags (require 'setup-gtags) -(require 'setup-editing) ;; setup helm (require 'setup-helm) @@ -91,23 +81,45 @@ ;; setup autocompletion (require 'setup-autocompletion) -;; Package zygospore --- revert C-x 1 by pressing C-x 1 again -;; Doesn't work with sr-speedbar -(global-set-key (kbd "C-x 1") 'zygospore-toggle-delete-other-windows) - -;; Set 'M-g' to 'goto-line', it's faster and what we usually want -(global-set-key (kbd "M-g") 'goto-line) - -;; Set 'C-x r i' to 'string-insert-rectangle' -;; Easier than using 'M-x' and searching for it. -(global-set-key (kbd "C-x r i") 'string-insert-rectangle) - (custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. - '(package-selected-packages (quote (magit irony-eldoc elpy irony helm-swoop helm)))) + '(ansi-color-faces-vector + [default default default italic underline success warning error]) + '(ansi-color-names-vector + ["#757575" "#CD5542" "#4A8F30" "#7D7C21" "#4170B3" "#9B55C3" "#68A5E9" "gray43"]) + '(custom-safe-themes + (quote + ("84d2f9eeb3f82d619ca4bfffe5f157282f4779732f48a5ac1484d94d5ff5b279" "c74e83f8aa4c78a121b52146eadb792c9facc5b1f02c917e3dbb454fca931223" "3c83b3676d796422704082049fc38b6966bcad960f896669dfc21a7a37a748fa" "938d8c186c4cb9ec4a8d8bc159285e0d0f07bad46edf20aa469a89d0d2a586ea" "6de7c03d614033c0403657409313d5f01202361e35490a3404e33e46663c2596" "ed317c0a3387be628a48c4bbdb316b4fa645a414838149069210b66dd521733f" "1db337246ebc9c083be0d728f8d20913a0f46edc0a00277746ba411c149d7fe5" default))) + '(fci-rule-color "#2e2e2e") + '(global-company-mode t) + '(package-selected-packages + (quote + (ample-zen-theme ample-theme magit irony-eldoc elpy irony helm-swoop helm))) + '(vc-annotate-background "#3b3b3b") + '(vc-annotate-color-map + (quote + ((20 . "#dd5542") + (40 . "#CC5542") + (60 . "#fb8512") + (80 . "#baba36") + (100 . "#bdbc61") + (120 . "#7d7c61") + (140 . "#6abd50") + (160 . "#6aaf50") + (180 . "#6aa350") + (200 . "#6a9550") + (220 . "#6a8550") + (240 . "#6a7550") + (260 . "#9b55c3") + (280 . "#6CA0A3") + (300 . "#528fd1") + (320 . "#5180b3") + (340 . "#6380b3") + (360 . "#DC8CC3")))) + '(vc-annotate-very-old-color "#DC8CC3")) (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful.