before index-conflict changes

This commit is contained in:
pivodevat
2025-11-18 19:46:36 +03:00
parent 28ba2135ec
commit 30540602bd
66 changed files with 1403 additions and 879 deletions

View File

@ -1,10 +1,9 @@
use std::path::PathBuf;
use crate::utils::hardcopy::hardcopy_handler;
use crate::utils::fs::hardcopy::hardcopy_handler;
use crate::utils::shell::*;
pub fn link(repo: &String, pkgname: &String) -> Result<(), String> {
let source = PathBuf::from("/pkg").join(repo).join(pkgname);
if source.join("disabled").exists() { return Ok(()) }
let source = crate::commands::get_aeropkg_base().join(repo).join(pkgname);
if source.join("disabled").exists() { println!("Can't link disabled package: {}", &pkgname); return Ok(()) }
let destination = source.parent()
.ok_or("Failed to get parent directory for path")?
@ -12,6 +11,7 @@ pub fn link(repo: &String, pkgname: &String) -> Result<(), String> {
let dirs_to_copy = vec![
("bin"),
("sbin"),
("lib"),
("libexec"),
("include"),