diff --git a/crates/cli/src/args.rs b/crates/cli/src/args.rs index 20248a53..04b39331 100644 --- a/crates/cli/src/args.rs +++ b/crates/cli/src/args.rs @@ -2,12 +2,14 @@ // The verbosity stuff is cribbed from https://github.com/clap-rs/clap-verbosity-flag/blob/c621a6a8a7c0b6df8f1464a985a5d076b4915693/src/lib.rs and updated for tracing +#[cfg(feature = "pgstac")] +use crate::subcommand::pgstac; use crate::{ input::Input, options::KeyValue, output::Output, run::Run, - subcommand::{item, items, migrate, pgstac, search, serve, translate, validate}, + subcommand::{item, items, migrate, search, serve, translate, validate}, Result, Value, }; use clap::Parser; @@ -184,6 +186,7 @@ impl Run for Subcommand { Subcommand::Item(args) => args.run(input, stream).await, Subcommand::Items(args) => args.run(input, stream).await, Subcommand::Migrate(args) => args.run(input, stream).await, + #[cfg(feature = "pgstac")] Subcommand::Pgstac(args) => args.run(input, stream).await, Subcommand::Search(args) => args.run(input, stream).await, Subcommand::Serve(args) => args.run(input, stream).await, @@ -198,6 +201,7 @@ impl Run for Subcommand { Subcommand::Items(args) => args.take_infile(), Subcommand::Migrate(args) => args.take_infile(), Subcommand::Search(args) => args.take_infile(), + #[cfg(feature = "pgstac")] Subcommand::Pgstac(args) => args.take_infile(), Subcommand::Serve(args) => args.take_infile(), Subcommand::Translate(args) => args.take_infile(), @@ -212,6 +216,7 @@ impl Run for Subcommand { Subcommand::Migrate(args) => args.take_outfile(), Subcommand::Search(args) => args.take_outfile(), Subcommand::Serve(args) => args.take_outfile(), + #[cfg(feature = "pgstac")] Subcommand::Pgstac(args) => args.take_outfile(), Subcommand::Translate(args) => args.take_outfile(), Subcommand::Validate(args) => args.take_outfile(),