all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Karl Fogel <kfogel@red-bean.com>
To: emacs-devel@gnu.org
Subject: Re: feature proposal? add-change-log-entry does not find the ChangeLog file: change-log-directory-files
Date: Tue, 04 Sep 2018 12:11:58 -0500	[thread overview]
Message-ID: <878t4h4275.fsf@red-bean.com> (raw)
In-Reply-To: <874lf5ft4f.fsf@mat.ucm.es> (Uwe Brauer's message of "Tue, 04 Sep 2018 12:34:56 +0200")

Uwe Brauer <oub@mat.ucm.es> writes:
>My problem is, if I am in a subdirectory of my mercurial (or git)
>repository and run add-change-log-entry, does not open the ChangeLog
>file in the «root» directory but tries to open the none existing
>ChangeLog file in the current subdirectory, which I don't want.
>
>Any ideas how to deal with this situation?
>
>
>I tried to set 
>
>,----
>[+]
>| change-log-directory-files is a variable defined in ‘add-log.el’.
>| Its value is (".bzr" ".git" "../.hg" ".hg" ".svn")
>| Original value was 
>| (".bzr" ".git" ".hg" ".svn")
>`----
>
>Did not help. Is this feature not implemented? By this I mean: suppose
>in a directory under VC, there is only one ChangeLog file in the root
>directory, then if I call add-change-log-entry there is no way to tell
>emacs that he only looks for that file?

A simple proposal:

Have `add-change-log-entry' walk up the tree, starting from the current directory, and use the first ChangeLog file found.  Most of the time, it'll be in the root of the version-controlled tree, but for projects (like Emacs) that have separate ChangeLogs in some subdirectories, the proper ChangeLog would still be found.

When a project wants to start using a ChangeLog in a subdirectory, someone just needs to manually initialize the ChangeLog there (creating it as an empty file would be enough), and afterwards `add-change-log-entry' will do the right thing.

Thoughts?

Best regards,
-Karl



  reply	other threads:[~2018-09-04 17:11 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-04 10:34 feature proposal? add-change-log-entry does not find the ChangeLog file: change-log-directory-files Uwe Brauer
2018-09-04 17:11 ` Karl Fogel [this message]
2018-09-04 17:20 ` Karl Fogel
2018-09-05  8:01   ` Uwe Brauer
2018-09-05 11:07   ` Uwe Brauer
2018-09-05 13:32   ` [SOLVED] (was: feature proposal? add-change-log-entry does not find the ChangeLog file: change-log-directory-files) Uwe Brauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=878t4h4275.fsf@red-bean.com \
    --to=kfogel@red-bean.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.