diff options
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/seam-test.el | 4 | ||||
-rw-r--r-- | lisp/seam.el | 5 |
2 files changed, 6 insertions, 3 deletions
diff --git a/lisp/seam-test.el b/lisp/seam-test.el index cf4f219..9ab1b22 100644 --- a/lisp/seam-test.el +++ b/lisp/seam-test.el @@ -121,9 +121,9 @@ (ert-deftest seam-test-make-note-weird-filename () (should (equal - '("./Weird file name!" ("private/weird-file-name.org")) + '("./Weir'd file name!" ("private/weird-file-name.org")) (seam-test-with-notes () - ((weird "./Weird file name! ")) + ((weird "./Weir'd file name! ")) (list (buffer-name weird) (seam-test-list-files)))))) diff --git a/lisp/seam.el b/lisp/seam.el index 72f12e2..4cc21e7 100644 --- a/lisp/seam.el +++ b/lisp/seam.el @@ -72,7 +72,10 @@ naming. Must be a function taking two arguments: TITLE and TYPE." (mapcar #'car seam-export-alist)) (defun seam-slugify (title) - (downcase (string-join (string-split title "\\W+" t) "-"))) + (setq title (string-replace "'" "" title)) + (setq title (string-split title "\\W+" t)) + (setq title (string-join title "-")) + (downcase title)) (defun seam-lookup-slug (slug) (cl-dolist (type seam-note-types) |