[FSUTIL]
[reactos.git] / reactos / base / applications / cmdutils / fsutil / fsutil.c
1 /*
2 * COPYRIGHT: See COPYING in the top level directory
3 * PROJECT: ReactOS FS utility tool
4 * FILE: base/applications/cmdutils/fsutil.c
5 * PURPOSE: FSutil main
6 * PROGRAMMERS: Pierre Schweitzer <pierre@reactos.org>
7 */
8
9 #include "fsutil.h"
10
11 /* Add handlers here for commands */
12 int DirtyMain(int argc, const TCHAR *argv[]);
13 int FsInfoMain(int argc, const TCHAR *argv[]);
14 static HandlerItem HandlersList[] =
15 {
16 /* Proc, name, help */
17 { DirtyMain, _T("dirty"), _T("Manipulates the dirty bit") },
18 { FsInfoMain, _T("fsinfo"), _T("Gathers informations about file systems") },
19 };
20
21 static void
22 PrintUsage(const TCHAR * Command)
23 {
24 PrintDefaultUsage(_T(" "), Command, (HandlerItem *)&HandlersList,
25 (sizeof(HandlersList) / sizeof(HandlersList[0])));
26 }
27
28 int
29 __cdecl
30 _tmain(int argc, const TCHAR *argv[])
31 {
32 return FindHandler(argc, argv, (HandlerItem *)&HandlersList,
33 (sizeof(HandlersList) / sizeof(HandlersList[0])),
34 PrintUsage);
35 }