Last active
April 21, 2023 09:33
-
-
Save Tracnac/035bd154e64f4864b4a558abcab60840 to your computer and use it in GitHub Desktop.
Emacs minimal conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(setq package-enable-at-startup nil) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(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. | |
'(auto-save-interval 200) | |
'(auto-save-list-file-prefix "~/.emacs.d/auto-save-list/.saves-") | |
'(auto-save-timeout 20) | |
'(backup-by-copying t) | |
'(backup-directory-alist '(("." . "~/.emacs.d/backup"))) | |
'(bookmark-default-file "~/.emacs.d/bookmark") | |
'(cursor-type '(hbar . 2)) | |
'(delete-old-versions t) | |
'(evil-undo-system 'undo-fu) | |
'(evil-want-fine-undo t) | |
'(find-file-visit-truename t) | |
'(history-delete-duplicates t) | |
'(history-length 50) | |
'(indicate-buffer-boundaries nil) | |
'(inhibit-buffer-choice t) | |
'(inhibit-compacting-font-caches t t) | |
'(inhibit-startup-echo-area-message '(user-login-name)) | |
'(inhibit-startup-screen t) | |
'(iso-transl-char-map nil t) | |
'(kept-new-versions 5) | |
'(kept-old-versions 5) | |
'(kill-ring-max 50) | |
'(make-backup-files t) | |
'(make-pointer-invisible t) | |
'(menu-bar-mode nil) | |
'(mouse-wheel-inhibit-click-time 0) | |
'(mouse-wheel-progressive-speed nil) | |
'(mouse-wheel-scroll-amount '(1 ((shift) . 1) ((meta)) ((control) . text-scale))) | |
'(nano-font-family-monospaced "VictorMono Nerd Font") | |
'(nano-font-family-proportional "Victor Mono") | |
'(nano-font-size 10) | |
'(org-babel-load-languages '((shell . t) (emacs-lisp . t) (C . t) (ocaml . t))) | |
'(org-log-done 'time) | |
'(org-log-done-with-time t) | |
'(package-selected-packages '(use-package)) | |
'(prefer-coding-system 'utf-8) | |
'(recentf-mode nil) | |
'(ring-bell-function 'ignore) | |
'(scroll-bar-mode nil) | |
'(scroll-step 1) | |
'(select-enable-clipboard t) | |
'(set-cursor-color "black") | |
'(set-default-coding-systems 'utf-8) | |
'(set-keyboard-coding-system 'utf-8) | |
'(set-language-environment "English") | |
'(set-terminal-coding-system 'utf-8) | |
'(straight-use-package-by-default t) | |
'(tool-bar-mode nil) | |
'(tooltip-mode nil) | |
'(tramp-backup-directory-alist "~/.emacs.d/tramp") | |
'(undo-limit 67108864) | |
'(undo-outer-limit 1073741824) | |
'(undo-strong-limit 134217728) | |
'(user-full-name "Tracnac") | |
'(user-mail-address "tracnac@devmobs.fr") | |
'(visible-bell nil) | |
'(widget-image-enable nil)) | |
(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. | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; "GNU Emacs T R /\ C N /\ C. Edition" | |
(setq custom-file (expand-file-name "emacs-custom.el" user-emacs-directory)) | |
(load custom-file) | |
(fset 'yes-or-no-p #'y-or-n-p) | |
(fset 'display-startup-echo-area-message #'ignore) | |
(defvar bootstrap-version) | |
(let ((bootstrap-file | |
(expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory)) | |
(bootstrap-version 6)) | |
(unless (file-exists-p bootstrap-file) | |
(with-current-buffer | |
(url-retrieve-synchronously | |
"https://raw.githubusercontent.com/radian-software/straight.el/develop/install.el" | |
'silent 'inhibit-cookies) | |
(goto-char (point-max)) | |
(eval-print-last-sexp))) | |
(load bootstrap-file nil 'nomessage)) | |
(straight-use-package 'use-package) | |
(use-package org) | |
(use-package counsel) | |
(use-package smex) | |
(use-package magit) | |
(use-package flycheck) | |
(use-package helpful) | |
(use-package eshell) | |
(use-package helm) | |
(use-package evil | |
:config | |
(evil-mode 1)) | |
(use-package which-key | |
:config | |
(which-key-mode)) | |
(use-package undo-fu | |
:config | |
(global-unset-key (kbd "C-z")) | |
(global-set-key (kbd "C-z") 'undo-fu-only-undo) | |
(global-set-key (kbd "C-S-z") 'undo-fu-only-redo)) | |
(use-package undo-fu-session | |
:config | |
(setq undo-fu-session-incompatible-files '("/COMMIT_EDITMSG\\'" "/git-rebase-todo\\'")) | |
(undo-fu-session-global-mode)) | |
(use-package smartparens | |
:config | |
(add-hook 'prog-mode-hook #'smartparens-mode)) | |
(use-package rainbow-delimiters | |
:config | |
(add-hook 'prog-mode-hook #'rainbow-delimiters-mode)) | |
(use-package savehist | |
:config | |
(setq savehist-additional-variables | |
'(kill-ring | |
command-history | |
set-variable-value-history | |
custom-variable-history | |
query-replace-history | |
read-expression-history | |
minibuffer-history | |
read-char-history | |
face-name-history | |
bookmark-history | |
file-name-history | |
counsel-M-x-history | |
counsel-minibuffer-history)) | |
(put 'minibuffer-history 'history-length 50) | |
(put 'file-name-history 'history-length 50) | |
(put 'set-variable-value-history 'history-length 25) | |
(put 'custom-variable-history 'history-length 25) | |
(put 'query-replace-history 'history-length 25) | |
(put 'read-expression-history 'history-length 25) | |
(put 'read-char-history 'history-length 25) | |
(put 'face-name-history 'history-length 25) | |
(put 'bookmark-history 'history-length 25) | |
(put 'counsel-M-x-history 'history-length 25) | |
(put 'counsel-minibuffer-history 'history-length 25) | |
(let (message-log-max) | |
(savehist-mode))) | |
(use-package nano-theme | |
:straight (nano-theme :type git :host github :repo "rougier/nano-emacs") | |
:init | |
(require 'nano-base-colors) | |
(require 'nano-faces) | |
:config | |
(require 'nano-faces) | |
(require 'nano-theme) | |
(require 'nano-theme-dark) | |
(require 'nano-theme-light) | |
(require 'nano-modeline) | |
(require 'nano-counsel) | |
(nano-faces) | |
(nano-theme)) | |
(defun unpropertize-kill-ring () | |
(setq kill-ring (mapcar 'substring-no-properties kill-ring))) | |
(add-hook 'kill-emacs-hook 'unpropertize-kill-ring) | |
(setq initial-scratch-message | |
(format "Welcome to GNU Emacs T R /\\ C N /\\ C. Edition\nInitialization time: %s\n\n" | |
(emacs-init-time))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment