emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#46056: closed (hardcoded ~/.emacs.d in elpa package excorporate)


From: GNU bug Tracking System
Subject: bug#46056: closed (hardcoded ~/.emacs.d in elpa package excorporate)
Date: Sun, 24 Jan 2021 03:17:02 +0000

Your message dated Sat, 23 Jan 2021 22:16:20 -0500
with message-id <m35z3nxbwb.fsf@fitzsim.org>
and subject line Re: bug#46056: hardcoded ~/.emacs.d in elpa package excorporate
has caused the debbugs.gnu.org bug report #46056,
regarding hardcoded ~/.emacs.d in elpa package excorporate
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs@gnu.org.)


-- 
46056: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=46056
GNU Bug Tracking System
Contact help-debbugs@gnu.org with problems
--- Begin Message --- Subject: hardcoded ~/.emacs.d in elpa package excorporate Date: Sat, 23 Jan 2021 19:13:44 +0100 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)
The `excorporate' package hardcodes its diary files to
~/.emacs.d/excorporate, instead of honoring user-emacs-directory.

I've included a small fix:

=== begin diff ===
diff --git a/excorporate-diary.el b/excorporate-diary.el
index 833df3017c..b147bed42d 100644
--- a/excorporate-diary.el
+++ b/excorporate-diary.el
@@ -76,13 +76,17 @@ respectively."
              #'exco-diary-icalendar--add-diary-entry-around))
 
 (defvar excorporate-diary-today-file
-  "~/.emacs.d/excorporate/diary-excorporate-today"
+  (concat
+   (file-name-as-directory user-emacs-directory)
+   "excorporate/diary-excorporate-today")
   "The diary file where Excorporate should save today's meetings.
 This file will be #include'd in `diary-file' by
 `excorporate-diary-enable'.")
 
 (defvar excorporate-diary-transient-file
-  "~/.emacs.d/excorporate/diary-excorporate-transient"
+  (concat
+   (file-name-as-directory user-emacs-directory)
+   "excorporate/diary-excorporate-transient")
   "The diary file where Excorporate should save retrieved meetings.
 This file will be #include'd in `diary-file' by
 `excorporate-diary-enable'.")
[gunnar@titanium excorporate]$ git diff -u
diff --git a/excorporate-diary.el b/excorporate-diary.el
index 833df3017c..b147bed42d 100644
--- a/excorporate-diary.el
+++ b/excorporate-diary.el
@@ -76,13 +76,17 @@ respectively."
              #'exco-diary-icalendar--add-diary-entry-around))
 
 (defvar excorporate-diary-today-file
-  "~/.emacs.d/excorporate/diary-excorporate-today"
+  (concat
+   (file-name-as-directory user-emacs-directory)
+   "excorporate/diary-excorporate-today")
   "The diary file where Excorporate should save today's meetings.
 This file will be #include'd in `diary-file' by
 `excorporate-diary-enable'.")
 
 (defvar excorporate-diary-transient-file
-  "~/.emacs.d/excorporate/diary-excorporate-transient"
+  (concat
+   (file-name-as-directory user-emacs-directory)
+   "excorporate/diary-excorporate-transient")
   "The diary file where Excorporate should save retrieved meetings.
 This file will be #include'd in `diary-file' by
 `excorporate-diary-enable'.")
=== end diff ===


Am I submitting this the right way?

-- 
Gunnar



--- End Message ---
--- Begin Message --- Subject: Re: bug#46056: hardcoded ~/.emacs.d in elpa package excorporate Date: Sat, 23 Jan 2021 22:16:20 -0500 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1.90 (gnu/linux)
Hi Gunnar,

Gunnar Horrigmo <horrigmo@runbox.no> writes:

> "Basil L. Contovounesios" <contovob@tcd.ie> writes:
>
>> Right.  CCing Thomas, the package's maintainer.

Thanks Basil, I might not have seen this otherwise (see postscript).

> Thank you.
>
>> Rather than concatenating file names as strings, better to use
>> locate-user-emacs-file in this case (or expand-file-name in general).
>> See (info "(elisp) Standard File Names").
>
> Good advice! 
>
>> Ideally the patch would include a ChangeLog-style commit message
>> referencing this bug number; see the guidelines in the CONTRIBUTE
>> file[1] at the top of the Emacs source tree.  Otherwise looks fine :).
>>
>> [1]: https://git.savannah.gnu.org/cgit/emacs.git/tree/CONTRIBUTE
>
> Not that Thomas needs my help, but just for my own excercise, is this
> what you prefer?

Thanks for the fix.  I wrote up the ChangeLog and pushed the change, see
attached.  It will be released when Excorporate 0.9.2 hits GNU ELPA
tomorrow or the day after.

Thomas

P.S. The results of the following steps don't include this bug report; I
wonder why:

M-x debbugs-gnu-search RET
Enter search phrase: excorporate RET
Enter attribute: RET

Attachment: 0001-Do-not-hard-code-diary-directory.patch
Description: Text Data


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]