2 * Copyright (C) 2005-2009 Junjiro Okajima
4 * This program, aufs is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
26 static void usage(char *me
)
29 "usage: %s aufs_mount_point list|cpup|flush\n"
30 "'list' shows the pseudo-linked inode numbers and filenames.\n"
31 "'cpup' copies-up all pseudo-link to the writeble branch.\n"
32 "'flush' calls 'cpup', and then 'mount -o remount,clean_plink=inum'\n"
33 "and remove the whiteouted plink.\n", me
);
37 int main(int argc
, char *argv
[])
45 if (!strcmp(argv
[2], "flush"))
47 else if (!strcmp(argv
[2], "list"))
49 else if (!strcmp(argv
[2], "cpup"))
54 cmd
= 0; /* never reach here */
60 cwd
= getcwd(NULL
, 0); /* glibc */
63 return au_plink(cwd
, cmd
, 1, 0);