diff --git a/providers/pulumi_wasm_provider_docker_rust/src/resource/container.rs b/providers/pulumi_wasm_provider_docker_rust/src/resource/container.rs index 99fce1eff..1e8d0515a 100644 --- a/providers/pulumi_wasm_provider_docker_rust/src/resource/container.rs +++ b/providers/pulumi_wasm_provider_docker_rust/src/resource/container.rs @@ -37,16 +37,24 @@ //! //! you provide the definition for the resource as follows //! -//! ```yaml -//! resources: -//! foo: -//! type: docker:Container -//! properties: -//! name: "foo" -//! image: "nginx" -//! ports: -//! - internal: 80 -//! external: 8080 +//! ```ignore +//! use pulumi_wasm_rust::Output; +//! use pulumi_wasm_rust::{add_export, pulumi_main}; +//! #[pulumi_main] +//! fn test_main() -> Result<(), Error> { +//! let foo = container::create( +//! "foo", +//! ContainerArgs::builder() +//! .image("nginx") +//! .name("foo") +//! .ports( +//! vec![ +//! ContainerPort::builder().external(8080).internal(80).build_struct(), +//! ], +//! ) +//! .build_struct(), +//! ); +//! } //! ``` //! //! then the import command is as follows diff --git a/pulumi_wasm_generator_lib/src/description.rs b/pulumi_wasm_generator_lib/src/description.rs index 3f787d058..910ebd95f 100644 --- a/pulumi_wasm_generator_lib/src/description.rs +++ b/pulumi_wasm_generator_lib/src/description.rs @@ -53,7 +53,7 @@ impl<'a> Description<'a> { match line.trim() { "" | "{{% examples %}}" => (Examples, vec![]), // Rustdoc treats ``` as rust code block - "```" => (Shell, vec!["```sh".to_string()]), + "```" => (LanguageOutsideExamples, vec!["```sh".to_string()]), l if l.starts_with("```") => (LanguageOutsideExamples, vec![line.to_string()]), _ => (Initial, vec![line.to_string()]), } diff --git a/pulumi_wasm_generator_lib/src/dockerfixes/container/1_fixed.md b/pulumi_wasm_generator_lib/src/dockerfixes/container/1_fixed.md index 024ac1328..78eea23e4 100644 --- a/pulumi_wasm_generator_lib/src/dockerfixes/container/1_fixed.md +++ b/pulumi_wasm_generator_lib/src/dockerfixes/container/1_fixed.md @@ -139,6 +139,7 @@ prints the container ID you provide the definition for the resource as follows + ```yaml resources: foo: @@ -150,6 +151,7 @@ resources: - internal: 80 external: 8080 ``` + then the import command is as follows