Skip to content

Commit

Permalink
Merge pull request #15 from workos/at-schema-convert-bugfix
Browse files Browse the repository at this point in the history
[FGA-198] Update raw FGA schema convert output so that it includes version
  • Loading branch information
atainter authored Dec 4, 2024
2 parents 41c702e + 47d80ea commit 85fdcab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/cmd/fga.go
Original file line number Diff line number Diff line change
Expand Up @@ -626,7 +626,7 @@ var convertSchemaCMD = &cobra.Command{
Use: "convert <input_file>",
Short: "Convert a schema to a JSON representation (or JSON to schema)",
Long: "Convert a schema to a JSON representation (or JSON to schema) that can be used to apply resource types.",
Example: `workos fga schema convert schema.txt -o json`,
Example: `workos fga schema convert schema.txt --to json`,
Args: cobra.ExactArgs(1),
RunE: func(cmd *cobra.Command, args []string) error {
to, err := cmd.Flags().GetString("to")
Expand Down Expand Up @@ -693,7 +693,7 @@ var convertSchemaCMD = &cobra.Command{
if response.Schema != nil {
printer.PrintMsg(*response.Schema)
} else {
printer.PrintJson(response.ResourceTypes)
printer.PrintJson(response)
}
default:
return errors.Errorf("invalid output: %s", output)
Expand Down

0 comments on commit 85fdcab

Please sign in to comment.