I have my config files in
~/.emacs is symlinked to.
I'm trying to figure out how to make the default "emacs root directory"
$HOME in all contexts (unless overridden by a buffer-local variable), whether launching an ansi terminal, launching dired, or anything like that.
$ ls -al .emacs.d | perl -pe 's/^.*([.]emacs[.]d)/$1/' .emacs.d -> ./config/emacs
.emacs.d/init.el file contains the following snippet in an attempt to force emacs open stuff like
ansi-term in my home directory.
(cd (getenv "HOME"))
How do I change the effective root directory for
ansi-term and everything else?
Here's a complete example that should reproduce the surprising behavior I'm talking about on OS X and Linux.
I have a directory
$ echo '(cd (getenv "HOME"))' > ~/tmp/emacs/cd.el $ cd /tmp $ emacs -q -l ~/tmp/emacs/cd.el
And then from inside
Launch the ansi terminal and accept the default shell
M-x ansi-term C-m C-m
print the current working directory from inside the terminal
$ pwd /tmp
I expected working directory to be