diff --git a/pkg/cmdrunner/shparse.go b/pkg/cmdrunner/shparse.go index 96e84852..6d463be1 100644 --- a/pkg/cmdrunner/shparse.go +++ b/pkg/cmdrunner/shparse.go @@ -83,7 +83,7 @@ func getSourceStr(source string, w *syntax.Word) string { return source[offset:end] } -var ValidMetaCmdRe = regexp.MustCompile("^/([a-z][a-z0-9_-]*)(:[a-z][a-z0-9_-]*)?$") +var ValidMetaCmdRe = regexp.MustCompile("^/([a-z][a-z0-9_-]*)(?::([a-z][a-z0-9_-]*))?$") type BareMetaCmdDecl struct { CmdStr string @@ -206,5 +206,8 @@ func EvalMetaCommand(ctx context.Context, origPk *scpacket.FeCommandPacketType) } rtnPk.Args = append(rtnPk.Args, literalVal) } + if resolveBool(rtnPk.Kwargs["dump"], false) { + DumpPacket(rtnPk) + } return rtnPk, nil }