summaryrefslogtreecommitdiff
path: root/cmds-property.c
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.com>2016-01-11 14:31:20 +0100
committerDavid Sterba <dsterba@suse.com>2016-01-12 15:02:53 +0100
commit7ccc0543dc25cd5751f500dd58df766d61b43095 (patch)
tree1213aedc421e40a81df74d96cf6c4f1eff112435 /cmds-property.c
parentf7c9278008dcdc9fb7c754de89639758ebf6809e (diff)
btrfs-progs: cleanup, move usage help strings closer to the command callbacks
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'cmds-property.c')
-rw-r--r--cmds-property.c58
1 files changed, 29 insertions, 29 deletions
diff --git a/cmds-property.c b/cmds-property.c
index 9ca2abbd..b7b24841 100644
--- a/cmds-property.c
+++ b/cmds-property.c
@@ -32,35 +32,6 @@ static const char * const property_cmd_group_usage[] = {
NULL
};
-static const char * const cmd_property_get_usage[] = {
- "btrfs property get [-t <type>] <object> [<name>]",
- "Gets a property from a btrfs object.",
- "If no name is specified, all properties for the given object are",
- "printed.",
- "A filesystem object can be a the filesystem itself, a subvolume,",
- "an inode or a device. The '-t <type>' option can be used to explicitly",
- "specify what type of object you meant. This is only needed when a",
- "property could be set for more then one object type. Possible types",
- "are s[ubvol], f[ilesystem], i[node] and d[evice].",
- NULL
-};
-
-static const char * const cmd_property_set_usage[] = {
- "btrfs property set [-t <type>] <object> <name> <value>",
- "Sets a property on a btrfs object.",
- "Please see the help of 'btrfs property get' for a description of",
- "objects and object types.",
- NULL
-};
-
-static const char * const cmd_property_list_usage[] = {
- "btrfs property list [-t <type>] <object>",
- "Lists available properties with their descriptions for the given object.",
- "Please see the help of 'btrfs property get' for a description of",
- "objects and object types.",
- NULL
-};
-
static int parse_prop(const char *arg, const struct prop_handler *props,
const struct prop_handler **prop_ret)
{
@@ -388,6 +359,19 @@ static void parse_args(int argc, char **argv,
}
}
+static const char * const cmd_property_get_usage[] = {
+ "btrfs property get [-t <type>] <object> [<name>]",
+ "Gets a property from a btrfs object.",
+ "If no name is specified, all properties for the given object are",
+ "printed.",
+ "A filesystem object can be a the filesystem itself, a subvolume,",
+ "an inode or a device. The '-t <type>' option can be used to explicitly",
+ "specify what type of object you meant. This is only needed when a",
+ "property could be set for more then one object type. Possible types",
+ "are s[ubvol], f[ilesystem], i[node] and d[evice].",
+ NULL
+};
+
static int cmd_property_get(int argc, char **argv)
{
int ret;
@@ -413,6 +397,14 @@ static int cmd_property_get(int argc, char **argv)
return ret;
}
+static const char * const cmd_property_set_usage[] = {
+ "btrfs property set [-t <type>] <object> <name> <value>",
+ "Sets a property on a btrfs object.",
+ "Please see the help of 'btrfs property get' for a description of",
+ "objects and object types.",
+ NULL
+};
+
static int cmd_property_set(int argc, char **argv)
{
int ret;
@@ -436,6 +428,14 @@ static int cmd_property_set(int argc, char **argv)
return ret;
}
+static const char * const cmd_property_list_usage[] = {
+ "btrfs property list [-t <type>] <object>",
+ "Lists available properties with their descriptions for the given object.",
+ "Please see the help of 'btrfs property get' for a description of",
+ "objects and object types.",
+ NULL
+};
+
static int cmd_property_list(int argc, char **argv)
{
int ret;