Move copy path (to wrong file)

This commit is contained in:
Willem van den Ende
2025-05-04 18:18:45 +01:00
parent 0fe0be3ee8
commit b350812edb
2 changed files with 19 additions and 9 deletions
+4 -9
View File
@@ -357,15 +357,6 @@ only the description"
(kill-new markdown-link)
(message "Copied %s" markdown-link)))
(defun qwan/copy-filename ()
"Push the file name of the currently visited buffer to the kill ring."
(interactive)
(unless buffer-file-name
(error "The current buffer doesn't visit a file"))
(kill-new buffer-file-name)
(message "Copied %s" buffer-file-name))
(defun qwan/relative-path-to-attachments (full-path)
(substring full-path (string-search "/attachments" full-path 0)))
(require 'ert)
@@ -454,6 +445,10 @@ only the description"
(add-load-path! "~/.doom.d/mostalive")
(require 'my-org-roam)
(add-load-path! "~/.doom.d/qwan")
(require 'qwan-blog)
;; org-roam v1 port to v2, insert node without opening buffer
(map!
:leader
+15
View File
@@ -0,0 +1,15 @@
;;; qwan/qwan-blog.el -*- lexical-binding: t; -*-
;;;
(provide 'qwan-blog)
(defun qwan/copy-filename ()
"Push the file name of the currently visited buffer to the kill ring."
(interactive)
(unless buffer-file-name
(error "The current buffer doesn't visit a file"))
(kill-new buffer-file-name)
(message "Copied %s" buffer-file-name))