Skip to content

BandoSamurai/emacs_python_R

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

emacs_python_R

Configure GNU Emacs as Python3 and R editor.

GNU Emacs is a free, open source programming editor: https://www.gnu.org/software/emacs/

This is a configuration for using Emacs as Python3 and R editor. It includes:

UI

  • Styling
  • Directory navigation tree
  • Tabs for open files
  • Standard copy+paste keybindings (aka Cua-Mode)

Python 3

  • Syntax checking
  • Code style (pep8)
  • Autocompletion

R

  • R support (experimental)

Screenshot Python Editing a Python file, showing autocompletion.

Screenshot R Editing an R file, showing a plot.

Prerequisites

  • Python3, pip3
  • virtualenv (required by the autocompletion server)
  • GNU Emacs 2.4 or newer
  • R and ESS.

To install e.g. on Debian do:

apt-get install emacs python3 virtualenv ess r-recommended`

Installation

  1. Get the Emacs cheat sheet. Remember, C-x generally stands for Ctrl-x and M-x for Alt-x.
  2. Install required Python3 packages: pip3 install -r requirements.txt
  3. Add the following lines to your initialization file in ~ /.emacs.d/init.el (or create it if it doesn't exist):
(setenv "WORKSPACE" "<path_to_your_workspace_dir>")
(add-to-list 'load-path "<path_to_where_you_cloned_emacs_python>")
(load "init.el")

The directory $WORKSPACE will be shown in the tree when you start Emacs.

  1. Start Emacs. After the first (re)start, Emacs will download and install the necessary packages.
  2. Restart Emacs. In Emacs, do M-x jedi:install-server
  3. Restart Emacs

References

Golubev, M. (2011) Emacs tabbar-mode visual tweaks. Online: https://gist.github.com/3demax/1264635

Hocking, T. (2012) Using R with Emacs and ESS. Online: http://members.cbio.mines-paristech.fr/~thocking/primer.html

Moore, A.D: (2013) Python Code completion in Emacs — at last! Online: http://www.alandmoore.com/blog/2013/07/31/python-code-completion-in-emacs-at-last/

Patel, A. (2015) Tab Bar Mode, Emacs Wiki. Online: https://www.emacswiki.org/emacs/TabBarMode

Purdon​, K. (2015) Emacs - the Best Python Editor? Online: https://realpython.com/blog/python/emacs-the-best-python-editor/

About

Configure GNU Emacs as Python3 and R editor.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Emacs Lisp 100.0%