Skip to content

Commit

Permalink
Merge branch 'bluerobotics:master' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
joaoantoniocardoso committed Apr 1, 2023
2 parents fca5a45 + 61a2ba0 commit 443c082
Show file tree
Hide file tree
Showing 25 changed files with 1,497 additions and 728 deletions.
129 changes: 119 additions & 10 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ actix-files = "0.6.2"
actix-web = "4.1.0"
actix-web-validator = "5.0.1"
actix-service = "2.0.2"
actix-extensible-rate-limit = "0.2.1"
serde = { version = "1.0.140", features = ["derive"] }
serde_json = "1.0.82"
validator = { version = "0.16", features = ["derive"] }
Expand All @@ -43,7 +44,6 @@ include_dir = "0.7.3"
paperclip = { version = "0.8", features = ["paperclip-actix", "actix4", "swagger-ui", "url", "uuid"] }
#TODO: Replace it with yaserde
quick-xml = { version = "0.23.0", features = ["serialize"] }
simple-error = "0.2.3"
url = { version = "2.2.2", features = ["serde"] }
v4l = "0.12.1"
directories = "4.0.1"
Expand All @@ -61,6 +61,7 @@ tokio = { version = "1.21", features = ["full"] }
enum_dispatch = "0.3.8"
uuid = { version = "0.8", features = ["v4", "serde"] }
ts-rs = "6.2"
cached = { version = "0.42", features = ["serde", "serde_json", "async_tokio_rt_multi_thread"] }

## Mavlink
mavlink = { version = "0.10.1", features = ["default", "emit-extensions"] }
Expand Down
12 changes: 11 additions & 1 deletion src/cli/manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@ pub fn is_reset() -> bool {
return MANAGER.as_ref().clap_matches.is_present("reset");
}

pub fn is_tracy() -> bool {
return MANAGER.as_ref().clap_matches.is_present("enable-tracy");
}

#[allow(dead_code)]
// Return the mavlink connection string
pub fn mavlink_connection_string() -> Option<&'static str> {
Expand Down Expand Up @@ -204,6 +208,12 @@ fn get_clap_matches<'a>() -> clap::ArgMatches<'a> {
.long("vehicle-ddns")
.help("Specifies the Dynamic DNS to use as vehicle IP when advertising streams via mavlink.")
.takes_value(true),
)
.arg(
clap::Arg::with_name("enable-tracy")
.long("enable-tracy")
.help("Turns on the Tracy tool integration. Learn more: https://github.com/wolfpld/tracy")
.takes_value(false),
);

matches.get_matches()
Expand All @@ -226,6 +236,6 @@ mod tests {

#[test]
fn default_arguments() {
assert_eq!(is_verbose(), false);
assert!(!is_verbose());
}
}
Loading

0 comments on commit 443c082

Please sign in to comment.