summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYann Herklotz <git@yannherklotz.com>2022-12-27 16:30:26 +0000
committerYann Herklotz <git@yannherklotz.com>2022-12-27 16:30:26 +0000
commit7a010dab8b5b0cb0d2fb0de3a56b2b35fc943442 (patch)
tree11bbdcd0b56d06b946664725d68b97afd437620b
parent1e63dd1081e6579f29483a80339151505bec1a56 (diff)
downloadorg-zettelkasten-7a010dab8b5b0cb0d2fb0de3a56b2b35fc943442.tar.gz
org-zettelkasten-7a010dab8b5b0cb0d2fb0de3a56b2b35fc943442.zip
Fix warnings when compiling optional extensions
-rw-r--r--org-zettelkasten-consult.el14
-rw-r--r--org-zettelkasten-counsel.el14
-rw-r--r--org-zettelkasten.el4
3 files changed, 8 insertions, 24 deletions
diff --git a/org-zettelkasten-consult.el b/org-zettelkasten-consult.el
index ee974a6..dd5ce55 100644
--- a/org-zettelkasten-consult.el
+++ b/org-zettelkasten-consult.el
@@ -1,14 +1,6 @@
;;; org-zettelkasten-consult.el --- Consult integration for org-zettelkasten -*- lexical-binding: t; -*-
;; Copyright (C) 2022-2023 Yann Herklotz
-;;
-;; Author: Yann Herklotz <yann@ymhg.org>
-;; Maintainer: Yann Herklotz <yann@ymhg.org>
-;; Keywords: files, hypermedia, Org, notes
-;; Homepage: https://git.sr.ht/~ymherklotz/org-zettelkasten
-;; Package-Requires: ((emacs "24.3") (org "9.0") (consult "0.20"))
-
-;; Version: 0.1.0
;; 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
@@ -31,10 +23,10 @@
;;; Code:
-(require 'org)
-(require 'consult)
+(require 'org-zettelkasten)
-(eval-when-compile (defvar org-zettelkasten-directory))
+(eval-when-compile
+ (declare-function consult-ripgrep "ext:consult"))
(defun org-zettelkasten-consult-search-current-id ()
"Use `consult-ripgrep' to search for the current ID in all files."
diff --git a/org-zettelkasten-counsel.el b/org-zettelkasten-counsel.el
index c840658..8810210 100644
--- a/org-zettelkasten-counsel.el
+++ b/org-zettelkasten-counsel.el
@@ -1,14 +1,6 @@
;;; org-zettelkasten-counsel.el --- Counsel integration for org-zettelkasten -*- lexical-binding: t; -*-
;; Copyright (C) 2022-2023 Yann Herklotz
-;;
-;; Author: Yann Herklotz <yann@ymhg.org>
-;; Maintainer: Yann Herklotz <yann@ymhg.org>
-;; Keywords: files, hypermedia, Org, notes
-;; Homepage: https://git.sr.ht/~ymherklotz/org-zettelkasten
-;; Package-Requires: ((emacs "24.3") (org "9.0") (counsel "0.13"))
-
-;; Version: 0.1.0
;; 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
@@ -31,10 +23,10 @@
;;; Code:
-(require 'org)
-(require 'counsel)
+(require 'org-zettelkasten)
-(eval-when-compile (defvar org-zettelkasten-directory))
+(eval-when-compile
+ (declare-function counsel-rg "ext:counsel"))
(defun org-zettelkasten-counsel-search-current-id ()
"Use `counsel-rg' to search for the current ID in all files."
diff --git a/org-zettelkasten.el b/org-zettelkasten.el
index c768227..8982c0a 100644
--- a/org-zettelkasten.el
+++ b/org-zettelkasten.el
@@ -184,9 +184,9 @@ directory."
:lighter " ZK"
:keymap org-zettelkasten-minor-mode-map)
+(provide 'org-zettelkasten)
+
(with-eval-after-load 'consult (require 'org-zettelkasten-consult))
(with-eval-after-load 'counsel (require 'org-zettelkasten-counsel))
-(provide 'org-zettelkasten)
-
;;; org-zettelkasten.el ends here