atharvalade commented on code in PR #2998:
URL: https://github.com/apache/iggy/pull/2998#discussion_r2996292741
##########
core/cli/src/commands/binary_context/common.rs:
##########
@@ -258,6 +321,18 @@ impl ContextReaderWriter {
Ok(())
}
+ pub fn ensure_iggy_home_exists(&self) -> Result<()> {
+ if let Some(ref iggy_home) = self.iggy_home
+ && !iggy_home.exists()
+ {
+ std::fs::create_dir_all(iggy_home).context(format!(
Review Comment:
replaced `std::fs::create_dir_all` and `iggy_home.exists()` with
t`okio::fs::create_dir_all` and `tokio::fs::try_exists` to stay consistent with
the rest of the file.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]