Merge pull request #1022 from gtardif/compose_disclaimer_moby_context

Display compose experimental disclaimer only for local context type or moby (default) context type
This commit is contained in:
Guillaume Tardif 2020-12-07 17:31:08 +01:00 committed by GitHub
commit 54b86cd912
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -75,7 +75,9 @@ func Command(contextType string) *cobra.Command {
Short: "Docker Compose", Short: "Docker Compose",
Use: "compose", Use: "compose",
PersistentPreRunE: func(cmd *cobra.Command, args []string) error { PersistentPreRunE: func(cmd *cobra.Command, args []string) error {
fmt.Println("The new 'docker compose' command is currently experimental. To provide feedback or request new features please open issues at https://github.com/docker/compose-cli") if contextType == store.DefaultContextType || contextType == store.LocalContextType {
fmt.Println("The new 'docker compose' command is currently experimental. To provide feedback or request new features please open issues at https://github.com/docker/compose-cli")
}
return nil return nil
}, },
} }