From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.help Subject: Re: How specify on the command line which .emacs to use? Date: Sun, 06 Sep 2015 05:41:02 +0300 Message-ID: <8337ys8e2p.fsf@gnu.org> References: NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1441507285 10515 80.91.229.3 (6 Sep 2015 02:41:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 6 Sep 2015 02:41:25 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Sep 06 04:41:15 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZYPtJ-0002Fi-Tv for geh-help-gnu-emacs@m.gmane.org; Sun, 06 Sep 2015 04:41:14 +0200 Original-Received: from localhost ([::1]:44432 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZYPtJ-0001Qc-Rq for geh-help-gnu-emacs@m.gmane.org; Sat, 05 Sep 2015 22:41:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48033) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZYPt7-0001QP-OI for help-gnu-emacs@gnu.org; Sat, 05 Sep 2015 22:41:02 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZYPt2-00069y-OS for help-gnu-emacs@gnu.org; Sat, 05 Sep 2015 22:41:01 -0400 Original-Received: from mtaout25.012.net.il ([80.179.55.181]:47815) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZYPt2-00069i-Gz for help-gnu-emacs@gnu.org; Sat, 05 Sep 2015 22:40:56 -0400 Original-Received: from conversion-daemon.mtaout25.012.net.il by mtaout25.012.net.il (HyperSendmail v2007.08) id <0NU800500HTZ1400@mtaout25.012.net.il> for help-gnu-emacs@gnu.org; Sun, 06 Sep 2015 05:37:36 +0300 (IDT) Original-Received: from HOME-C4E4A596F7 ([84.94.185.246]) by mtaout25.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0NU8005IBHYN4600@mtaout25.012.net.il> for help-gnu-emacs@gnu.org; Sun, 06 Sep 2015 05:37:36 +0300 (IDT) In-reply-to: X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 80.179.55.181 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:107041 Archived-At: > Date: Sat, 5 Sep 2015 19:02:53 -0700 (PDT) > From: BobD > > Is there a way I can specify on the command line which .emacs file to use? > > I am now using this command line: runemacs.exe -q -l /Directory/.emacs > The "-q" means not to use a .emacs file. The "-l" loads the named file. > But the "-q" suppresses saving customizations. > > I'd like something like this: runemacs.exe -dotemacsfile /Directory/.emacs Since you are on Windows, the easiest would be to point the HOME environment variable to the directory where you want to have the .emacs file. If that doesn't fix your problem, please tell more about the reason you need this. Just FYI: loading .emacs via the -l switch does not have the same effect as loading .emacs "normally", when Emacs finds it during startup, because some things you can put in .emacs are only effective during startup.