add missing brackets; change to the correct executable name of nqp at parrot
[parrot.git] / editor / README.pod
blob5ff31b499ee46827e5224bf545a45f8e958a70e4
1 # $Id$
3 =head1 NAME
5 editor/README.pod - Productivity Comes in Pretty Colors
7 =head1 Syntax Highlighting and Other Editor Assistance
9 Included in this directory are some add-ins for making working on parrot (or in
10 parrot) easier, for various popular editors. Mostly that means
11 syntax-highlighting and automatic indenting. Read on to see what's available for
12 your favorite editor. For a summary on what is available do
13   cd editor && make help
15 =head2 Vim
17 Calling C<make vim-install> in the F<editor/> directory will
18 install several files in F<~/.vim>. All these files have the F<.vim>
19 extension. F<pir.vim> (generated from F<pir_vim.in>), F<pasm.vim>, and
20 F<pmc.vim> are syntax files; F<indent_pir.vim> is an indent plugin;
21 and F<filetype_parrot.vim> is a filetype script that tells vim to
22 associate the extensions .pir, .pasm, and .pmc with the
23 right syntax. The syntax files are installed to F<~/.vim/syntax/>;
24 F<filetype_parrot.vim> is installed to F<~/.vim/ftdetect>;
25 F<indent_pir.vim> is copied to F<~/.vim/indent/pir.vim>.  If you want
26 indenting, you should also place C<filetype indent on> somewhere in
27 your F<~/.vimrc>.
29 =head2 Kate
31 There is a syntax file for the KDE editor Kate, but it is not built by default.
32 Run:
34    make imc.kate
36 in F<editor/> to build it.
38 TODO: How do we install Kate syntax files?
40 =head2 Emacs
42 =over 4
44 =item * Editing the Parrot VM source
46 In this directory is a F<parrot.el> describing the c-mode and cperl-mode
47 changes modifications required to edit the Parrot source code.  To install
48 the Parrot mode support copy F<parrot.el> to a directory where Emacs looks
49 for external packages and add the following to your F<~/.emacs> file:
51     (load "parrot")
53 Alternatively, if you're an active Parrot developer, you may wish to add
54 this to your .emacs instead, to automatically track future changes:
56     (load-file "/<path-to-parrot>/editor/parrot.el")
58 =item * Editing PASM source files
60 Included here is an Emacs mode for editing pasm files, in F<pasm.el>.
62 To install the pasm major mode copy F<pasm.el> to a directory where Emacs
63 looks for external packages and add the following to your F<~/.emacs> file:
65     (load "pasm")
67 To automatically associate .pasm files with this major mode add:
69     (add-to-list 'auto-mode-alist (cons "\\.pasm\\'" 'pasm-mode))
71 to your F<~/.emacs> or you can alternatively type C<M-x pasm-mode> for every
72 file that you want to use the major mode in.
74 Additionally, you might want to add:
76     (add-hook 'pasm-mode-hook
77               (function (lambda ()
78                           (setq indent-tabs-mode nil))))
80 to F<~/.emacs> as this seems to prevent the odd behavior that is noted when 
81 using tabs in the pasm mode.
83 =back
85 =head2 TAGS file
87 There is a script here to automatically generate a TAGS file, which works with
88 Vim and other editors that recognize ctags-format files. Run
90   make tags-vi
92 for Vim-compatible tags or
94   make tags-emacs
96 for Emacs-style tags.  The tool "exuberant ctags" is required for both. There
97 is also the
99   make tags-xemacs
101 target which will work with older XEmacs etags (21.5*).
103 =cut