a bit refactoring

This commit is contained in:
melsonic 2025-03-11 23:56:27 +05:30
parent 544bf57265
commit 6253d5994e
No known key found for this signature in database
GPG key ID: DFA426742F621CD7
2 changed files with 1 additions and 2 deletions

View file

@ -14,7 +14,7 @@ func validateCmd(ctx context.Context, ms *xmain.State) (err error) {
ms.Opts = xmain.NewOpts(ms.Env, ms.Opts.Flags.Args()[1:])
if len(ms.Opts.Args) == 0 {
return xmain.UsageErrorf("validate must be passed an input file")
return xmain.UsageErrorf("input argument required")
}
inputPath := ms.Opts.Args[0]

View file

@ -438,7 +438,6 @@ func (w *watcher) compileLoop(ctx context.Context) error {
if len(svg) > 0 {
err = fmt.Errorf("failed to fully %scompile (rendering partial svg): %w", recompiledPrefix, err)
} else {
fmt.Println(recompiledPrefix)
err = fmt.Errorf("failed to %scompile: %w", recompiledPrefix, err)
}
errs = err.Error()