Configuring compile-command, useful in Emacs for building R packages with C++ code

preview_player
Показать описание
Part of the series R and Emacs Speaks Statistics,

Summary: set buffer-local variables in a comment in the first line of
your source code, e.g. -*- compile-command: "R CMD INSTALL .." -*-,
M-x compile to execute compile-command in *compilation* buffer, type
TAB in *compilation* buffer to move to next error/warning (shift-TAB
to move to previous), type return
or click on error/warning to jump to the corresponding line of source
for several/all files in a directory, (setq compilation-scroll-output
t) to scroll the *compilation* buffer to the bottom (rather than the
default which keeps it at the top), (setq compilation-read-command
nil) to run the compile-command without asking for confirmation, C-x
C-e to execute emacs lisp code, C-h f to get help on an emacs lisp
function, M-x UpArrow to recall previous emacs command,
(global-set-key [f9] 'compile) to use one-touch compilation via F9
key, avoid emacs asking to confirm risky local variables via
(add-to-list 'safe-local-variable-values '(compile-command . "R CMD
INSTALL ..")).
Рекомендации по теме
welcome to shbcf.ru