;;; kkk-eshell.el --- Eshell Config -*- lexical-binding: t; -*- ;; Copyright (C) 2023 Vinicius Teshima ;; Author: Vinicius Teshima ;; This program is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation, either version 3 of the License, or ;; (at your option) any later version. ;; This program is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with this program. If not, see . ;;; Commentary: ;; Eshell Config ;;; Code: (defvar eshell-ls-initial-args '("-lahg" "--group-directories-first" "--color=no")) (defvar kkk-eshell--ls-highlights '(("^drwx.* \\(.*\\)" . (1 'font-lock-string-face)) ("^lrwxrwxrwx\\( *.*? \\)\\{6\\}\\(.*?\\) " . (2 'font-lock-constant-face)) ("^.rwxrwxrwx\\( *.*? \\)\\{6\\}\\(.*\\)" . (2 'font-lock-type-face))) ) (defun kkk-eshell--set-font-lock-default () "Set `font-lock-defaults' to `kkk-eshell--ls-highlights'." (setq font-lock-defaults kkk-eshell--ls-highlights)) (add-hook 'eshell-mode-hook #'kkk-eshell--set-font-lock-default) (provide 'kkk-eshell) ;;; kkk-eshell.el ends here