Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Optimize emacs packaging loading & configuration - Move additional mode-spectific variables into their respective use-package blocks - Re-organize where functions are loaded, with mode-specific functions belonging to their respective use-package blocks - Simplify prog-mode-hook & text-mode-hook customization - Customize trash directory on Mac OS X systems - Lose osx-trash which is s-l-o-w - Customize & simplify auto-complete[1] mode setup. Also, set up auto-complete /before/ yasnippet[2] - Massively simplify yasnippet configuration - Switch keybinding for ace-window[3] - Switch to using arjen grey theme[4] - Switch to using melpa stable[5] where applicable - Disable global-emojify-mode-line-mode since it wrecks havoc with cut-n-paste - I haven't found an excuse to use Go, so don't install go-mode. Hopefully this will change - Don't use ac-php since it's resource intensive. I may readdress this in the future Also, do not accidentally hose network-security.data file Footnotes: [1] https://github.com/auto-complete/auto-complete [2] https://github.com/joaotavora/yasnippet [3] https://github.com/abo-abo/ace-window [4] https://github.com/credmp/arjen-grey-theme [5] http://stable.melpa.org/#/ |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk | v2017.12.16 |
Files: | files | file ages | folders |
SHA1: |
178b66d4b795bc4454b81d7c4ecc1b44 |
User & Date: | cfuhrman 2017-12-16 21:04:43.151 |
Context
2018-02-10
| ||
23:48 | Further customizations of emacs environment (docs/README.org) - Bump copyright - Update list of supported operating systems (emacs.d/init.el) - Install and configure the following packages: + popwin[1] + calfw[2] + geben[3] + go-mode[4] and related packages - Pin the following packages to melpa-stable + all-the-icons + all-the-icons-ivy - Break out all-the-icons-dired and all-the-icons-ivy to their separate use-package blocks - Switch to using php-doc.el for automatically generating PHP documentation blocks (emacs-d/cmf-org-settings.el) - Add journal tag to all journal entries (setup.sh) - Install gocode and gotags to use with go-mode Footnotes: [1] https://github.com/m2ym/popwin-el [2] https://github.com/m2ym/popwin-el [3] https://github.com/ahungry/geben [4] https://github.com/dominikh/go-mode.el check-in: 392bdcb90e user: cfuhrman tags: trunk, v2018.02.11 | |
2017-12-16
| ||
21:04 | Optimize emacs packaging loading & configuration - Move additional mode-spectific variables into their respective use-package blocks - Re-organize where functions are loaded, with mode-specific functions belonging to their respective use-package blocks - Simplify prog-mode-hook & text-mode-hook customization - Customize trash directory on Mac OS X systems - Lose osx-trash which is s-l-o-w - Customize & simplify auto-complete[1] mode setup. Also, set up auto-complete /before/ yasnippet[2] - Massively simplify yasnippet configuration - Switch keybinding for ace-window[3] - Switch to using arjen grey theme[4] - Switch to using melpa stable[5] where applicable - Disable global-emojify-mode-line-mode since it wrecks havoc with cut-n-paste - I haven't found an excuse to use Go, so don't install go-mode. Hopefully this will change - Don't use ac-php since it's resource intensive. I may readdress this in the future Also, do not accidentally hose network-security.data file Footnotes: [1] https://github.com/auto-complete/auto-complete [2] https://github.com/joaotavora/yasnippet [3] https://github.com/abo-abo/ace-window [4] https://github.com/credmp/arjen-grey-theme [5] http://stable.melpa.org/#/ check-in: 178b66d4b7 user: cfuhrman tags: trunk, v2017.12.16 | |
2017-12-03
| ||
21:56 | Sync latest changes from my personal repository (README.org) - Bump Copyright (emacs) - Re-enable installation of vc-fossil for Emacs 25 and greater - Install and configure the following packages: + flyspell-correct-ivy[1] + all-the-icons[2] + all-the-icons-dired[3] + all-the-icons-ivy[4] + which-key[5] + ace-window[6] + highlight-parentheses[7] + flyspell-correct-ivy[8] - Force set fill-column to 80 characters for text-mode - Enable global-emojify-mode-line-mode - Automatically install fonts required for all-the-icons - Use emoji for common modes presented in the mode-line + 💡: beacon Mode + 📔: eldoc mode + 🦋: flycheck-mode + 🄶: ggtags-mode + 🌲: undo-tree + 🅈: yas-minor-mode - Load package archives more intelligently - Massive reworking of yasnippet[9] and auto-complete[10]. - Move mode-specific variables into their own use-package blocks - Bootstrap diminish prior to installation of use-package - Added boiler-plates for (c)perl-mode - Optimize loading of custom files (setup.sh) - Bump Copyright Footnotes: [1] https://github.com/d12frosted/flyspell-correct [2] https://github.com/domtronn/all-the-icons.el [3] https://github.com/jtbm37/all-the-icons-dired [4] https://github.com/asok/all-the-icons-ivy [5] https://github.com/justbur/emacs-which-key [6] https://github.com/abo-abo/ace-window [7] https://github.com/tsdh/highlight-parentheses.el [8] https://github.com/d12frosted/flyspell-correct/blob/master/flyspell-correct-ivy.el [9] https://github.com/joaotavora/yasnippet [10] https://github.com/auto-complete/auto-complete check-in: 3c1101ac0d user: cfuhrman tags: trunk, v2017.12 | |
Changes
Changes to emacs.d/init.el.
︙ | ︙ | |||
85 86 87 88 89 90 91 | '(emerge-combine-versions-template " %b %a ") '(global-hl-line-mode t) '(linum-delay t) '(log-edit-hook (quote (log-edit-show-files))) | < < < < < < < < < < < < < < < > < < < < < < < < < < < < < < < | 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 | '(emerge-combine-versions-template " %b %a ") '(global-hl-line-mode t) '(linum-delay t) '(log-edit-hook (quote (log-edit-show-files))) '(mark-even-if-inactive t) '(mark-holidays-in-calendar t) '(recentf-mode t) '(scroll-bar-mode (quote right)) '(sh-basic-offset 8) '(sh-indent-comment t) '(sh-indent-for-case-alt (quote +)) '(sh-indent-for-case-label 0) '(sh-indent-for-continuation 4) '(sh-indentation 8) '(show-paren-mode 1) '(tramp-default-method "ssh") '(transient-mark-mode 1) '(use-package-concat t) '(user-full-name cmf-full-name) '(user-mail-address cmf-mail-address) ) ;; Load the appropriate customization file based on if we are running ;; under a window system, such as "x" or "ns" (Mac OS X or GNUstep) (if (equal window-system nil) (if (or (string-match "term-256" (getenv "TERM")) (string-match "screen-256" (getenv "TERM"))) (setq custom-file cmf-custom-256) (setq custom-file cmf-custom-16)) (setq custom-file cmf-custom) ) (load custom-file) ;; Programming styles ;; -------------------------------------------------------------------- ;; OpenBSD Coding Style (c-add-style "openbsd" '("bsd" (c-backspace-function . delete-backward-char) (c-syntactic-indentation-in-macros . nil) (c-tab-always-indent . nil) (c-hanging-braces-alist (block-close . c-snug-do-while)) (c-offsets-alist (arglist-cont-nonempty . *) (statement-cont . *)) (indent-tabs-mode . t))) ;; My own style (c-add-style "cmf" '("bsd" (indent-tabs-mode . nil) (c-offsets-alist (statement-cont . (first c-lineup-cascaded-calls +))))) ;; Functions ;; -------------------------------------------------------------------- ;; Function for loading exec paths (defun cmf/update-exec-path (pathlist) "Add given PATHLIST to 'exec-path'." (dolist (path pathlist) (add-to-list 'exec-path path) (setenv "PATH" (concat (getenv "PATH") ":" path))) ) |
︙ | ︙ | |||
202 203 204 205 206 207 208 | (frame-height (1- (frame-height frame)))) ;; The original value added to the `image-height' for the ;; test was 19; however, that causes the test to fail on X11 ;; by about 1.5 -- so use 17 instead. (> frame-height (+ image-height 17)))))) )) | | < < | < | < < | < < < < > < < < < < < > > | < < < < < > > | < < < < < | 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 | (frame-height (1- (frame-height frame)))) ;; The original value added to the `image-height' for the ;; test was 19; however, that causes the test to fail on X11 ;; by about 1.5 -- so use 17 instead. (> frame-height (+ image-height 17)))))) )) ;; Fix for bug involving enriched text mode (if (version< emacs-version "25.3") (eval-after-load "enriched" '(defun enriched-decode-display-prop (start end &optional param) (list start end)))) ;; Hooks ;; -------------------------------------------------------------------- ;; Define a nice programming hook (defun nice-prog-hook () "Enable some sanity for programming source files." (if (>= emacs-major-version 23) (linum-mode t)) (auto-fill-mode t) (eldoc-mode t) (electric-pair-mode t) (font-lock-add-keywords nil '(("\\<\\(FIXME\\|TODO\\|BUG\\|LATER\\):" 1 font-lock-warning-face t))) ) ;; Define a basic hook for sane editing of text documents (defun nice-text-hook () "Hook for sane editing of text documents." (auto-fill-mode t) (footnote-mode t) ) ;; Apply hooks as appropriate (add-hook 'prog-mode-hook 'nice-prog-hook) (add-hook 'text-mode-hook 'nice-text-hook) (add-hook 'text-mode-hook (lambda () (set-fill-column 80))) ;; Macros ;; -------------------------------------------------------------------- (fset 'yes-or-no-p 'y-or-n-p) |
︙ | ︙ | |||
315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 | ;; Use Emacs ls(1) emulation (require 'ls-lisp) ;; Package configuration ;; -------------------------------------------------------------------- (require 'package) (setq package-enable-at-startup nil) (setq package-archives '(("melpa" . "https://melpa.org/packages/") ("melpa-stable" . "https://stable.melpa.org/packages/") ("marmalade" . "https://marmalade-repo.org/packages/") ("gnu" . "http://elpa.gnu.org/packages/")) ) (package-initialize) ;; Boostrap 'diminish' if necessary (unless (package-installed-p 'diminish) | > > > > | | < < < < > > > > > > > > > > | < | | | < < | < < < < < < < < < < < | < < | > > > | | | | > | < < | | > | | | < | | > | | | > > > > > | > > < | | 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 | ;; Use Emacs ls(1) emulation (require 'ls-lisp) ;; Package configuration ;; -------------------------------------------------------------------- ;; ;; package.el installation and configuration ;; (require 'package) (setq package-enable-at-startup nil) (setq package-archives '(("melpa" . "https://melpa.org/packages/") ("melpa-stable" . "https://stable.melpa.org/packages/") ("marmalade" . "https://marmalade-repo.org/packages/") ("gnu" . "http://elpa.gnu.org/packages/")) ) (package-initialize) ;; Boostrap 'diminish' if necessary (unless (package-installed-p 'diminish) (package-refresh-contents) (package-install 'diminish)) ;; Bootstrap 'use-package' if necessary (unless (package-installed-p 'use-package) (package-refresh-contents) (package-install 'use-package)) ;; Enable use-package (eval-when-compile (require 'use-package)) (require 'diminish) (require 'bind-key) ;; ;; OSX Modes (Mac OS X only) ;; (when (eq system-type 'darwin) ;; Set up mac-specific parameters here (setq delete-by-moving-to-trash t mac-option-modifier 'meta trash-directory "~/.Trash/emacs" ) ;; Make sure backup directory exists (if (not (file-exists-p trash-directory)) (make-directory trash-directory)) ;; osx-location (use-package osx-location :ensure t :init (add-hook 'osx-location-changed-hook (lambda () (setq calendar-latitude osx-location-latitude calendar-longitude osx-location-longitude calendar-location-name (format "%s, %s" osx-location-latitude osx-location-longitude) forecast-latitude osx-location-latitude forecast-longitude osx-location-longitude forecast-city (format "%s, %s" osx-location-latitude osx-location-longitude) ) ) ) :config (osx-location-watch) ) ) ;; ;; Generic Packages ;; ;; For use on all operating systems ;; ;; auto-complete (use-package auto-complete :ensure t :ensure ac-ispell :ensure fuzzy :pin melpa-stable :demand :bind (:map ac-complete-mode-map ("\C-n" . ac-next) ("\C-p" . ac-previous) ) :init (add-hook 'text-mode-hook 'ac-ispell-ac-setup) (add-hook 'log-mode-hook 'ac-ispell-ac-setup) :config (ac-config-default) (ac-ispell-setup) (setq ac-fuzzy-enable 1 ) :custom (ac-dwim t) ) ;; yasnippet (use-package yasnippet :ensure t :ensure yasnippet-snippets :pin melpa-stable :init (yas-global-mode 1) :custom (yas-wrap-around-region t) ) ;; ace-window (use-package ace-window :ensure t :pin melpa-stable :config (setq aw-keys '(?a ?s ?d ?f ?g ?h ?j ?k ?l)) :bind ( ("C-x o" . ace-window)) ) ;; all-the-icons (use-package all-the-icons :if window-system :ensure t :ensure all-the-icons-dired |
︙ | ︙ | |||
473 474 475 476 477 478 479 | :defer t :no-require t :mode (("\\.htaccess\\'" . apache-mode) ("access\\.conf\\'" . apache-mode) ("httpd\\.conf\\'" . apache-mode) ("sites-\\(available\\|enabled\\)/" . apache-mode) ("srm\\.conf\\'" . apache-mode)) | | > | | | | < | | < < < < < < < < | < < < < < < < < | | < > | < < > > | | < < | < < < | | | | < < | > > > > | < < > > | | | > | < | < < < | < < > | < < < < < < < | | > > > > > < < < > > > > > > > > > > > | < < | < < < < < < < | | | < < < < < < < | < | < | | > > < < < < < < < < < < < < | | < > < < | | | < < < < | < | | | | < < < | < < < < < < < < < < < < < < < < < < > > > > > | > | | < < > > > > > > > < < > > > < < < < | > | < | | < < | | | | | | | < < < < | < < < < | < < < | | > > < < < < < < < < < < < < > < < < < | < < < | > | > > | | > | | < < | < < < < < < < < < < < < < < < < | | < | < < < < < < < < < < < < < < < < < | | | | | < | | < > | > > | | > > > > > > > > < < < < < | > > > > | | | | | 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 | :defer t :no-require t :mode (("\\.htaccess\\'" . apache-mode) ("access\\.conf\\'" . apache-mode) ("httpd\\.conf\\'" . apache-mode) ("sites-\\(available\\|enabled\\)/" . apache-mode) ("srm\\.conf\\'" . apache-mode)) :init (add-hook 'apache-mode-hook 'nice-prog-hook) ) ;; arjen-grey-theme (use-package arjen-grey-theme :ensure t :if window-system :init (add-to-list 'custom-safe-themes "c74e83f8aa4c78a121b52146eadb792c9facc5b1f02c917e3dbb454fca931223") (load-theme 'arjen-grey t) ) ;; auctex (use-package auctex :ensure t :no-require t ) ;; beacon mode (use-package beacon :ensure t :pin melpa-stable :diminish " 🄱" :init (require 'beacon) :config (beacon-mode 1) ) ;; [c]perl-mode (use-package cperl-mode :mode ("\\.cgi\\'" . cperl-mode) :init (defalias 'perl-mode 'cperl-mode) (add-to-list 'exec-path "~/perl5/bin") :config ;; Functions for perltidy (defun cmf/perltidy-region () "Run perltidy on the current region." (interactive) (save-excursion (shell-command-on-region (point) (mark) "perltidy -q" nil t)) ) (defun cmf/perltidy-defun () "Run perltidy on the current defun." (interactive) (save-excursion (mark-defun) (perltidy-region)) ) :custom (cperl-continued-brace-offset -8) (cperl-continued-statement-offset 4) (cperl-electric-keywords t) (cperl-electric-linefeed t) (cperl-electric-parens nil) (cperl-font-lock t) (cperl-highlight-variables-indiscriminately t) (cperl-indent-level 8) ) ;; crontab-mode (use-package crontab-mode :ensure t :no-require t :mode (("\\.cron\\(tab\\)?\\'" . crontab-mode) ("cron\\(tab\\)?\\." . crontab-mode)) ) ;; eldoc (use-package eldoc :diminish eldoc-mode " Doc" ) ;; emojify (use-package emojify ;; While the melpa version of emojify supports an experimental ;; version of global-emojify-mode-line-mode, enabling this causes ;; issues with cutting & pasting text, so will revisit that option ;; when it becomes more stable. :ensure t :if window-system :pin melpa-stable :config (global-emojify-mode) ) ;; flycheck (use-package flycheck :ensure t :init (global-flycheck-mode) :custom (flycheck-disabled-checkers (quote (php-phpcs))) (flycheck-highlighting-mode 'lines) (flycheck-phpcs-standard "PSR2") ) ;; flyspell (use-package flyspell :ensure t :ensure flyspell-correct-ivy :bind (:map flyspell-mode-map ("C-c ;" . flyspell-correct-previous-word-generic)) :init (require 'flyspell-correct-ivy) (add-hook 'prog-mode-hook 'flyspell-prog-mode) (add-hook 'text-mode-hook 'flyspell-mode) :config (setq-default ispell-program-name "aspell") (ac-flyspell-workaround) ) ;; forecast (if (version< emacs-version "24.4") (message "Forecast requires Emacs version 24.4 or later. Unable to install") (use-package forecast :ensure t :no-require t :custom (forecast-latitude cmf-latitude) (forecast-longitude cmf-longitude) (forecast-city cmf-location-name) (forecast-country "United States") (forecast-units 'us) (forecast-api-key "f78b853ac0c972cccf06e75e21afbe9d") ) ) ;; gited - dired for git branches (use-package gited :ensure t :no-require t :bind ( ("C-x C-g" . gited-list-branches) ) ) ;; ggtags (use-package ggtags :ensure t :diminish ggtags-mode " 🄶" :init (add-hook 'prog-mode-hook (lambda () (ggtags-mode t))) ) ;; highlight-parentheses (use-package highlight-parentheses :ensure t :diminish highlight-parentheses-mode :config (global-highlight-parentheses-mode) ) ;; html-mode (use-package html-mode :mode ("\\.tmpl\\'" . html-mode) ) ;; ivy (use-package ivy :ensure counsel :ensure swiper :diminish ivy-mode :bind ( ("C-s" . swiper) ("C-r" . swiper) ("C-c C-r" . ivy-resume) ("M-x" . counsel-M-x) ("C-x C-f" . counsel-find-file) ("<f1> f" . counsel-describe-function) ("<f1> v" . counsel-describe-variable) ("<f1> l" . counsel-load-library) ("M-i" . counsel-imenu) ("<f2> i" . counsel-info-lookup-symbol) ("<f2> u" . counsel-unicode-char) ("C-c g" . counsel-git) ("C-c j" . counsel-git-grep) ("C-x l" . counsel-locate) ) :init (ivy-mode 1) :custom (ivy-use-virtual-buffers t) (ivy-height 10) (ivy-count-format "(%d/%d) ") ) ;; jinja2-mode (use-package jinja2-mode :ensure t :defer t :mode ("\\.j2\\'" . jinja2-mode) ) ;; json-mode (use-package json-mode :ensure t :init ;; Associated JSON files with nice-prog-hook (add-hook 'json-mode-hook 'nice-prog-hook) ) ;; log-edit-mode (use-package log-edit :mode ( ("COMMIT.*" . log-edit-mode) ("ci-comment" . log-edit-mode) ("bzr_log\\." . log-edit-mode) ("pico\\." . log-edit-mode) ) :init (add-hook 'log-edit-mode-hook 'nice-text-hook) (add-hook 'log-edit-mode-hook 'turn-on-orgstruct++) ) ;; magit (if (version< emacs-version "24.4") (message "Magit requires Emacs version 24.4 or later. Unable to install") (use-package magit :ensure t :bind ("C-x g" . magit-status) ) ) ;; make-mode (use-package make-mode :mode ("[Mm]akefile\\." . makefile-mode) ) ;; nxml-mode (use-package nxml-mode :ensure auto-complete-nxml :mode (("\\.xsd\\'" . xml-mode) ("\\.wsdl\\'" . xml-mode)) :config ;; Under normal circumstances, I would add nice-prog-hook to nxml ;; mode and be done with it. The issue here is that nice-prog-hook ;; includes enabling auto-fill-mode, which wrecks havoc when editing ;; XML files at work. So, create my own hook explicitly disabling ;; auto-fill-mode (defun nice-nxml-hook () "Hook for sane editing of XML files." (if (>= emacs-major-version 23) (linum-mode t)) (auto-fill-mode -1) ) ;; Apply hook (add-hook 'nxml-mode-hook 'nice-nxml-hook) ;; Keystroke for popup help about something at point. (setq auto-complete-nxml-popup-help-key "C-:") ;; Keystroke for toggle on/off automatic completion. (setq auto-complete-nxml-toggle-automatic-key "C-c C-t") ) ;; org-mode (use-package org :ensure org-ac :ensure org-bullets :ensure ox-twbs :bind ( ("C-c l" . org-store-link) ("C-c a" . org-agenda) ("C-c c" . org-capture) ("C-c b" . org-iswitchb) ) :init (require 'org-install) (require 'org-bullets) :config ;; Org-mode settings are kept in a different file (require 'cmf-org-settings) ;; Define a basic hook for sane editing of org-mode documents (defun nice-org-hook () "Hook for sane editing of 'org-mode' documents." (org-defkey org-mode-map "\C-c[" 'org-time-stamp-inactive) (org-ac/setup-current-buffer) (if (equal (car (split-string org-version ".")) 8) (require 'ox-md)) ) ;; Persist org-clock appropriately (org-clock-persistence-insinuate) ;; Org-mode hooks (add-hook 'org-mode-hook 'nice-text-hook) (add-hook 'org-mode-hook 'nice-org-hook) (add-hook 'org-mode-hook (lambda () (org-bullets-mode 1))) ) ;; php-mode (use-package php-mode :ensure t :ensure php-auto-yasnippets :ensure php-eldoc :ensure php-extras :ensure phpcbf :ensure phpunit :no-require t :mode ("\\.php\\'" . php-mode) :bind (:map php-mode-map ("C-c C--" . php-current-class) ("C-c C-=" . php-current-namespace) ("C-c C-y" . 'yas/create-php-snippet) ("C-x p" . 'phpdoc) ) :init (require 'php-ext) (add-hook 'php-mode-hook 'nice-prog-hook) (add-hook 'php-mode-hook (lambda () (subword-mode 1))) :config ;; Load php documentor (load-file "~/.emacs.d/thirdparty/phpdocumentor.el") :custom (php-mode-coding-style (quote psr2)) ;; (php-lineup-cascaded-calls t) (phpcbf-standard "PSR2") ) ;; pretty-lambdada (if (version< emacs-version "24.4") (use-package pretty-lambdada :ensure t :init (require 'pretty-lambdada) :config (pretty-lambda-for-modes) ) ;; Otherwise use built-in prettify mode (global-prettify-symbols-mode t) ) ;; ruby-mode (use-package ruby-mode :init (add-hook 'ruby-mode-hook 'nice-prog-hook) ) ;; sed-mode (use-package sed-mode :ensure t :no-require t :mode ( ("*.sed" . sed-mode) ) ) ;; smart-mode-line (use-package smart-mode-line :ensure t :init (setq sml/no-confirm-load-theme t) (sml/setup) :config (if (equal window-system nil) (progn (sml/apply-theme 'dark) (setq sml/read-only-char " 🔒")) (progn (sml/apply-theme 'dark) (setq sml/read-only-char " 🅛")) (sml/apply-theme 'respectful)) :custom (sml/modified-char "★") ) ;; sql (use-package sql :mode ( ("sql*" . sql-mode)) :init (add-hook 'sql-mode-hook 'nice-prog-hook) ) ;; sudo-edit (use-package sudo-edit :ensure t :no-require t ) ;; twilight-theme (use-package twilight-theme :ensure t :if (equal custom-file cmf-custom-256) :init (load-theme 'twilight t) ) ;; twittering-mode (use-package twittering-mode :ensure t :no-require t :init (add-hook 'twittering-edit-mode-hook 'nice-text-hook) :config (unless (equal window-system nil) (setq twittering-icon-mode t) ) :custom (twittering-display-remaining t) (twittering-timer-interval 900) (twittering-tinyurl-service (quote tinyurl)) (twittering-use-icon-storage t) (twittering-use-master-password t) (twittering-username "wulflock") ) ;; undo-tree (use-package undo-tree :ensure t :diminish " 🆃" :init (add-hook 'prog-mode-hook (lambda () (undo-tree-mode t))) (add-hook 'text-mode-hook (lambda () (undo-tree-mode t))) :custom (undo-tree-visualizer-diff t) (undo-tree-visualizer-timestamps t) ) ;; vc-fossil (use-package vc-fossil :ensure t :init (require 'vc-fossil) :config (add-to-list 'vc-handled-backends 'Fossil) ) ;; which-func (use-package which-func :no-require t :custom (which-function-mode t) ) ;; which-key (use-package which-key :ensure t :pin melpa-stable :config (which-key-mode) ) ;; with-editor (use-package with-editor :no-require t :init (add-hook 'with-editor-mode-hook 'nice-text-hook) (add-hook 'with-editor-mode-hook 'turn-on-orgstruct++) ) ;; xkcd (use-package xkcd :ensure t :if window-system :no-require t ) ;; yaml-mode (use-package yaml-mode :ensure t :no-require t :mode ("\\.sls\\'" . yaml-mode) :init (add-hook 'yaml-mode-hook 'prog-mode-hook) ) ;; Miscellany ;; -------------------------------------------------------------------- ;; Diminished modes that we have to put here as :diminish doesn't seem ;; to want to work :/ (diminish 'yas-minor-mode " 🅈") ;; Do some byte recompilation (byte-recompile-directory (expand-file-name "~/.emacs.d/thirdparty") 0) (byte-recompile-directory (expand-file-name "~/.emacs.d/lisp") 0) ;;; init.el ends here |
Changes to global-excludes.
︙ | ︙ | |||
16 17 18 19 20 21 22 | elpa/ emojis/ eshell/ ext/ ido.last org-clock-save.el recentf | | | 16 17 18 19 20 21 22 23 24 25 26 | elpa/ emojis/ eshell/ ext/ ido.last org-clock-save.el recentf network-security.data tramp/ url/ xkcd/ |