add which-key
This commit is contained in:
5 files changed
+102
No files matched your search
@@ -1,3 +1,7 @@
|
|||||||
/auto-save-list/
|
/auto-save-list/
|
||||||
/transient/
|
/transient/
|
||||||
/elpa/
|
/elpa/
|
||||||
|
/projects
|
||||||
|
/places
|
||||||
|
/ido.last
|
||||||
|
/history
|
||||||
@@ -16,3 +16,6 @@
|
|||||||
[submodule "site-lisp/lazy-load"]
|
[submodule "site-lisp/lazy-load"]
|
||||||
path = site-lisp/lazy-load
|
path = site-lisp/lazy-load
|
||||||
url = https://github.com/manateelazycat/lazy-load.git
|
url = https://github.com/manateelazycat/lazy-load.git
|
||||||
|
[submodule "site-lisp/emacs-which-key"]
|
||||||
|
path = site-lisp/emacs-which-key
|
||||||
|
url = https://github.com/justbur/emacs-which-key.git
|
||||||
@@ -1,3 +1,5 @@
|
|||||||
|
;; -*- coding: utf-8; lexical-binding: t; -*-
|
||||||
|
|
||||||
(defvar creature-gc-cons-threshold
|
(defvar creature-gc-cons-threshold
|
||||||
(if (display-graphic-p) (* 64 1024 1024) (* 16 1024 1024))
|
(if (display-graphic-p) (* 64 1024 1024) (* 16 1024 1024))
|
||||||
"The default value to use for `gc-cons-threshold'.
|
"The default value to use for `gc-cons-threshold'.
|
||||||
@@ -93,12 +95,25 @@ If freezing sometimes, decrease it. If stuttering, increase it.")
|
|||||||
(add-subdirs-to-load-path subdir-path)))))
|
(add-subdirs-to-load-path subdir-path)))))
|
||||||
|
|
||||||
(add-subdirs-to-load-path creature/pkg-dir)
|
(add-subdirs-to-load-path creature/pkg-dir)
|
||||||
|
(add-to-list 'load-path (expand-file-name "lisp" creature/config-dir) t)
|
||||||
|
|
||||||
(require 'lazy-load)
|
(require 'lazy-load)
|
||||||
(lazy-load-global-keys
|
(lazy-load-global-keys
|
||||||
'(("C-x g" . magit-status))
|
'(("C-x g" . magit-status))
|
||||||
"magit")
|
"magit")
|
||||||
|
|
||||||
|
(require 'init-built-in)
|
||||||
|
|
||||||
|
(require 'which-key)
|
||||||
|
(setq which-key-show-early-on-C-h t)
|
||||||
|
(setq which-key-idle-delay 10000)
|
||||||
|
(setq which-key-idle-secondary-delay 0.05)
|
||||||
|
(which-key-mode 'toggle)
|
||||||
|
|
||||||
|
(setq custom-file (expand-file-name "custom.el" creature/cache-dir))
|
||||||
|
(when (file-exists-p custom-file)
|
||||||
|
(load custom-file 'noerror))
|
||||||
|
|
||||||
(add-hook 'emacs-startup-hook
|
(add-hook 'emacs-startup-hook
|
||||||
(lambda ()
|
(lambda ()
|
||||||
(message (emacs-init-time))))
|
(message (emacs-init-time))))
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
;; -*- coding: utf-8; lexical-binding: t; -*-
|
||||||
|
|
||||||
|
;; Encoding
|
||||||
|
(prefer-coding-system 'utf-8)
|
||||||
|
(setq locale-coding-system 'utf-8)
|
||||||
|
(set-language-environment 'utf-8)
|
||||||
|
(set-default-coding-systems 'utf-8)
|
||||||
|
(set-buffer-file-coding-system 'utf-8)
|
||||||
|
(set-clipboard-coding-system 'utf-8)
|
||||||
|
(set-file-name-coding-system 'utf-8)
|
||||||
|
(set-keyboard-coding-system 'utf-8)
|
||||||
|
(set-terminal-coding-system 'utf-8)
|
||||||
|
(set-selection-coding-system 'utf-8)
|
||||||
|
(modify-coding-system-alist 'process "*" 'utf-8)
|
||||||
|
|
||||||
|
;; Don't show prompt when call function
|
||||||
|
(fset 'yes-or-no-p 'y-or-n-p)
|
||||||
|
(put 'erase-buffer 'disabled nil)
|
||||||
|
(put 'narrow-to-page 'disabled nil)
|
||||||
|
(put 'narrow-to-defun 'disable nil)
|
||||||
|
(put 'narrow-to-region 'disabled nil)
|
||||||
|
|
||||||
|
;; Always use space for indentation
|
||||||
|
(setq-default tab-width 4)
|
||||||
|
(setq-default indent-tabs-mode nil)
|
||||||
|
|
||||||
|
;; Highlight trail whitespace
|
||||||
|
(setq show-trailing-whitespace t)
|
||||||
|
|
||||||
|
(global-whitespace-mode 1)
|
||||||
|
|
||||||
|
|
||||||
|
;; Save minibuffer history
|
||||||
|
(savehist-mode)
|
||||||
|
(setq history-length 1000
|
||||||
|
savehist-autosave-interval 60
|
||||||
|
enable-recursive-minibuffers t
|
||||||
|
savehist-additional-variables '(mark-ring
|
||||||
|
global-mark-ring
|
||||||
|
search-ring
|
||||||
|
regexp-search-ring
|
||||||
|
extended-command-history))
|
||||||
|
|
||||||
|
;; Record cursor position for file
|
||||||
|
(save-place-mode)
|
||||||
|
|
||||||
|
;; Delete file directly
|
||||||
|
(setq delete-by-moving-to-trash t)
|
||||||
|
|
||||||
|
;; No backup file
|
||||||
|
(setq make-backup-files nil)
|
||||||
|
|
||||||
|
;; Auto save file
|
||||||
|
(setq auto-save-default t)
|
||||||
|
(setq auto-save-file-name-transforms
|
||||||
|
`((".*" ,temporary-file-directory t)))
|
||||||
|
|
||||||
|
;; Disable bell
|
||||||
|
(setq visible-bell nil
|
||||||
|
ring-bell-function 'ignore)
|
||||||
|
|
||||||
|
;; Keep cursor at end of lines when prev
|
||||||
|
;; position of cursor is at the end.
|
||||||
|
;; Require line-move-visual is nil.
|
||||||
|
;; (setq track-eol t
|
||||||
|
;; line-move-visual nil)
|
||||||
|
|
||||||
|
;; Do not show startup screen
|
||||||
|
(setq inhibit-splash-screen t ; no startup screen
|
||||||
|
x-gtk-use-system-tooltips nil) ; no gtk tooltips
|
||||||
|
|
||||||
|
(electric-pair-mode 1)
|
||||||
|
(electric-quote-mode 1)
|
||||||
|
(electric-indent-mode 1)
|
||||||
|
|
||||||
|
(setq epg-pinentry-mode 'loopback)
|
||||||
|
|
||||||
|
|
||||||
|
(provide 'init-built-in)
|
||||||
Submodule
+1
Submodule site-lisp/emacs-which-key added at 8093644032.
Reference in new issue
Block a user