diff --git a/cli/commands/export.mdx b/cli/commands/export.mdx index 4b3579f..4651e74 100644 --- a/cli/commands/export.mdx +++ b/cli/commands/export.mdx @@ -16,6 +16,7 @@ flipt export [flags] -h, --help help for export --namespaces string comma-delimited list of namespaces to export from. (mutually exclusive with --all-namespaces) (default "default") -o, --output string export to filename (default STDOUT) + --sort-by-key sort exported resources by key. (flags, flag variants and segments. namespaces will be sorted with --all-namespaces) -t, --token string client token used to authenticate access to remote Flipt instance when exporting. ``` diff --git a/operations/import-export.mdx b/operations/import-export.mdx index 655f7e9..576b5dc 100644 --- a/operations/import-export.mdx +++ b/operations/import-export.mdx @@ -85,4 +85,11 @@ flipt export --namespaces production namespaces. +By default, Flipt exports resources in the _natural_ order of the selected storage type. While the output is typically consistent within the same storage type, +import/export operations can yield varying results across different storage types. To enhance consistency during export, the --sort-by-key flag can be used. + +```yaml +flipt export --sort-by-key --all-namespaces +``` + See the [CLI reference](/cli/commands/export) for more information on the `export` command.