File: PLUGIN_HOWTO.pygments

package info (click to toggle)
global 6.6.14-1.1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 12,612 kB
  • sloc: ansic: 132,180; sh: 5,017; javascript: 4,891; perl: 811; lisp: 676; makefile: 340; yacc: 122
file content (76 lines) | stat: -rw-r--r-- 2,240 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
___________________________________
|      |  |  |     |  _  |     |  |
|  |___|  |  |  |  |    _|  |  |  |    GNU GLOBAL source code tag system
|  |   |  |  |  |  |     |     |  |
|  ~~  |   ~~|     |  ~  |  |  |   ~~|          for all hackers.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 Copyright (c) 2014 Tama Communications Corporation

 This file is free software; as a special exception the author gives
 unlimited permission to copy and/or distribute it, with or without
 modifications, as long as this notice is preserved.

 This program is distributed in the hope that it will be useful, but
 WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
 implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

                ----------------------------------

How to use Pygments Plug-in Parser

Pygments is a generic syntax highlighter for wide variety of
programming languages. This plug-in use Pygments and Universal
Ctags as a parser to treat both definitions and references.
Exuberant Ctags is no longer supported.

You need the following software:
o Python 2.6 or later (3 is also supported)
o Pygments python package 1.6 or later
o Universal Ctags 6.0.0 or later (optional)

[Installation]

1. Check

Make sure python and ctags can be invoked in your command line.
$ type python
python is /usr/bin/python
$ type ctags
ctags is /usr/local/bin/ctags

2. Installation of GLOBAL

$ ./configure
$ make
$ sudo make install

3. Setup of Pygments plug-in parser

The definition of Pygments plug-in parser is prepared
in the default configuration file. Please specify it.

$ export GTAGSCONF=/usr/local/share/gtags/gtags.conf
$ export GTAGSLABEL=pygments

[Execution of gtags]

Please execute gtags(1) as usual.

$ gtags

If it is doubtful whether Pygments plug-in parser is used,
please try --explain option. It shows the libraries used by
gtags.

$ gtags --explain
...
File './lib/xmalloc.c' is handled as follows:
        suffix:   |.c|
        language: |C|
        parser:   |parser|
        library:  |/usr/local/lib/gtags/pygments-parser.la|

                ----------------------------------

Pygments plug-in parser was written by Yoshitaro MAKISE.
Now it is maintained as a part of GNU Global.