forked from rosa/hakurei
cmd/mbf: optionally ignore reply
An acknowledgement is not always required in this use case. This change also adds 64 bits of connection configuration for future expansion. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -392,10 +392,11 @@ func main() {
|
||||
|
||||
{
|
||||
var (
|
||||
flagDump string
|
||||
flagEnter bool
|
||||
flagExport string
|
||||
flagRemote bool
|
||||
flagDump string
|
||||
flagEnter bool
|
||||
flagExport string
|
||||
flagRemote bool
|
||||
flagNoReply bool
|
||||
)
|
||||
c.NewCommand(
|
||||
"cure",
|
||||
@@ -474,8 +475,12 @@ func main() {
|
||||
})
|
||||
|
||||
case flagRemote:
|
||||
pathname, err := cureRemote(ctx, &addr, rosa.Std.Load(p))
|
||||
if err == nil {
|
||||
var flags uint64
|
||||
if flagNoReply {
|
||||
flags |= remoteNoReply
|
||||
}
|
||||
pathname, err := cureRemote(ctx, &addr, rosa.Std.Load(p), flags)
|
||||
if !flagNoReply && err == nil {
|
||||
log.Println(pathname)
|
||||
}
|
||||
return err
|
||||
@@ -497,6 +502,10 @@ func main() {
|
||||
&flagRemote,
|
||||
"daemon", command.BoolFlag(false),
|
||||
"Cure artifact on the daemon",
|
||||
).Flag(
|
||||
&flagNoReply,
|
||||
"no-reply", command.BoolFlag(false),
|
||||
"Do not receive a reply from the daemon",
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user