From mboxrd@z Thu Jan 1 00:00:00 1970 From: tsd@tsdye.com (Thomas S. Dye) Subject: Re: Variable settings in .emacs VS cross device portability. Date: Mon, 30 Jan 2012 14:42:39 -1000 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from eggs.gnu.org ([140.186.70.92]:53951) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Rs1oA-0005SU-57 for emacs-orgmode@gnu.org; Mon, 30 Jan 2012 19:42:51 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Rs1o5-0004OU-5Z for emacs-orgmode@gnu.org; Mon, 30 Jan 2012 19:42:50 -0500 Received: from oproxy9.bluehost.com ([69.89.24.6]:36002) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1Rs1o4-0004OL-No for emacs-orgmode@gnu.org; Mon, 30 Jan 2012 19:42:45 -0500 In-Reply-To: (Yu's message of "Mon, 30 Jan 2012 17:13:09 +0100") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Yu Cc: org-mode mailing list Yu writes: > Hello! > > I was wondering if there is a possibility to make org-files fully > portable in behaviour (especially when exporting) between different > emacs installations. > > When reading the mailing list or other writing about org-mode, > commonly suggestions of the type "just add (setq org-foo bar) to your > .emacs". This however creates a dependency on the local setup of the > variables, which likely will be a problem, when sharing the file with > someone. > > My current solution is to use a template file with #+BIND: and > #+PROPERTY: lines in a setup section rather than setting anything in > configuration files. > > However, is there some way to turn a user-variable dependent file into > a portable file? I was thinking of something along the lines of > "dumping user-specified variables into a list of #+BIND lines" and, if > necessary, the magic "-*- var: value -*-" line at the start of the > file (or, less elegant because of spreading options across different > positions in the file) the commented "local variables" structure near > the end of the file. The latter two variants only apply if I am right > about #+BIND lines applying only during export (whereas the magic > emacs lines should create buffer-local bindings). Aloha Yu, I favor Eric Schulte's solution for reproducible research, which you can find here: http://www.jstatsoft.org/v46/i03 The trick is to launch a fresh instance of Emacs and supply it with an initialization file tailored to the content. Eric uses a Makefile for this, and I've been able to copy and tweak his Makefile for use on other projects. hth, Tom -- Thomas S. Dye http://www.tsdye.com