summaryrefslogtreecommitdiffstats
path: root/sinksh/syntax_modules/sink_modify.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'sinksh/syntax_modules/sink_modify.cpp')
-rw-r--r--sinksh/syntax_modules/sink_modify.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/sinksh/syntax_modules/sink_modify.cpp b/sinksh/syntax_modules/sink_modify.cpp
index 6cda5ab..173d65e 100644
--- a/sinksh/syntax_modules/sink_modify.cpp
+++ b/sinksh/syntax_modules/sink_modify.cpp
@@ -101,17 +101,15 @@ bool resource(const QStringList &args, State &state)
101Syntax::List syntax() 101Syntax::List syntax()
102{ 102{
103 Syntax modify("modify", QObject::tr("Modify items in a resource"), &SinkModify::modify); 103 Syntax modify("modify", QObject::tr("Modify items in a resource"), &SinkModify::modify);
104 modify.addPositionalArgument({ .name = "type", .help = "The type of entity to modify (mail, event, etc.)" }); 104 modify.addPositionalArgument({"type", "The type of entity to modify (mail, event, etc.)"});
105 modify.addPositionalArgument({ .name = "resourceId", .help = "The ID of the resource containing the entity" }); 105 modify.addPositionalArgument({"resourceId", "The ID of the resource containing the entity"});
106 modify.addPositionalArgument({ .name = "objectId", .help = "The ID of the entity" }); 106 modify.addPositionalArgument({"objectId", "The ID of the entity"});
107 modify.addPositionalArgument( 107 modify.addPositionalArgument({"key value", "Attributes and values to modify", false, true });
108 { .name = "key value", .help = "Attributes and values to modify", .required = false, .variadic = true });
109 108
110 Syntax resource("resource", QObject::tr("Modify a resource"), &SinkModify::resource);//, Syntax::EventDriven); 109 Syntax resource("resource", QObject::tr("Modify a resource"), &SinkModify::resource);//, Syntax::EventDriven);
111 110
112 resource.addPositionalArgument({ .name = "id", .help = "The ID of the resource" }); 111 resource.addPositionalArgument({"id", "The ID of the resource" });
113 resource.addPositionalArgument( 112 resource.addPositionalArgument({"key value", "Attributes and values to modify", false, true});
114 { .name = "key value", .help = "Attributes and values to modify", .required = false, .variadic = true });
115 113
116 resource.completer = &SinkshUtils::resourceOrTypeCompleter; 114 resource.completer = &SinkshUtils::resourceOrTypeCompleter;
117 modify.children << resource; 115 modify.children << resource;