From mboxrd@z Thu Jan 1 00:00:00 1970 From: Noorul Islam Subject: Re: [PATCH] question about org-agenda-files Date: Fri, 6 Aug 2010 19:44:43 +0530 Message-ID: References: <87zkx087oj.fsf@gnu.org> <4CB19CCB-1A75-41BF-8835-F839AA578624@gmail.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary=000e0cd47c80cef84d048d2849d5 Return-path: Received: from [140.186.70.92] (port=40927 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OhNhX-0008IW-S2 for emacs-orgmode@gnu.org; Fri, 06 Aug 2010 10:15:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OhNh6-0000Ng-VU for emacs-orgmode@gnu.org; Fri, 06 Aug 2010 10:14:46 -0400 Received: from mail-gw0-f41.google.com ([74.125.83.41]:35397) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OhNh6-0000NK-Ra for emacs-orgmode@gnu.org; Fri, 06 Aug 2010 10:14:44 -0400 Received: by gwj16 with SMTP id 16so3806089gwj.0 for ; Fri, 06 Aug 2010 07:14:43 -0700 (PDT) In-Reply-To: <4CB19CCB-1A75-41BF-8835-F839AA578624@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Carsten Dominik Cc: emacs-orgmode@gnu.org, Bastien --000e0cd47c80cef84d048d2849d5 Content-Type: multipart/alternative; boundary=000e0cd47c80cef831048d2849d3 --000e0cd47c80cef831048d2849d3 Content-Type: text/plain; charset=ISO-8859-1 On Fri, Aug 6, 2010 at 4:12 PM, Carsten Dominik wrote: > > On Aug 6, 2010, at 10:30 AM, Bastien wrote: > > Rustom Mody writes: >> >> Why is it that if org-agenda-files is a list the list should have >>> absolute file names whereas when it (points to) a single file >>> containing the names those names are allowed to be relative to >>> org-directory? >>> >> >> I guess this is a small historical contingency. We might indeed allow >> relative filenames when `org-agenda-files' is a list. >> > > I agree and would welcome a patch for this. > > Changing this behavior is going to be a significant one as far as the current users are concerned. I started working towards a patch for this and now I am thinking how not to break existing functionality. Or should we force everyone to be relative to org-directory? Here is the simple patch which straight away expands the file names with org-directory. * org.el: + org-expand-file-list () Expand the list of agenda files in "org-agenda-files" with "org-directory" as base directory. + org-agenda-files () Call org-expand-file-list() if "org-agenda-files" is a list. Thanks and Regards Noorul > - Carsten > > > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode > --000e0cd47c80cef831048d2849d3 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable

On Fri, Aug 6, 2010 at 4:12 PM, Carsten = Dominik <= carsten.dominik@gmail.com> wrote:

On Aug 6, 2010, at 10:30 AM, Bastien wrote:

Rustom Mody <= rustompmody@gmail.com> writes:

Why is it that if org-agenda-files is a list the list should have
absolute file names whereas when it (points to) a single file
containing the names those names are allowed to be relative to
org-directory?

I guess this is a small historical contingency. =A0We might indeed allow relative filenames when `org-agenda-files' is a list.

I agree and would welcome a patch for this.


Changing this behavior is going= to be a significant one as far as the current users are concerned. I start= ed working towards a patch for this and now I am thinking how not to break = existing functionality. Or should we force everyone to be relative to org-d= irectory?

Here is the simple patch which straight away expands th= e file names with org-directory.

* org.el:=A0
=A0=A0+ org-expand-file-list ()
=A0=A0 =A0 Expand the = list of agenda files in "org-agenda-files" with "org-directo= ry" as base directory.
=A0=A0+ org-agenda-files ()
=A0=A0 =A0 Call org-expand= -file-list() if "org-agenda-files" is a list.

Thanks and Regards
Noorul
=A0
- Carsten



_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gn= u.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

--000e0cd47c80cef831048d2849d3-- --000e0cd47c80cef84d048d2849d5 Content-Type: text/plain; charset=US-ASCII; name="org-agenda-files.txt" Content-Disposition: attachment; filename="org-agenda-files.txt" Content-Transfer-Encoding: base64 X-Attachment-Id: f_gcj4a5v20 ZGlmZiAtLWdpdCBhL2xpc3Avb3JnLmVsIGIvbGlzcC9vcmcuZWwKaW5kZXggMTliMjhhMy4uNTMy ZGE4MyAxMDA2NDQKLS0tIGEvbGlzcC9vcmcuZWwKKysrIGIvbGlzcC9vcmcuZWwKQEAgLTE1Mzc5 LDcgKzE1Mzc5LDcgQEAgdXNlZCBieSB0aGUgYWdlbmRhIGZpbGVzLiAgSWYgQVJDSElWRSBpcyBg aWZtb2RlJywgZG8gdGhpcyBvbmx5IGlmCiAJIChjb25kCiAJICAoKGFuZCAobm90IHVucmVzdHJp Y3RlZCkgKGdldCAnb3JnLWFnZW5kYS1maWxlcyAnb3JnLXJlc3RyaWN0KSkpCiAJICAoKHN0cmlu Z3Agb3JnLWFnZW5kYS1maWxlcykgKG9yZy1yZWFkLWFnZW5kYS1maWxlLWxpc3QpKQotCSAgKChs aXN0cCBvcmctYWdlbmRhLWZpbGVzKSBvcmctYWdlbmRhLWZpbGVzKQorCSAgKChsaXN0cCBvcmct YWdlbmRhLWZpbGVzKSAob3JnLWV4cGFuZC1maWxlLWxpc3QpKQogCSAgKHQgKGVycm9yICJJbnZh bGlkIHZhbHVlIG9mIGBvcmctYWdlbmRhLWZpbGVzJyIpKSkpKQogICAgIChzZXRxIGZpbGVzIChh cHBseSAnYXBwZW5kCiAJCSAgICAgICAobWFwY2FyIChsYW1iZGEgKGYpCkBAIC0xNTQ2OCw2ICsx NTQ2OCwxNiBAQCB1bi1leHBhbmRlZCBmaWxlIG5hbWVzLiIKIAkgICAgIGUpKSkKICAgICAgICAo b3JnLXNwbGl0LXN0cmluZyAoYnVmZmVyLXN0cmluZykgIlsgXHRcclxuXSo/W1xyXG5dWyBcdFxy XG5dKiIpKSkpKQogCisoZGVmdW4gb3JnLWV4cGFuZC1maWxlLWxpc3QgKCkKKyAgIkV4cGFuZCB0 aGUgbGlzdCBvZiBhZ2VuZGEgZmlsZXMgaW4gYG9yZy1hZ2VuZGEtZmlsZXMnIHdpdGggCitgb3Jn LWRpcmVjdG9yeScgYXMgYmFzZSBkaXJlY3RvcnkuIgorICAod2hlbiAobGlzdHAgb3JnLWFnZW5k YS1maWxlcykKKyAgICAobWFwY2FyCisgICAgIChsYW1iZGEgKGYpCisgICAgICAgKGxldCAoKGUg KGV4cGFuZC1maWxlLW5hbWUgCisJCSAoc3Vic3RpdHV0ZS1pbi1maWxlLW5hbWUgZikgb3JnLWRp cmVjdG9yeSkpKQorCSBlKSkgb3JnLWFnZW5kYS1maWxlcykpKQorCiA7OzsjIyNhdXRvbG9hZAog KGRlZnVuIG9yZy1jeWNsZS1hZ2VuZGEtZmlsZXMgKCkKICAgIkN5Y2xlIHRocm91Z2ggdGhlIGZp bGVzIGluIGBvcmctYWdlbmRhLWZpbGVzJy4K --000e0cd47c80cef84d048d2849d5 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --000e0cd47c80cef84d048d2849d5--