Skip to content

Commit

Permalink
feat: automatically uppercase abbreviations
Browse files Browse the repository at this point in the history
  • Loading branch information
twpayne committed Dec 6, 2024
1 parent e8bee49 commit 7a5a1d9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/gojsonstruct/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@ func run() error {
jsonstruct.WithGoFormat(*goFormat),
}
if *abbreviations != "" {
options = append(options, jsonstruct.WithExtraAbbreviations(strings.Split(*abbreviations, ",")...))
extraAbbreviations := strings.Split(strings.ToUpper(*abbreviations), ",")
options = append(options, jsonstruct.WithExtraAbbreviations(extraAbbreviations...))
}
if *intType != "" {
options = append(options, jsonstruct.WithIntType(*intType))
Expand Down

0 comments on commit 7a5a1d9

Please sign in to comment.