]> sipb.mit.edu Git - ikiwiki.git/blob - doc/plugins/contrib/shortcuts.mdwn
eb13bb106df241ccaf8a401046460f038dd41b59
[ikiwiki.git] / doc / plugins / contrib / shortcuts.mdwn
1 [[template id=plugin name=shortcuts included=0 author="[[VictorMoral]]"]]
2 [[tag type/format]]
3
4 *shortcuts* is a plugin for make external links easy in a ikiwiki page.
5 It filter the raw source code, searching *wafl expresions* and replacing it
6 for ikiwiki links and not for html links. 
7
8 *Note: my apologies for my poor english, my mother language is the spanish.
9 Any corrections are welcome :-).*
10
11 In the source page you need include the expresions as:
12
13     For my {wiki:UPS} APC i need the {deb:apcupsd} package installed. You can 
14     found {google:apc linux|many positive responses}.
15
16 and after filter this is the result:
17
18     For my [UPS](http://en.wikipedia.org/wiki/UPS) i need the 
19     [apcupsd](http://packages.debian.org/). You can found 
20     [many positive responses](http://www.google.com/search?q=apc+linux).
21
22 If you need escape a walf expression prefix with a backslash character as in:
23
24     This is a \{cpan:example}.
25
26 This module is inspired in Kwiki::Shortcuts with minor diferences. The wafl
27 expresions are strings between braces with the following elements:
28
29 * one name (followed by one colon character)
30 * one o many search terms
31 * an optional text for the link
32
33 The plugin provides some predefined shortcuts, and it can use a external
34 definitions file. This file is named *shortcuts.conf* by default, but it can
35 be set with the *shortcuts* parameter and configuration variable.
36
37 The next shortcuts are predefined:
38
39 -   google: http://www.google.com/search?q=
40 -   deb:    http://packages.debian.org/
41 -   dbug:   http://bugs.debian.org/
42 -   cpan:   http://search.cpan.org/search?mode=dist&query=
43 -   wiki:   http://en.wikipedia.org/wiki/
44
45 Use the external Perl module: URI::Escape and it can be found
46 [here](http://taquiones.net/files/misc/IkiWiki-Plugin-shortcuts-0.3.tar.gz).
47