mirror of
https://github.com/onyx-and-iris/gobs-cli.git
synced 2025-07-21 20:31:47 +00:00
Compare commits
1 Commits
Author | SHA1 | Date | |
---|---|---|---|
c6406888a9 |
@ -5,7 +5,7 @@ All notable changes to this project will be documented in this file.
|
|||||||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||||
|
|
||||||
# [0.14.0] - 2025-07-14
|
# [0.14.1] - 2025-07-14
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
|
9
text.go
9
text.go
@ -33,11 +33,18 @@ func (cmd *TextCurrentCmd) Run(ctx *context) error {
|
|||||||
return fmt.Errorf("input %s is of %s", cmd.InputName, kind)
|
return fmt.Errorf("input %s is of %s", cmd.InputName, kind)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
currentText, ok := resp.InputSettings["text"]
|
||||||
|
if !ok {
|
||||||
|
return fmt.Errorf("input %s does not have a 'text' setting", cmd.InputName)
|
||||||
|
}
|
||||||
|
if currentText == "" {
|
||||||
|
currentText = "(empty)"
|
||||||
|
}
|
||||||
fmt.Fprintf(
|
fmt.Fprintf(
|
||||||
ctx.Out,
|
ctx.Out,
|
||||||
"Current text for source %s: %s\n",
|
"Current text for source %s: %s\n",
|
||||||
ctx.Style.Highlight(cmd.InputName),
|
ctx.Style.Highlight(cmd.InputName),
|
||||||
resp.InputSettings["text"],
|
currentText,
|
||||||
)
|
)
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user