File
⇒ New Frame
), multiple buffers
Install the emacs
package, if it is not already available
$ sudo apt install emacs [sudo] password for your_login: Reading package lists... Done Building dependency tree Reading state information... Done emacs is already the newest version (1:26.3+1-1ubuntu2). 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.
Install Aquamacs
This is the light and easy option
winget install --id GNU.Emacs
plink
command to connect to remote servers (instead of Windows builtin ssh
)host
) as you have configured in the Host Name field in Putty/plink:your_login@ssh1.lsce.ipsl.fr:/path/to/file
This is the heavyweight option
emacs some_text_file &
emacs &
Start
⇒ E
⇒ Emacs
C-g
(CTRL
+g
) to abort or interrupt something in emacs
e.g. When you are searching forward with C-s
, type C-g
to exit the search
All the common functions of emacs are available from the pull-down menus at the top, but the real power comes from knowing (a few of) the keyboard shortcuts!
C-x C-c
means CTRL-x
followed by CTRL-c
, and will exit emacsFile
⇒Quit
, just faster C-s
means CTRL-s
, and will Search forwardIncremental Search
in the Reference Card for more information on searching!C-g
means CTRL-G
and will abort the current emacs command/action (e.g. exit a forward search started with C-s
)C-z
will iconify the emacs window!C-x u
(CTRL-x
followed by u
) or Edit
⇒Undo
for undoing the previous action!M-f
means Alt-f
(or Esc
followed by f
if the keyboard has no Alt
key), and will Move forward a wordC-A
and C-E
to go to the beginning and end of a lineHelp
⇒Emacs Tutorial
Help
⇒Emacs Tutorial (choose language)…
(
and )
) when copy/pasting settings you find on the webOptions
menu appear at the end of the configuration file
emacs knows where its configuration file is located, and you can just open it by typing C-x C-f ~/.emacs
and then check how the Home folder (~/
) has been expanded
Related emacs (configuration) files and folders (e.g. .emacs.d/
folder) are located in the same place as the main configuration file
~/.emacs
: i.e. .emacs
(dot-emacs) file in the current user's Home directoryc:\Users\your_login\AppData\Roaming\.emacs
c:/Users/your_login/AppData/Roaming/.emacs
Keyboard shortcuts defined by the example configuration file
C-x C-g
: goto lineShift Left_Arrow
and Shift Right_Arrow
: go to the beginning/end of a lineC-a
and C-e
, and the Home
and End
keyboard keysShift Up_Arrow
and Shift Down_Arrow
: go to the beginning/end of the bufferF1
: Undo (lots of undos!!)F2
: Search and ReplaceQuery Replace
in the Reference Card to determine what you can do when a match is foundF3
: fill-paragraph (i.e. automatically re-indent text or comments)F12
: Repeat complex command (e.g. restart a previous query-replace operation)Useful shortcuts
M-;
: comment out selected linescomment character
for the current buffer mode, e.g. #
for a Python scriptC-x C-f
), emacs will automatically use the tramp
mode to:scp
) to your computer when you open it, so that you can edit the file locallyscp
) file back to its original remote location when you save it (C-x C-s
)/ssh:user@server:/path/file
/plinkx:jdoe_server:/path/file
on Windows with an existing jdoe_server
session defined in PuTTY
/ssh:your_login@ssh1.lsce.ipsl.fr:/home/users/your_login/my_script.py
/ssh:user_A@gateway|ssh:user_B@target_server:/path/file
/ssh:your_login@ssh1.lsce.ipsl.fr|ssh:user_B@target_server:/path/file
'(recentf-mode t)
mode, you can easily access recent files in File
⇒Open Recent
without having to type the full access path again!
The tramp
mode is quite complex and relies on connections to one or more remote computers using external programs and protocols. You may have to experiment a bit till you find the correct syntax and inline method to work with a particular remote server. Make sure you have read the prerequisite section!
Buffer
⇒ *Messages*
C-g
M-x doctor
). See also Fun and Games in EmacsI am the psychotherapist. Please, describe your problems. Each time you are finished talking, type RET twice. My climate model does not work Why do you say your climate model does not work? I get wrong results Is it because of your plans that you say you get wrong results?
[ PMIP3 Wiki Home ] - [ Help! ] - [ Wiki syntax ]