Execute the pull command. This method creates a tokio runtime and executes the async pull operation. It handles all the steps required to download and apply remote changes. # Errors Returns an error if: - No repository is found - The remote cannot be connected to - Network operations fail - Changes fail to download or save
(&self)
| 1009 | /// - Network operations fail |
| 1010 | /// - Changes fail to download or save |
| 1011 | fn run(&self) -> CliResult<()> { |
| 1012 | // Create a runtime for async operations |
| 1013 | let rt = tokio::runtime::Runtime::new().map_err(|e| { |
| 1014 | CliError::Internal(anyhow::anyhow!("Failed to create async runtime: {}", e)) |
| 1015 | })?; |
| 1016 | |
| 1017 | rt.block_on(self.run_async()) |
| 1018 | } |
| 1019 | } |
| 1020 | |
| 1021 | // Tests |