This commit is contained in:
Frederik Hanghøj Iversen 2021-06-08 11:05:42 +02:00
parent 9d8e9fc4a1
commit 599fc1a0ec

View file

@ -1,4 +1,4 @@
;;; init.el --- Summary ;;; Init.el --- Summary
;;; Commentary: ;;; Commentary:
;;; Initialization ;;; Initialization
;;; Code: ;;; Code:
@ -108,6 +108,10 @@
'(haskell-indentation-where-pre-offset 0) '(haskell-indentation-where-pre-offset 0)
'(haskell-language-extensions (symbol-value 'haskell-language-extensions)) '(haskell-language-extensions (symbol-value 'haskell-language-extensions))
'(haskell-tags-on-save t) '(haskell-tags-on-save t)
'(ido-case-fold nil)
'(ido-enable-dot-prefix t)
'(ido-enter-matching-directory nil)
'(ido-show-dot-for-dired t)
'(idris-interpreter-path "idris2") '(idris-interpreter-path "idris2")
'(idris-semantic-source-highlighting nil) '(idris-semantic-source-highlighting nil)
'(indent-tabs-mode nil) '(indent-tabs-mode nil)
@ -129,17 +133,18 @@
'(org-agenda-files "~/.config/orgmode/agenda_files") '(org-agenda-files "~/.config/orgmode/agenda_files")
'(org-hide-leading-stars t) '(org-hide-leading-stars t)
'(package-selected-packages '(package-selected-packages
'(jsonnet-mode eslint-fix nhexl-mode idris-mode realgud-trepan-ni realgud-node-inspect realgud graphviz-dot-mode rust-mode lsp forge tide origami dhall-mode docker-tramp graphql-mode enh-ruby-mode scala-mode string-inflection prettier-js quelpa typescript-mode visual-fill-column ag ripgrep fill-column-indicator rjsx-mode image+ company org-jira which-key flycheck es-mode lsp-haskell projectile exec-path-from-shell lsp-ui lsp-Mode editorconfig purescript-mode markdown-mode+ ssh-agency dash yaml-mode restart-emacs markdown-mode magit helm haskell-mode haml-mode form-feed dashboard)) '(git-gutter jsonnet-mode eslint-fix nhexl-mode idris-mode realgud-trepan-ni realgud-node-inspect realgud graphviz-dot-mode rust-mode lsp forge tide origami dhall-mode docker-tramp graphql-mode enh-ruby-mode scala-mode string-inflection prettier-js quelpa typescript-mode visual-fill-column ag ripgrep fill-column-indicator rjsx-mode image+ company org-jira which-key flycheck es-mode lsp-haskell projectile exec-path-from-shell lsp-ui lsp-Mode editorconfig purescript-mode markdown-mode+ ssh-agency dash yaml-mode restart-emacs markdown-mode magit helm haskell-mode haml-mode form-feed dashboard))
'(prettier-js-args nil)
'(prettier-js-command "prettier") '(prettier-js-command "prettier")
'(projectile-auto-discover nil)
'(projectile-completion-system 'ido)
'(projectile-globally-ignored-directories '(projectile-globally-ignored-directories
'(".idea" ".ensime_cache" ".eunit" ".git" ".hg" ".fslckout" "_FOSSIL_" ".bzr" "_darcs" ".tox" ".svn" ".stack-work" "node_modules" "vendor")) '(".idea" ".ensime_cache" ".eunit" ".git" ".hg" ".fslckout" "_FOSSIL_" ".bzr" "_darcs" ".tox" ".svn" ".stack-work" "node_modules" "vendor"))
'(projectile-globally-ignored-files '("/TAGS" "/vendor" "/.bundle" "/node_modules")) '(projectile-globally-ignored-files '("/TAGS" "/vendor" "/.bundle" "/node_modules"))
'(projectile-mode t nil (projectile)) '(projectile-known-projects
'(projectile-project-search-path
(seq-filter 'file-directory-p (seq-filter 'file-directory-p
(seq-drop (file-expand-wildcards "~/git/*/*")) t)
(directory-files "~/git" t) '(projectile-mode t nil (projectile))
2)))
'(projectile-switch-project-action 'magit-status) '(projectile-switch-project-action 'magit-status)
'(projectile-use-git-grep t) '(projectile-use-git-grep t)
'(purescript-mode-hook '(turn-on-purescript-indentation)) '(purescript-mode-hook '(turn-on-purescript-indentation))
@ -158,7 +163,17 @@
(format "cd ~/git/zendesk/guide-acceptance-tests && rspec --no-color '%s'" (format "cd ~/git/zendesk/guide-acceptance-tests && rspec --no-color '%s'"
(projectile-get-relative-path-buffer)))) (projectile-get-relative-path-buffer))))
'(safe-local-variable-values '(safe-local-variable-values
'((eval local-set-key '((magit-disabled-section-inserters quote
(magit-insert-status-headers magit-insert-staged-changes forge-insert-pullreqs magit-insert-stashes magit-insert-unpulled-from-upstream magit-insert-unpushed-to-upstream-or-recent))
(magit-disabled-section-inserters quote
(magit-insert-status-headers))
(eval remove-hook 'magit-status-sections-hook 'magit-insert-unpulled-from-upstream)
(eval remove-hook 'magit-status-sections-hook 'magit-insert-stashes)
(eval remove-hook 'magit-status-sections-hook 'forge-insert-pullreqs)
(eval remove-hook 'magit-status-sections-hook 'magit-insert-staged-changes)
(eval remove-hook 'magit-status-sections-hook 'magit-insert-status-headers)
(eval remove-hook 'magit-status-sections-hook 'magit-insert-unpushed-to-upstream-or-recent)
(eval local-set-key
(kbd "C-M-\\") (kbd "C-M-\\")
'prettier-js) 'prettier-js)
(add-to-list 'auto-mode-alist (add-to-list 'auto-mode-alist
@ -206,6 +221,7 @@
'("abstract" "any" "as" "async" "await" "boolean" "bigint" "break" "case" "catch" "class" "const" "constructor" "continue" "declare" "default" "delete" "do" "else" "enum" "export" "extends" "extern" "false" "finally" "for" "function" "from" "goto" "if" "implements" "import" "in" "instanceof" "interface" "keyof" "let" "module" "namespace" "never" "new" "null" "number" "object" "of" "private" "protected" "public" "readonly" "return" "static" "string" "super" "switch" "this" "throw" "true" "try" "type" "typeof" "unknown" "var" "void" "while")) '("abstract" "any" "as" "async" "await" "boolean" "bigint" "break" "case" "catch" "class" "const" "constructor" "continue" "declare" "default" "delete" "do" "else" "enum" "export" "extends" "extern" "false" "finally" "for" "function" "from" "goto" "if" "implements" "import" "in" "instanceof" "interface" "keyof" "let" "module" "namespace" "never" "new" "null" "number" "object" "of" "private" "protected" "public" "readonly" "return" "static" "string" "super" "switch" "this" "throw" "true" "try" "type" "typeof" "unknown" "var" "void" "while"))
'(typescript-indent-level 2) '(typescript-indent-level 2)
'(vc-follow-symlinks nil) '(vc-follow-symlinks nil)
'(warning-suppress-log-types '((comp)))
'(which-key-idle-delay 1e-05) '(which-key-idle-delay 1e-05)
'(window-combination-resize t) '(window-combination-resize t)
'(window-resize-pixelwise t) '(window-resize-pixelwise t)
@ -244,7 +260,8 @@
(defvar extra-libs-root (substitute-in-file-name "$XDG_CONFIG_HOME/emacs/lisp/")) (defvar extra-libs-root (substitute-in-file-name "$XDG_CONFIG_HOME/emacs/lisp/"))
(defvar additional-packages (defvar additional-packages
'((agda2-mode . "agda-mode/") '(
;; (agda2-mode . "agda-mode/")
(psc-ide . "psc-ide/") (psc-ide . "psc-ide/")
;; (org-jira . "org-jira/") ;; (org-jira . "org-jira/")
(jira . "jira/") (jira . "jira/")
@ -312,6 +329,9 @@
'(error ((t (:foreground "Pink" :weight bold)))) '(error ((t (:foreground "Pink" :weight bold))))
'(fixed-pitch-serif ((t (:family "Monospace Serif")))) '(fixed-pitch-serif ((t (:family "Monospace Serif"))))
'(font-lock-comment-face ((t (:foreground "chocolate1")))) '(font-lock-comment-face ((t (:foreground "chocolate1"))))
'(ido-first-match ((t (:inherit completions-common-part))))
'(ido-only-match ((t (:inherit completions-common-part))))
'(ido-subdir ((t nil)))
'(isearch ((t (:background "palevioletred2" :foreground "white")))) '(isearch ((t (:background "palevioletred2" :foreground "white"))))
'(magit-diff-hunk-heading ((t (:inherit lazy-highlight)))) '(magit-diff-hunk-heading ((t (:inherit lazy-highlight))))
'(magit-diff-hunk-heading-highlight ((t (:inherit highlight)))) '(magit-diff-hunk-heading-highlight ((t (:inherit highlight))))
@ -389,8 +409,6 @@
;; ;; (require 'haskell-unicode-input-method) ;; ;; (require 'haskell-unicode-input-method)
(add-to-list 'auto-mode-alist '("\\.js\\'" . js2-mode))
(require 'prettier-js) (require 'prettier-js)
(add-hook (add-hook
@ -413,6 +431,8 @@
(setq js2-global-externs js2-globals) (setq js2-global-externs js2-globals)
(require 'sh-script)
(setq sh-electric-here-document-mode nil)
(add-hook 'sh-mode-hook (add-hook 'sh-mode-hook
(lambda () (lambda ()
(sh-electric-here-document-mode -1) (sh-electric-here-document-mode -1)
@ -424,7 +444,7 @@
;;;; Projectile ;;;; Projectile
(require 'projectile) (require 'projectile)
(projectile-mode +1) (projectile-mode 1)
(define-key projectile-mode-map (kbd "C-c p") 'projectile-command-map) (define-key projectile-mode-map (kbd "C-c p") 'projectile-command-map)
@ -459,7 +479,7 @@
;;;; Magit ;;;; Magit
(require 'magit) (require 'magit)
(global-magit-file-mode t) (cond ((fboundp 'global-magit-file-mode) (global-magit-file-mode t)))
(global-set-key (kbd "C-c g g") 'magit-dispatch) (global-set-key (kbd "C-c g g") 'magit-dispatch)
(global-set-key (kbd "C-c g s") 'magit-status) (global-set-key (kbd "C-c g s") 'magit-status)
(global-set-key (kbd "C-c g f") 'magit-file-dispatch) (global-set-key (kbd "C-c g f") 'magit-file-dispatch)
@ -488,15 +508,16 @@
;; I'm confused about the less worse option here. I think the best ;; I'm confused about the less worse option here. I think the best
;; option is to use smie (the default). ;; option is to use smie (the default).
(setq ruby-use-smie t)
(setq ruby-deep-indent-paren nil) (setq ruby-deep-indent-paren nil)
(setq ruby-align-to-stmt-keywords t) (setq ruby-align-to-stmt-keywords t)
(setq select-enable-clipboard t) (setq select-enable-clipboard t)
(defun fredefox-ruby-mode-hook () (defun fredefox-ruby-mode-hook ()
"Hook to run engaging 'ruby-mode'." "Hook to run engaging 'ruby-mode'."
(require 'chruby)
(require 'zdi)
(chruby-use-corresponding) (chruby-use-corresponding)
(subword-mode t) (subword-mode t)
(zdi-set-compile-command)) (zdi-set-compile-command))
@ -602,4 +623,8 @@ Requires that `sqlformat` is installed."
(interactive "r") (interactive "r")
(sort-regexp-fields nil "\\w+" "\\&" beg end)) (sort-regexp-fields nil "\\w+" "\\&" beg end))
(windmove-default-keybindings)
(global-set-key (kbd "M-u") 'upcase-dwim)
(global-set-key (kbd "M-l") 'downcase-dwim)
;;; init.el ends here ;;; init.el ends here