Changeset 9bc0481 in dotfiles for emacs/.emacs.d/nil


Ignore:
Timestamp:
Dec 12, 2024, 4:57:35 PM (5 weeks ago)
Author:
Mikhail Kirillov <w96k@…>
Branches:
master
Children:
eb58262
Parents:
f30e1cd
Message:

Update config

File:
1 edited

Legend:

Unmodified
Added
Removed
  • emacs/.emacs.d/nil

    rf30e1cd r9bc0481  
    22
    33(setq package-archives '(("gnu" . "http://elpa.gnu.org/packages/")
    4                    ("melpa" . "http://melpa.org/packages/")))
     4                     ("melpa" . "http://melpa.org/packages/")))
    55
    66(when (< emacs-major-version 27)
     
    88
    99(require 'gnutls)
    10 
    11 (progn
    12     (package-refresh-contents)
    13     (package-install 'avy)
    14     (package-install 'php-mode)
    15     (package-install 'phps-mode)
    16     ;; (package-install 'anzu)
    17     (package-install 'anaconda-mode)
    18     (package-install 'auctex)
    19     ;; (package-install 'rmsbolt)
    20     ;; (package-install 'beginend)
    21     ;; (package-install 'composer)
    22     (package-install 'cinspect)
    23     (package-install 'debian-el)
    24     (package-install 'dpkg-dev-el)
    25     (package-install 'edebug-inline-result)
    26     ;;(package-install 'haskell-mode)
    27     ;;(package-install 'idris-mode)
    28     (package-install 'magit)
    29     (package-install 'git-timemachine)
    30     (package-install 'git-dwim)
    31     (package-install 'gitpatch)
    32     (package-install 'goto-chg)
    33     (package-install 'debbugs)
    34     ;;(package-install 'deft)
    35     ;; (package-install 'direnv)
    36     (package-install 'dumb-jump)
    37     (package-install 'docker)
    38     (package-install 'docker-cli)
    39     (package-install 'docker-tramp)
    40     (package-install 'docker-compose-mode)
    41     (package-install 'org-sql)
    42     ;;(package-install 'eglot)
    43     ;; (package-install 'eglot-java)
    44     ;; (package-install 'mastodon)
    45     ;; (package-install 'exec-path-from-shell)
    46     (package-install 'expand-region)
    47     ;; (package-install 'flymake-php)
    48     (package-install 'flycheck)
    49     (package-install 'flycheck-phpstan)
    50     (package-install 'phpactor)
    51     ;;(package-install 'robe)
    52     (package-install 'geiser)
    53     (package-install 'geiser-guile)
    54     (package-install 'guix)
    55     ;; (package-install 'git-gutter)
    56     ;; (package-install 'gnuplot)
    57     ;;(package-install 'swiper)
    58     ;;(package-install 'sqlite3)
    59     (package-install 'org-roam)
    60     ;; (package-install 'org-roam-ui)
    61     ;; (package-install 'org-download)
    62     ;; (package-install 'org-babel-eval-in-repl)
    63     ;;(package-install 'ob-php)
    64     ;; (package-install 'on-screen)
    65     ;;(package-install 'nix-mode)
    66     (package-install 'pdf-tools)
    67     ;;(package-install 'phpactor)
    68     ;; (package-install 'company-quickhelp)
    69     ;;(package-install 'ac-php)
    70     (package-install 'php-mode)
    71     (package-install 'php-quickhelp)
    72     (package-install 'phan)
    73     ;;(package-install 'php-cs-fixer)
    74     ;; (package-install 'company-php)
    75     ;;(package-install 'php-eldoc)
    76     ;;(package-install 'phps-mode)
    77     (package-install 'realgud)
    78     ;; (package-install 'realgud-xdebug)
    79     ;; (package-install 'kiwix)
    80     ;;(package-install 'sml-mode)
    81     (package-install 'sly)
    82     (package-install 'simple-httpd)
    83     (package-install 'sudo-edit)
    84     ;;(package-install 'treemacs)
    85     (package-install 'undo-tree)
    86     ;; (package-install 'yasnippet)
    87     ;; (package-install 'yasnippet-snippets)
    88     ;; (package-install 'vimrc-mode)
    89     ;; (package-install 'flymake-phpcs)
    90     ;; (package-install 'flymake-phpstan)
    91     ;; (package-install 'no-littering)
    92     (package-install 'web-mode)
    93     ;; (package-install 'which-key)
    94     ;; (package-install 'reverse-im)
    95     (package-install 'imenu-list)
    96     ;; (package-install 'isearch-mb)
    97     (package-install 'visual-fill-column)
    98     ;; (package-install 'browse-kill-ring)
    99     (package-install 'corfu)
    100     ;; (package-install 'inf-ruby)
    101     (package-install 'yaml-mode)
    102     ;; (package-install 'geben)
    103     (package-install 'link-hint)
    104     (package-install 'whole-line-or-region)
    105     (package-install 'quickrun)
    106     ;; (package-install 'psysh)
    107     ;; (package-install 'restclient)
    108     )
    109 
    110 (when (eq window-system 'pgtk)
    111   (pgtk-use-im-context t))
    112 
    113 (when (fboundp 'native-compile-async)
    114     (setq comp-async-compilation t
    115       package-native-compile t
    116 
    117       native-comp-speed 2
    118       native-comp-async-jobs-number 1
    119       comp-num-cpus 2
    120       ;; JIT Compilation
    121       native-comp-deferred-compilation t
    122       ;; AOT Compilation
    123       package-native-compile t
    124       comp-async-report-warnings-errors nil))
    125 
    126 ;; (native-compile-async "~/.emacs.d/elpa/" 'recursively)
    127 (native-compile-async "~/.guix-profile/share/emacs/site-lisp" 'recursively)
    128 
    129 ;; block until native compilation has finished
    130   (while (or comp-files-queue
    131              (> (comp-async-runnings) 0))
    132 
    133 ;; Disable guix autoloading and x resources loading
    134 (setq site-run-file nil)
    13510
    13611(require 'exwm)
     
    13813(exwm-config-example)
    13914
    140 ;; Change mode-line-modes to show only major mode
    141 (defvar mode-line-major-mode
    142   (let ((recursive-edit-help-echo "Recursive edit, type C-M-c to get out"))
    143     (list (propertize "%[" 'help-echo recursive-edit-help-echo)
    144           `(:propertize ("" mode-name)
    145                         help-echo "Major mode\n\
    146     mouse-1: Display major mode menu\n\
    147     mouse-2: Show help for major mode\n\
    148     mouse-3: Toggle minor modes"
    149                         mouse-face mode-line-highlight
    150                         local-map ,mode-line-major-mode-keymap)
    151           '("" mode-line-process)
    152           (propertize "%n" 'help-echo "mouse-2: Remove narrowing from buffer"
    153                       'mouse-face 'mode-line-highlight
    154                       'local-map (make-mode-line-mouse-map
    155                                   'mouse-2 #'mode-line-widen))
    156           (propertize "%]" 'help-echo recursive-edit-help-echo)
    157           " "))
    158   "Mode line construct for displaying major and minor modes.")
    159 
    160 (put 'mode-line-major-mode 'risky-local-variable t)
    161 
    162 ;; Change mode-line-format
    163 (setq-default mode-line-format
    164               '("%e"
    165                 mode-line-front-space
    166                 mode-line-mule-info
    167 
    168                 mode-line-client
    169                 mode-line-modified
    170                 mode-line-remote
    171                 mode-line-frame-identification
    172                 ;; long-path
    173                 mode-line-buffer-identification
    174                 mode-line-misc-info
    175                 "   "
    176                 mode-line-major-mode
    177                 " "
    178                 vc-mode
    179                 "  "
    180 
    181                 mode-line-position
    182                 mode-line-end-spaces
    183                 ))
    184 
    185 ;; Do not resize the frame at this early stage.
    186 (setq frame-inhibit-implied-resize t)
    187 (setq use-dialog-box nil)
    188 
    189 ;;; Disable some gui
    190 (scroll-bar-mode -1)
    191 (tool-bar-mode -1)
    192 (menu-bar-mode -1)
    193 ;;(tooltip-mode -1)
    194 
    195 ;;; Changing emacs default setting through customize
    196 (custom-set-variables
    197  '(fill-column 72)
    198  '(git-gutter:added-sign " ")
    199  '(git-gutter:deleted-sign " ")
    200  '(git-gutter:modified-sign " ")
    201  '(git-gutter:unchanged-sign " ")
    202  '(lsp-headerline-breadcrumb-enable nil)
    203  '(scroll-bar-mode 'nil)
    204  '(scroll-bar-adjust-thumb-portion nil)
    205  '(tool-bar-position 'bottom)
    206  '(tool-bar-style 'both-horiz))
    207 
    208 (custom-set-faces
    209  '(default ((t (:height 140 :family "Jetbrains Mono" :embolden t))))
    210  '(region ((t (:background "gray85"))))
    211  '(mode-line ((t (:background "grey70" :foreground "grey10"))))
    212  '(mode-line-inactive ((t (:inherit mode-line :background "grey90" :foreground "grey20" :box (:line-width (-2 . -2) :color "grey85") :weight light))))
    213  '(mode-line-buffer-id ((t (:weight bold))))
    214  '(mode-line-emphasis ((t (:weight bold))))
    215  '(lsp-modeline-code-actions-face ((t :inherit mode-line :height 100)))
    216  '(tool-bar ((t (:background "grey80" :foreground "grey10"))))
    217  '(fill-column-indicator ((t (:foreground "grey95"))))
    218  '(hl-line ((t (:background "gray95"))))
    219  '(fringe ((t (:background "grey87"))))
    220  '(header-line ((t (:inherit mode-line :background "grey90"))))
    221  '(vertical-border ((t (:foreground "grey90"))))
    222  '(window-divider ((t (:foreground "gray90")))))
    223 
    224 (set-fringe-style (cons 7 7))
    225 
    226 (defun switch-gui ()
    227   "Disable/enable menu-bar and tool-bar."
    228   (interactive)
    229   (if menu-bar-mode
    230       (progn
    231         (menu-bar-mode -1)
    232         (tool-bar-mode -1)
    233         (scroll-bar-mode -1))
    234     (progn
    235       (menu-bar-mode 1)
    236       (tool-bar-mode 1)
    237       (scroll-bar-mode 1))))
    238 
    239 (defun switch-scroll-bar ()
    240   "Disable/enable scroll-bar."
    241   (interactive)
    242   (if scroll-bar-mode
    243       (scroll-bar-mode -1)
    244     (scroll-bar-mode)))
    245 
    246 (define-key global-map (kbd "<f5>") 'switch-gui)
    247 (define-key global-map (kbd "<f8>") 'switch-scroll-bar)
    248 
    249 (provide 'early-init)
    250     ;;; early-init.el ends here
    251 
    252 ;;(add-hook 'prog-mode-hook 'flymake-mode)
     15(add-hook 'prog-mode-hook 'flymake-mode)
    25316
    25417(require 'psalm)
     
    26932    (interactive)
    27033    (let* ((default-directory (php-project-get-root-dir))
    271            (phan-executable (or flycheck-phanclient--phan-executable
    272                                 (if (file-exists-p "vendor/bin/phan")
    273                                     (concat default-directory "vendor/bin/phan")
    274                                   (executable-find "phan"))))
    275            (cmd (list phan-executable "--daemonize-tcp-port" "4846" "--quick")))
    276       (apply #'start-process "PhanDaemon" "*phan daemon*" cmd)))
     34             (phan-executable (or flycheck-phanclient--phan-executable
     35                                  (if (file-exists-p "vendor/bin/phan")
     36                                      (concat default-directory "vendor/bin/phan")
     37                                    (executable-find "phan"))))
     38             (cmd (list phan-executable "--daemonize-tcp-port" "4846" "--quick")))
     39        (apply #'start-process "PhanDaemon" "*phan daemon*" cmd)))
    27740
    27841  (flycheck-define-checker php-phanclient
     
    28952  (add-hook 'prog-mode-hook 'flycheck-mode))
    29053
    291 (when (package-loaded? "treemacs")
    292   (progn
    293     (setq treemacs-width       50
    294           treemacs-show-cursor t
    295           treemacs-position    'right
    296           treemacs-indentation 1
    297           treemacs-tag-follow-mode t
    298           treemacs-fringe-indicator-mode nil)
    299 
    300     (define-key global-map
    301       (kbd "C-x C-d") 'treemacs)))
    302 
    303 (when (package-loaded? "isearch-mb")
    304   (progn
    305     (isearch-mb-mode t)
    306     (global-set-key (kbd "C-s") 'isearch-forward-regexp)
    307     (global-set-key (kbd "C-r") 'isearch-backward-regexp)))
    308 
    309 (when (package-loaded? "browse-kill-ring") 
    310   (define-key global-map (kbd "C-M-y") 'browse-kill-ring))
    311 
    312 (setq path-to-ctags "~/.guix-profile/bin/ctags")
    313 
    314 (defun tags-create (dir-name)
    315   "Create tags file."
    316   (interactive "DDirectory: ")
    317   (shell-command
    318    (format "%s -f TAGS -e -R %s" path-to-ctags
    319            (directory-file-name dir-name))))
    320 
    321 (defun tags-create-python (dir-name)
    322   "Create tags with python interpreter"
    323   (interactive "DDirectory: ")
    324   (shell-command
    325    (format "%s -f TAGS -e -R --fields=+l --languages=python --python-kinds=-iv $(python -c \"import os, sys; print(' '.join('{}'.format(d) for d in sys.path if os.path.isdir(d)))\") %s" path-to-ctags
    326            (directory-file-name dir-name))))
    327 
    32854(when (package-loaded? "realgud")
    32955  (load "~/.emacs.d/site-lisp/realgud-xdebug/realgud-xdebug.el"))
     
    33561  (progn
    33662    (setq corfu-preview-current 'nil
    337           corfu-popupinfo-delay t)
     63            corfu-popupinfo-delay t)
    33864    (corfu-mode 1)
    33965    (corfu-popupinfo-mode 1)
    34066    (defun show-default-completion-buffer ()
    341       (interactive)
    342       (corfu-quit)
    343       (corfu-mode -1)
    344       (completion-at-point)
    345       (corfu-mode 1)
    346       (corfu-popupinfo-mode 1))
     67        (interactive)
     68        (corfu-quit)
     69        (corfu-mode -1)
     70        (completion-at-point)
     71        (corfu-mode 1)
     72        (corfu-popupinfo-mode 1))
    34773    (define-key corfu-map (kbd "M-TAB") 'show-default-completion-buffer)
    34874    (define-key corfu-map (kbd "TAB") 'show-default-completion-buffer)
     
    35278
    35379    (defun corfu-send-shell (&rest _)
    354       "Send completion candidate when inside comint/eshell."
    355       (cond
    356       ((and (derived-mode-p 'eshell-mode) (fboundp 'eshell-send-input))
    357         (eshell-send-input))
    358       ((and (derived-mode-p 'comint-mode)  (fboundp 'comint-send-input))
    359         (comint-send-input))))
     80        "Send completion candidate when inside comint/eshell."
     81        (cond
     82        ((and (derived-mode-p 'eshell-mode) (fboundp 'eshell-send-input))
     83          (eshell-send-input))
     84        ((and (derived-mode-p 'comint-mode)  (fboundp 'comint-send-input))
     85          (comint-send-input))))
    36086
    36187    (advice-add #'corfu-insert :after #'corfu-send-shell)
    36288
    36389    (add-hook 'eshell-mode-hook 'corfu-mode)))
    364 
    365 (setq completion-styles '(basic partial-completion substring flex emacs22)
    366       completion-ignore-case t
    367       read-buffer-completion-ignore-case t
    368       read-file-name-completion-ignore-case t)
    36990
    37091(setq aggressive-completion-delay 0.5)
     
    37798
    37899(setq deft-recursive t
    379       deft-use-filter-string-for-filename t
    380       deft-default-extension "org md"
    381       deft-directory "~/projects/at-w96k/content/digarden")
     100        deft-use-filter-string-for-filename t
     101        deft-default-extension "org md"
     102        deft-directory "~/projects/at-w96k/content/digarden")
    382103
    383104(when (package-loaded? "yasnippet")
     
    405126;; (setq phps-mode-async-process-using-async-el t)
    406127
    407 (desktop-save-mode 1)
    408 
    409 (global-anzu-mode t)
    410 
    411128(load "swiper-autoloads")
    412129(global-set-key (kbd "C-s") 'swiper)
    413130
    414131(setq swiper-include-line-number-in-search t
    415       swiper-use-visual-line t
    416       swiper-stay-on-quit t)
     132        swiper-use-visual-line t
     133        swiper-stay-on-quit t)
    417134
    418135(load "which-key-autoloads")
     
    421138
    422139(setq which-key-side-window-max-width 0.5
    423       which-key-show-remaining-keys t
    424       which-key-max-display-columns 50
    425       which-key-max-description-length 35
    426       which-key-sort-order 'which-key-local-then-key-order
    427       which-key-idle-delay 0.25)
    428 
    429 (add-hook 'prog-mode-hook 'rmsbolt-mode)
     140        which-key-show-remaining-keys t
     141        which-key-max-display-columns 50
     142        which-key-max-description-length 35
     143        which-key-sort-order 'which-key-local-then-key-order
     144        which-key-idle-delay 0.25)
    430145
    431146;; (when (package-loaded? "quickrun")
     
    435150
    436151(setq sly-lisp-implementations
    437       '((clisp ("clisp"))
    438         (cmucl ("cmucl" "-quiet"))
    439         (sbcl ("/opt/sbcl/bin/sbcl") :coding-system utf-8-unix)))
    440 
    441 (load "erlang-autoloads")
     152        '((clisp ("clisp"))
     153          (cmucl ("cmucl" "-quiet"))
     154          (sbcl ("/opt/sbcl/bin/sbcl") :coding-system utf-8-unix)))
    442155
    443156(when (package-loaded? "inf-ruby")
     
    474187;;   (eglot-ensure))
    475188
    476 (with-eval-after-load 'php-mode
    477 
    478   ;; (add-hook 'php-mode-hook #'init-php-mode)
    479   )
    480 
    481 (when (package-loaded? "php-mode")
    482   (progn
    483     (add-hook 'php-mode-hook 'php-enable-symfony2-coding-style)
    484     (setq lsp-intelephense-php-version "8.1.16")
    485     (defvar phpactor-executable "~/.bin/phpactor")
    486     (custom-set-variables '(lsp-phpactor-path "~/usr/local/bin/phpactor"))
    487 
    488     (add-hook 'php-mode-hook
    489               '(lambda ()
    490                  ;; (require 'yasnippet)
    491                  ;; (require 'yasnippet-snippets)
    492 
    493                  (set-fill-column 120)
    494 
    495                  ;; (make-local-variable 'eldoc-documentation-function)
    496                  ;; (setq eldoc-documentation-function
    497                  ;;       'phpactor-hover)
    498                  ;; (yas-minor-mode t)
    499                  (define-key php-mode-map (kbd "C-c h") 'php-quickhelp-at-point)))
    500 
    501     (setq php-manual-path
    502           "~/php/php-manual/"
    503           php-quickhelp-dir "~/php/php-manual/"
    504           php-quickhelp--dest "~/.emacs.d/php-manual/php_manual_en.json")
    505 
    506 
    507     ;; (add-hook 'php-mode-hook
    508     ;;          '(lambda ()
    509     ;;             ;; (auto-complete-mode t)
    510 
    511     ;;             ;; (require 'ac-php)
    512     ;;             (require 'php-quickhelp)
    513     ;;             (require 'company)
    514     ;;             (company-mode t)
    515     ;;             (require 'company-php)
    516     ;;             (require 'company-quickhelp)
    517 
    518     ;;             (require 'yasnippet)
    519     ;;             (require 'yasnippet-snippets)
    520 
    521     ;;             (set (make-local-variable 'company-backends)
    522     ;;                  '((company-ac-php-backend company-dabbrev-code)
    523     ;;                    php-quickhelp-company-php
    524     ;;                    company-capf company-files))
    525 
    526     ;;             (company-quickhelp-mode t)
    527 
    528     ;;             (define-key php-mode-map (kbd "C-M-i") 'company-complete)
    529     ;;             (define-key company-mode-map (kbd "M-TAB") 'company-complete)
    530 
    531     ;;             ;; (setq ac-sources '(ac-source-php php-quickhelp-company-php))
    532     ;;             ;; (setq eldoc-documentation-function
    533     ;;             ;;       'php-quickhelp-eldoc-func)
    534 
    535     ;;             (yas-minor-mode t)
    536 
    537     ;;             ;; (define-key php-mode-map (kbd "C-M-i") 'auto-complete)
    538     ;;             ;; (define-key ac-mode-map (kbd "M-TAB") 'auto-complete)
    539 
    540     ;;             (define-key php-mode-map (kbd "C-c H")
    541     ;;                         'php-local-manual-search)
    542 
    543     ;;             (define-key php-mode-map (kbd "C-c h") 'php-quickhelp-at-point)
    544     ;;             (define-key company-mode-map (kbd "C-c h") 'php-quickhelp-at-point)
    545 
    546     ;;             ;; (define-key php-mode-map (kbd "C-c t") 'ac-php-show-tip)
    547 
    548     ;;             ;; Jump to definition (optional)
    549     ;;             (define-key php-mode-map
    550     ;;                         (kbd "M-.") 'ac-php-find-symbol-at-point)
    551 
    552     ;;             ;; Return back (optional)
    553     ;;             (define-key php-mode-map
    554     ;;                         (kbd "M-,") 'ac-php-location-stack-back)))
    555     ))
     189(use-package php-mode
     190  :bind ("C-c h" . 'php-quickhelp-at-point)
     191  :config
     192
     193  (setq php-manual-path
     194        "~/projects/php-manual/"
     195        php-quickhelp-dir "~/projects/php-manual/"
     196        php-quickhelp--dest "~/projects/php-manual/php_manual_en.json"))
     197
     198
     199;; (add-hook 'php-mode-hook
     200;;              '(lambda ()
     201;;                 ;; (auto-complete-mode t)
     202
     203;;                 ;; (require 'ac-php)
     204;;                 (require 'php-quickhelp)
     205;;                 (require 'company)
     206;;                 (company-mode t)
     207;;                 (require 'company-php)
     208;;                 (require 'company-quickhelp)
     209
     210;;                 (require 'yasnippet)
     211;;                 (require 'yasnippet-snippets)
     212
     213;;                 (set (make-local-variable 'company-backends)
     214;;                      '((company-ac-php-backend company-dabbrev-code)
     215;;                        php-quickhelp-company-php
     216;;                        company-capf company-files))
     217
     218;;                 (company-quickhelp-mode t)
     219
     220;;                 (define-key php-mode-map (kbd "C-M-i") 'company-complete)
     221;;                 (define-key company-mode-map (kbd "M-TAB") 'company-complete)
     222
     223;;                 ;; (setq ac-sources '(ac-source-php php-quickhelp-company-php))
     224;;                 ;; (setq eldoc-documentation-function
     225;;                 ;;       'php-quickhelp-eldoc-func)
     226
     227;;                 (yas-minor-mode t)
     228
     229;;                 ;; (define-key php-mode-map (kbd "C-M-i") 'auto-complete)
     230;;                 ;; (define-key ac-mode-map (kbd "M-TAB") 'auto-complete)
     231
     232;;                 (define-key php-mode-map (kbd "C-c H")
     233;;                             'php-local-manual-search)
     234
     235;;                 (define-key php-mode-map (kbd "C-c h") 'php-quickhelp-at-point)
     236;;                 (define-key company-mode-map (kbd "C-c h") 'php-quickhelp-at-point)
     237
     238;;                 ;; (define-key php-mode-map (kbd "C-c t") 'ac-php-show-tip)
     239
     240;;                 ;; Jump to definition (optional)
     241;;                 (define-key php-mode-map
     242;;                             (kbd "M-.") 'ac-php-find-symbol-at-point)
     243
     244;;                 ;; Return back (optional)
     245;;                 (define-key php-mode-map
     246;;                             (kbd "M-,") 'ac-php-location-stack-back)))
     247))
    556248
    557249(setq phpactor-executable "~/.bin/phpactor")
     
    603295
    604296(setq lsp-sqls-connections
    605       '(((driver . "mysql") (dataSourceName . "dbuser:mangoworms@tcp(localhost:3306)/profile24"))))
     297        '(((driver . "mysql") (dataSourceName . "dbuser:mangoworms@tcp(localhost:3306)/profile24"))))
    606298
    607299(when (package-loaded? "org-sql")
     
    609301
    610302(add-hook 'sql-interactive-mode-hook
    611         (lambda ()
    612           (sql-connect "profile24")
    613           (toggle-truncate-lines t)))
     303          (lambda ()
     304            (sql-connect "profile24")
     305            (toggle-truncate-lines t)))
    614306
    615307(setq sql-connection-alist
    616308    '((profile24
    617       (sql-product 'mysql)
    618       (sql-server "localhost")
    619       (sql-user "dbuser")
    620       (sql-password "123456")
    621       (sql-database "testdb")
    622       (sql-port 3306))))
     309        (sql-product 'mysql)
     310        (sql-server "localhost")
     311        (sql-user "dbuser")
     312        (sql-password "123456")
     313        (sql-database "testdb")
     314        (sql-port 3306))))
    623315
    624316(load "org-ref-autoloads")
     
    628320;; see org-ref for use of these variables
    629321(setq org-ref-bibliography-notes "~/Documents/bibliography/notes.org"
    630       org-ref-default-bibliography '("~/Documents/Bibliography/references.bib")
    631       org-ref-pdf-directory "~/Documents/bibliography/bibtex-pdfs/")
    632 
    633 (when (package-loaded? "mastodon")
    634   (setq mastodon-active-user "w96k"
    635         mastodon-instance-url "https://fosstodon.org/"))
    636 
    637 (global-hl-line-mode 1)
    638 
    639 (add-to-list 'special-display-buffer-names "*Buffer List*")
    640 (setq Buffer-menu-files-only t)
     322        org-ref-default-bibliography '("~/Documents/Bibliography/references.bib")
     323        org-ref-pdf-directory "~/Documents/bibliography/bibtex-pdfs/")
     324
     325(global-hl-line-mode t)
    641326
    642327(setq exec-path-from-shell-variables
    643       '("PATH" "MANPATH"))
     328        '("PATH" "MANPATH"))
    644329
    645330(when (and (memq window-system '(mac ns x))
    646            (not (eq system-type 'berkeley-unix)))
     331             (not (eq system-type 'berkeley-unix)))
    647332  (exec-path-from-shell-initialize))
    648333
     
    656341
    657342(add-hook 'eww-mode-hook
    658           (lambda ()
    659             (set-fill-column 80)
    660             (display-fill-column-indicator-mode)
    661             (visual-fill-column-mode)))
     343            (lambda ()
     344              (set-fill-column 80)
     345              (display-fill-column-indicator-mode)
     346              (visual-fill-column-mode)))
    662347
    663348(add-to-list 'tramp-remote-path 'tramp-own-remote-path)
     
    665350(load "debian-el-autoloads")
    666351(load "dpkg-dev-el-autoloads")
    667 
    668 (package-loaded? "nix")
    669352
    670353(when (package-loaded? "direnv")
     
    674357  (interactive)
    675358  (let ((x (+ (face-attribute 'default :height)
    676               10)))
     359                10)))
    677360    (set-face-attribute 'default nil :height x)
    678361    (set-face-attribute 'mode-line nil :height x)
     
    683366  (interactive)
    684367  (let ((x (- (face-attribute 'default :height)
    685               10)))
     368                10)))
    686369    (set-face-attribute 'default nil :height x)
    687370    (set-face-attribute 'mode-line nil :height x)
     
    700383(interactive)
    701384(x-send-client-message nil 0 nil "_NET_WM_STATE" 32
    702                       ;; if first parameter is '1', can't toggle fullscreen status
    703                       '(1 "_NET_WM_STATE_FULLSCREEN" 0)))
     385                        ;; if first parameter is '1', can't toggle fullscreen status
     386                        '(1 "_NET_WM_STATE_FULLSCREEN" 0)))
    704387
    705388;; Better support for files with long lines
Note: See TracChangeset for help on using the changeset viewer.