[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: New config file
From: |
Harry Putnam |
Subject: |
Re: New config file |
Date: |
Wed, 30 Sep 2009 01:26:15 -0500 |
User-agent: |
Gnus/5.110011 (No Gnus v0.11) Emacs/23.1.50 (gnu/linux) |
Harry Putnam <reader@newsguy.com> writes:
> emacsuser <mekhala.acharya@bms.com> writes:
>
>> It loads an emacs session ((not with the default serttings of .emacs). But I
>> have to type M-x load file, then give .emacs-ks. Only then does the config
>> settings take effect. I wasn't to be able to call .emacs-ks without using
>> load file.
>
> Probably the simplist way would be to create an alias for emacs that
> runs emacs -q -l my.config (Or a function)
>
> The -q tells emacs not to load .emacs... and the -l tells emacs to
> load whatever filename follows.
>
> The alias route would look like this (in .bashrc) (assuming you are using
> bash as your shell)
>
> alias='myem emacs -q -l ~/my.conf' (Use any name (without spaces)
> that you want in place of `myem' and `my.conf'.
>
> I usually prefer functions... but either way if fine. A function would
> look like (in .bashrc.):
>
> myem () { emacs -q -l ~/my.conf; }
>
> Ditto about the names... but the spacing and format need to be exactly
> like that, including the semi-colon... the shell is fussy about functions.
I forgot to mention that with either of those you would need to source
.bashrc after putting one of them in there.
Like this . ~/.bashrc or source ~/.bashrc
You could also just do
emacs -q -l my.conf
But if you are trying to get it simplified and don't want to type all
that each time then an alias or function is the way to go