I want to open emacs + an emacs file directly in the terminal, the file in question, how should I go about it?
1 Answer
Since you are using putty
I assume you want a non-X version of Emacs:
emacs -nw test.txt
will open test.txt
in a non-window version of Emacs.
If you need to open test.txt on a particular line and column use:
emacs -nw +5:8 test.txt
This will set your cursor to column 8 on line 5 (or at the end of that line if it is not long enough).
-
2I would perhaps add that in some distros, there's a package called emacs-nox. If you install it, then you can just type
emacs-nox file
or are even able switch permanently to non-X version viaalternatives --config emacs
. Or perhapsupdate-alternatives
, that really depends. Nov 4, 2014 at 2:16 -
@MiroslavFranc You are right, and that is the case on my system (Ubuntu 12.04). At this point I was (am) however not even sure this answers the OPs questio.– AnthonNov 4, 2014 at 4:28
emacs
followed by the file name?