Subversion Repositories HelenOS

Rev

Rev 3265 | Rev 3302 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3265 Rev 3277
1
#ifndef MODULES_H
1
#ifndef MODULES_H
2
#define MODULES_H
2
#define MODULES_H
3
 
3
 
4
/* Each built in function has two files, one being an entry.h file which
4
/* Each built in function has two files, one being an entry.h file which
5
 * prototypes the run/help entry functions, the other being a .def file
5
 * prototypes the run/help entry functions, the other being a .def file
6
 * which fills the modules[] array according to the cmd_t structure
6
 * which fills the modules[] array according to the cmd_t structure
7
 * defined in cmds.h.
7
 * defined in cmds.h.
8
 *
8
 *
9
 * To add or remove a module, just make a new directory in cmds/modules
9
 * To add or remove a module, just make a new directory in cmds/modules
10
 * for it and copy the 'show' example for basics, then include it here.
10
 * for it and copy the 'show' example for basics, then include it here.
11
 * (or reverse the process to remove one)
11
 * (or reverse the process to remove one)
12
 *
12
 *
13
 * NOTE: See module_ aliases.h as well, this is where aliases (commands that
13
 * NOTE: See module_ aliases.h as well, this is where aliases (commands that
14
 * share an entry point with others) are indexed */
14
 * share an entry point with others) are indexed */
15
 
15
 
16
#include "config.h"
16
#include "config.h"
17
 
17
 
18
/* Prototypes for each module's entry (help/exec) points */
18
/* Prototypes for each module's entry (help/exec) points */
19
 
19
 
20
#include "help/entry.h"
20
#include "help/entry.h"
21
#include "quit/entry.h"
21
#include "quit/entry.h"
-
 
22
#include "mkdir/entry.h"
-
 
23
#include "rm/entry.h"
-
 
24
#include "cat/entry.h"
-
 
25
#include "touch/entry.h"
-
 
26
#include "ls/entry.h"
22
 
27
 
23
/* Each .def function fills the module_t struct with the individual name, entry
28
/* Each .def function fills the module_t struct with the individual name, entry
24
 * point, help entry point, etc. You can use config.h to control what modules
29
 * point, help entry point, etc. You can use config.h to control what modules
25
 * are loaded based on what libraries exist on the system. */
30
 * are loaded based on what libraries exist on the system. */
26
 
31
 
27
module_t modules[] = {
32
module_t modules[] = {
28
#include "help/help.def"
33
#include "help/help.def"
29
#include "quit/quit.def"
34
#include "quit/quit.def"
-
 
35
#include "mkdir/mkdir.def"
-
 
36
#include "rm/rm.def"
-
 
37
#include "cat/cat.def"
-
 
38
#include "touch/touch.def"
-
 
39
#include "ls/ls.def"
30
    {NULL, NULL, NULL, NULL}
40
    {NULL, NULL, NULL, NULL}
31
};
41
};
32
 
42
 
33
#endif
43
#endif
34
 
44