From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: PJ Weisberg Newsgroups: gmane.emacs.help Subject: Re: How to specify customized configuration file rather than "~/.emacs" ? Date: Thu, 13 Sep 2012 08:27:46 -0700 Message-ID: References: <87oblaxb84.fsf@gmail.com> <20120913143835.GE32461@kuru.dyndns-at-home.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: ger.gmane.org 1347550078 24348 80.91.229.3 (13 Sep 2012 15:27:58 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 13 Sep 2012 15:27:58 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Suvayu Ali Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Sep 13 17:28:02 2012 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 1TCBKk-0005E1-Ac for geh-help-gnu-emacs@m.gmane.org; Thu, 13 Sep 2012 17:28:02 +0200 Original-Received: from localhost ([::1]:36216 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TCBKg-0004SC-H4 for geh-help-gnu-emacs@m.gmane.org; Thu, 13 Sep 2012 11:27:58 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:39561) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TCBKb-0004S6-5S for help-gnu-emacs@gnu.org; Thu, 13 Sep 2012 11:27:54 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TCBKX-0005o2-2W for help-gnu-emacs@gnu.org; Thu, 13 Sep 2012 11:27:53 -0400 Original-Received: from mail-lb0-f169.google.com ([209.85.217.169]:33418) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TCBKW-0005nv-RT for help-gnu-emacs@gnu.org; Thu, 13 Sep 2012 11:27:49 -0400 Original-Received: by lbon3 with SMTP id n3so2193607lbo.0 for ; Thu, 13 Sep 2012 08:27:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=iHeN2aqd+uTdhZSs0J6wvNzWUaMs64Q5S7h9uXmUoek=; b=N8AvfHDpHoS1WbcICPIFbreCpO1Q5WRoyVrWac9VJ8zvivtKlDwxYLAQmyGqRU4PPP +hqNhsamhTcgPbhEGBLZDWHC3RBGA54AYN4guO/Grz6YG1YKBbMSXedXLA22op833P9o bTTVlcnuY5fz+jQ4dkKpoBjb3uafHy6nzThbtjUscH4Zntq5nBBDMtRfTicjaMi/kKVO rzFIOtJ8juJxRxU9fmtOTbH2YaCB9Pnf7W93pfor1/XRhX8LFj8CZwCodtF+oOxzXOke j2woUjvnAwROY6Z7JiyvKuBpi+D89HL+dTeZRpS/sT++Y4upQPIugfqYIJ71EAXBHmvJ C4tw== Original-Received: by 10.112.25.167 with SMTP id d7mr19616lbg.74.1347550066662; Thu, 13 Sep 2012 08:27:46 -0700 (PDT) Original-Received: by 10.112.48.6 with HTTP; Thu, 13 Sep 2012 08:27:46 -0700 (PDT) In-Reply-To: <20120913143835.GE32461@kuru.dyndns-at-home.com> X-Google-Sender-Auth: i663ofSQyIv-x1e936GGBMgkXPE X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.85.217.169 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:86753 Archived-At: On Thu, Sep 13, 2012 at 7:38 AM, Suvayu Ali wrote: > On Thu, Sep 13, 2012 at 07:42:59PM +0530, Jambunathan K wrote: >> Z C writes: >> >> > I just want emacs to load another file as the configuration file, and >> > ignore the default file ("~/.emacs"). >> > >> > Note that I don't want to change the original "~/.emacs" file. >> > >> > I've tried to change "$HOME" env variable, but it doesn't work. >> > >> >> Load emacs with custom options. >> >> ,---- >> | $ emacs --help | grep load >> | >> | --no-desktop do not load a saved desktop >> | --no-init-file, -q load neither ~/.emacs nor default.el >> | --no-site-file do not load site-start.el >> | --user, -u USER load ~USER/.emacs instead of your own >> | --directory, -L DIR add DIR to variable load-path >> | --load, -l FILE load Emacs Lisp FILE using the load function >> `---- >> > > To elaborate with an example: > > $ emacs -q -l ~/special-config.el > > or, > > $ emacs -Q -l ~/special-config.el You'll probably also want to put (setq user-init-file "~/special-config.el") in that file, or Emacs will refuse to save customizations -PJ Gehm's Corollary to Clark's Law: Any technology distinguishable from magic is insufficiently advanced.