alternative based on lsp

master
Josha von Gizycki 4 years ago
parent 3ee1c7fb54
commit 26be43256a

3
.gitignore vendored

@ -1,3 +1,4 @@
/* /*
!init.el !custom.el
!lsp-based.el
!.gitignore !.gitignore

@ -0,0 +1,83 @@
(require 'package)
(add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/") t)
(package-initialize)
(setq package-selected-packages '(clojure-mode lsp-mode cider lsp-treemacs flycheck company paredit))
(when (cl-find-if-not #'package-installed-p package-selected-packages)
(package-refresh-contents)
(mapc #'package-install package-selected-packages))
(add-hook 'clojure-mode-hook 'lsp)
(add-hook 'clojurescript-mode-hook 'lsp)
(add-hook 'clojurec-mode-hook 'lsp)
(autoload 'enable-paredit-mode "paredit" "Turn on pseudo-structural editing of Lisp code." t)
(add-hook 'lisp-mode-hook 'enable-paredit-mode)
(add-hook 'clojure-mode-hook 'enable-paredit-mode)
(add-hook 'emacs-lisp-mode-hook 'enable-paredit-mode)
(add-hook 'eval-expression-minibuffer 'enable-paredit-mode)
;(add-hook 'clojure-mode-hook 'clojure-mode-hook)
(add-hook 'less-css-mode-hook 'hs-minor-mode)
(add-hook 'before-save-hook 'delete-trailing-whitespace)
(setq gc-cons-threshold (* 100 1024 1024)
read-process-output-max (* 1024 1024)
treemacs-space-between-root-nodes nil
company-minimum-prefix-length 1
lsp-lens-enable t
lsp-signature-auto-activate nil
lsp-clojure-custom-server-command '("bash" "-c" "~/bin/clojure-lsp")
inhibit-startup-message t
column-number-mode t
;; ido!
ido-enable-flex-matching t
ido-use-filename-at-point nil
; lsp-enable-indentation nil ; uncomment to use cider indentation instead of lsp
; lsp-enable-completion-at-point nil ; uncomment to use cider completion instead of lsp
)
;; ui stuff
(menu-bar-mode -1)
(tool-bar-mode -1)
(show-paren-mode 1)
(global-linum-mode 1)
(ivy-mode 1)
;; indent all the stuff
(global-set-key [f12] 'lsp-format-buffer)
;; custom key bindings
(global-set-key (kbd "C-M-SPC") 'just-one-space)
(global-set-key (kbd "C-x -") 'hs-toggle-hiding)
;; recent files
(recentf-mode 1)
(setq recentf-max-menu-items 25)
(global-set-key "\C-x\ \C-r" 'recentf-open-files)
;; helm - fuzzy matching on M-x
;;(package-initialize)
;;(require 'helm-config)
;;(helm-mode 1)
;;(global-set-key (kbd "M-x") 'helm-M-x)
(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.
'(custom-enabled-themes (quote (misterioso)))
'(initial-frame-alist (quote ((fullscreen . maximized))))
'(package-selected-packages
(quote
(counsel editorconfig which-key idomenu paredit clojure-mode lsp-mode cider lsp-treemacs flycheck company))))
(custom-set-faces
;; custom-set-faces 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.
'(default ((t (:inherit nil :stipple nil :background "#2d3743" :foreground "#e1e1e0" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 100 :width normal :foundry "DAMA" :family "monospace")))))
Loading…
Cancel
Save