python korea(emacs)

Post on 23-Jun-2015

1.625 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

DESCRIPTION

Emacs for python programmers in Python Korea Community seminar. Mostly derived from Vinod Kurup's material

TRANSCRIPT

Emacs for Python Programming

Johnny Cho( 조민재 )

@popeye92

June 29th, 2014

First ...

Special thanks to Vinod Kurup

But first ...

How to safely play with Emacs

• Control-x Control-c to quit (C-x C-c)

• C-g is your friend

• Plan to mess up

vinod:~$ rm -r .emacs.d .emacs

vinod:~$ emacs

You're good to go again!

Emacs Sucks!

but only if you use the default settings

Emacs Tutorial

C-h t RET

M-x help-with-toturial-spec-language RET Korean RET

Emacs Starter Kit

M -x package-install RET starter-kit RET

Packages for Emacs python programmers

ido-settings.el;

auto-complete;

jedi.el;

flycheck;

autopair;

optional ipython;

Installation Packages

(require 'package)

(setq package-archives '(("gnu" . "http://elpa.gnu.org/packages/")

("marmalade" . "http://marmalade-repo.org/packages/")

("melpa" . "http://melpa.milkbox.net/packages/")))

Installation Packages

M-x package-list-packages

M-x package-install RET autopair RET

Emacs Python IDE

Features

• Syntax highlighting

• Auto-Indentation

• Code completion

• Documentation lookup

• Code lookup / navigation

• Error highlighting (on-the-fly)

• Code runner

• Test runner

• Debugging

Major mode

Python's is a bit of a mess

Use python-mode.el

M-x package-install RET python-mode RET ( < Emacs24.2 )

Emacs24 .2 이후기본패키지

Syntax highlighting

Automatic indentation

Code completion

Documentation lookup

Code lookup

Error highlighting

Code runner

• Send the current buffer to Python

C-c C-c

• Choose your interpreter

(setq python-python-command "ipython")

• Choose your virtualenv

(virtualenv-workon "myproject")

or

M-x virtualenv-workon RET myproject RET

Test runner

Debugging

Useful links

Python Programming in Emacs● www.emacswiki.org/emacs/PythonProgrammingInEmacs● wiki.python.org/moin/EmacsEditor

Non-python stuffs

Magit mode

Dired mode

Keyboard Macros

Pretty Themes

Shell modes

And more!!

• Kill ring

• yasnippet

• Org-mode

• ace-jump

• erc

Help in emacs

• C-h t => tutorial

• C-h f => function docs

• C-h v => variable docs

• C-h k => keybindings

Emacs can teach you emacs

감사합니다 .

popeye92@gmail.com@popeye92

top related