summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/appearance.el3
-rw-r--r--lisp/documents.el40
-rw-r--r--lisp/jakob.el5
-rw-r--r--lisp/shell.el2
-rw-r--r--lisp/window-manager.el6
5 files changed, 28 insertions, 28 deletions
diff --git a/lisp/appearance.el b/lisp/appearance.el
index c0ff65c..004e4d7 100644
--- a/lisp/appearance.el
+++ b/lisp/appearance.el
@@ -6,6 +6,9 @@
;;; Configuration for making Emacs look pretty.
;;;
+(require 'scroll-bar)
+(require 'fringe)
+
;; Use soft wrapping instead of "scrolling" when overflowing the width of a frame.
diff --git a/lisp/documents.el b/lisp/documents.el
index 88d3ba2..55ff72e 100644
--- a/lisp/documents.el
+++ b/lisp/documents.el
@@ -147,43 +147,41 @@ Visits LINK, or if LINK names a subdirectory of
(file-directory-p (concat path "/" subcategory)))
contents))
(categories (if category
- (map 'list
- #'(lambda (subcategory) (concat category "/" subcategory))
- categories)
+ (mapcar #'(lambda (subcategory) (concat category "/" subcategory))
+ categories)
categories)))
(append (if category
- (map 'list #'(lambda (page) (concat category "/" page)) pages)
+ (mapcar #'(lambda (page) (concat category "/" page)) pages)
pages)
categories
- (apply #'append (map 'list #'notes-hierarchy-paths categories)))))
+ (apply #'append (mapcar #'notes-hierarchy-paths categories)))))
(defun notes-hierarchy ()
"Returns every page and category in `notes-directory'.
The result contains lists of the form (NAME PATH IS-PAGE-P), and
does not include files that satisfy the
`notes-file-should-ignore' predicate."
- (map 'list
- #'(lambda (path) (list
- (cond ((cl-search "Index.org" path)
- (let ((name (cl-subseq path 0 -9)))
- (if (string= name "")
- "/"
- name)))
- ((notes-file-is-page path) (cl-subseq path 0 -4))
- (t path))
- (concat notes-directory "/" path)
- (notes-file-is-page path)))
- (notes-hierarchy-paths)))
+ (mapcar #'(lambda (path) (list
+ (cond ((cl-search "Index.org" path)
+ (let ((name (cl-subseq path 0 -9)))
+ (if (string= name "")
+ "/"
+ name)))
+ ((notes-file-is-page path) (cl-subseq path 0 -4))
+ (t path))
+ (concat notes-directory "/" path)
+ (notes-file-is-page path)))
+ (notes-hierarchy-paths)))
(defun notes-page-goto ()
"Interactively find a page in `notes-directory'."
(interactive)
(let* ((hierarchy (notes-hierarchy))
- (hierarchy (cl-remove-if-not #'third hierarchy))
- (name (ivy-read "Find file: " (map 'list #'first hierarchy)))
- (item (cl-find-if #'(lambda (item) (string= name (first item))) hierarchy)))
+ (hierarchy (cl-remove-if-not #'cl-third hierarchy))
+ (name (ivy-read "Find file: " (mapcar #'cl-first hierarchy)))
+ (item (cl-find-if #'(lambda (item) (string= name (cl-first item))) hierarchy)))
(if item
- (find-file (second item))
+ (find-file (cl-second item))
(let ((path (concat notes-directory "/" name ".org")))
(find-file path)))))
diff --git a/lisp/jakob.el b/lisp/jakob.el
index 9082be2..c39f923 100644
--- a/lisp/jakob.el
+++ b/lisp/jakob.el
@@ -38,9 +38,8 @@
"Returns the paths of every password managed by `pass'."
(let ((prefix-length (1+ (length password-store-directory)))
(suffix-length (length ".gpg")))
- (map 'list
- #'(lambda (path) (cl-subseq path prefix-length (- suffix-length)))
- (directory-files-recursively password-store-directory ".gpg$"))))
+ (mapcar #'(lambda (path) (cl-subseq path prefix-length (- suffix-length)))
+ (directory-files-recursively password-store-directory ".gpg$"))))
(defun pass ()
"Prompt for a password and copy it to the clipboard.
diff --git a/lisp/shell.el b/lisp/shell.el
index fa1ee72..843f51e 100644
--- a/lisp/shell.el
+++ b/lisp/shell.el
@@ -162,7 +162,7 @@
(interactive)
(let ((n (* 2 (1- (line-number-at-pos)))))
(goto-char (point-min))
- (while (plusp n)
+ (while (cl-plusp n)
(delete-visual-line)
(setq n (1- n)))
(end-of-line)))
diff --git a/lisp/window-manager.el b/lisp/window-manager.el
index 139943e..1db8d46 100644
--- a/lisp/window-manager.el
+++ b/lisp/window-manager.el
@@ -107,9 +107,9 @@
(when (and exwm-class-name
(string= exwm-class-name "Firefox"))
(exwm-input-set-local-simulation-keys
- (concatenate 'list
- exwm-input-simulation-keys
- '(([?\C-q] . [?\C-w])))))
+ (cl-concatenate 'list
+ exwm-input-simulation-keys
+ '(([?\C-q] . [?\C-w])))))
(when (and exwm-class-name
(string= exwm-class-name "Alacritty"))
(exwm-input-set-local-simulation-keys nil))))

© 2015 - 2026 Jakob L. Kreuze