pub struct ModulesCommand { /* private fields */ }Expand description
Command for listing declared modules in a configuration.
Lists all modules declared in the current working directory.
Supports -json for machine-readable output.
Requires Terraform v1.10.0 or later.
use terraform_wrapper::{Terraform, TerraformCommand};
use terraform_wrapper::commands::modules::ModulesCommand;
let tf = Terraform::builder().working_dir("/tmp/infra").build()?;
let output = ModulesCommand::new()
.json()
.execute(&tf)
.await?;Implementations§
Trait Implementations§
Source§impl Clone for ModulesCommand
impl Clone for ModulesCommand
Source§fn clone(&self) -> ModulesCommand
fn clone(&self) -> ModulesCommand
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ModulesCommand
impl Debug for ModulesCommand
Source§impl Default for ModulesCommand
impl Default for ModulesCommand
Source§fn default() -> ModulesCommand
fn default() -> ModulesCommand
Returns the “default value” for a type. Read more
Source§impl TerraformCommand for ModulesCommand
impl TerraformCommand for ModulesCommand
Source§type Output = CommandOutput
type Output = CommandOutput
The output type produced by this command.
Source§async fn execute(&self, tf: &Terraform) -> Result<CommandOutput>
async fn execute(&self, tf: &Terraform) -> Result<CommandOutput>
Execute this command against the given Terraform client.
Source§fn supports_input(&self) -> bool
fn supports_input(&self) -> bool
Whether this command supports the
-input=false flag. Read moreAuto Trait Implementations§
impl Freeze for ModulesCommand
impl RefUnwindSafe for ModulesCommand
impl Send for ModulesCommand
impl Sync for ModulesCommand
impl Unpin for ModulesCommand
impl UnsafeUnpin for ModulesCommand
impl UnwindSafe for ModulesCommand
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more