parse_install_paths_from_pkgbuild

Function parse_install_paths_from_pkgbuild 

Source
pub fn parse_install_paths_from_pkgbuild(
    pkgbuild: &str,
    pkgname: &str,
) -> Vec<String>
Expand description

What: Parse install paths from PKGBUILD content.

Inputs:

  • pkgbuild: Raw PKGBUILD file content.
  • pkgname: Package name (used for default install paths).

Output:

  • Returns a vector of file paths that would be installed.

Details:

  • Parses package() functions and install scripts to extract file paths.
  • Handles common patterns like install -Dm755, cp, mkdir -p, etc.
  • Extracts paths from package() functions that use install commands.
  • This is a best-effort heuristic and may not capture all files.