summaryrefslogtreecommitdiff
path: root/dired-conf.el
diff options
context:
space:
mode:
Diffstat (limited to 'dired-conf.el')
-rw-r--r--dired-conf.el44
1 files changed, 43 insertions, 1 deletions
diff --git a/dired-conf.el b/dired-conf.el
index e4aa4b8..c29c937 100644
--- a/dired-conf.el
+++ b/dired-conf.el
@@ -1,11 +1,42 @@
-;;; -*- lexical-binding: t; -*-
+;;; dired-conf.el --- Configurations related to dired -*- lexical-binding: t; -*-
+
+;; Copyright (C) 2021 李俊緯
+
+;; Author: 李俊緯 <mmemmew@gmail.com>
+;; Keywords: data, files, hardware, unix
+
+;; 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
+;; <https://www.gnu.org/licenses/>.
+
+;;; Commentary:
+
+;; This file configures dired and related packages, including
+;; trashed.el.
+
+;;; Code:
+
+;;; normal settings
(require 'dired)
(require 'dired-x)
(require 'files)
+
(set 'insert-directory-program "gls")
+
(set 'dired-listing-switches
"-alh --dired --group-directories-first --time-style=long-iso")
+
(setq dired-dwim-target t)
(add-hook 'dired-mode-hook #'hl-line-mode)
@@ -24,3 +55,14 @@
(require 'image-dired)
(setq image-dired-external-viewer "open")
+
+;;; trash settings
+
+;; I tried the package trashed, but it does not support the trash can
+;; on macOS.
+
+(set 'delete-by-moving-to-trash nil)
+(set 'trash-directory "/Users/durand/.Trash/")
+
+(provide 'dired-conf)
+;;; dired-conf.el ends here