Skip to content
This repository has been archived by the owner on Jun 9, 2023. It is now read-only.

Commit

Permalink
Corrected cache folder registry (1)
Browse files Browse the repository at this point in the history
  • Loading branch information
fedorenko22116 committed Jul 16, 2020
1 parent 338dee2 commit f4841bc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion debian_bridge_cli/src/starter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ where

debug!("Configuration path: {}", config_path.to_str().unwrap());

let cache_path = xdg::BaseDirectories::with_prefix(&package_name)?.place_cache_file("Dockerfile")?;
let cache_path = xdg::BaseDirectories::with_prefix(&package_name)?.place_cache_file("")?;

debug!("Cache path: {}", cache_path.to_str().unwrap());

Expand Down
3 changes: 2 additions & 1 deletion debian_bridge_core/src/app/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,9 @@ impl<'a> App<'a> {
let deb = Deb::try_new(app_path)?;
let program = Program::new(&deb.package, &app_path, &settings, &icon, &cmd, &deps);
let mut app_tmp_path = self.cache_path.to_owned();
app_tmp_path.push(Path::new("tmp.deb"));

std::fs::create_dir_all(&app_tmp_path).map_err(|err| AppError::File(err.to_string()))?;
app_tmp_path.push(Path::new("tmp.deb"));
std::fs::copy(app_path, &app_tmp_path).map_err(|err| AppError::File(err.to_string()))?;

let mut dockerfile = util::gen_dockerfile(&deb, &program)?;
Expand Down

0 comments on commit f4841bc

Please sign in to comment.