help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Writing a script to add comments to a python file


From: John Bokma
Subject: Re: Writing a script to add comments to a python file
Date: Sun, 15 Jul 2012 20:26:21 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux)

Joshua Moore <joshua.marshall.moore@gmail.com> writes:

> Hi gnu.emacs.help
>
> I've been using the basic features of emacs for a while now, and would
> like to add my own functions to it.
>
> What would be a good way to implement a command that adds a comment
> symbol (#) to a selected region in a python file?

It's already there. Maybe it's a better idea to find out what's all
available? A few times I wanted to add something to Emacs only to find
out (often via Google) it's already there.

Anyway:

M x comment-dwim

bound here (default) to:

M ;

> I can read and write a little bit of lisp-like languages, but I don't
> know how to access the region of selected text, edit the lines or
> where to save the script.
>
> Any help is appreciated.

Buy "An introduction into programming Lisp" or read it online:
http://www.gnu.org/software/emacs/emacs-lisp-intro/

-- 
John Bokma                                                               j3b

Blog: http://johnbokma.com/        Perl Consultancy: http://castleamber.com/
Perl for books:    http://johnbokma.com/perl/help-in-exchange-for-books.html


reply via email to

[Prev in Thread] Current Thread [Next in Thread]