mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-26 02:11:53 +00:00
* include system images in compat s9pk * wip * wip * update types * wip * fix signature serialization * Add SignatureHeader conversions * finish display impl for get --------- Co-authored-by: Shadowy Super Coder <musashidisciple@proton.me>
18 lines
369 B
Rust
18 lines
369 B
Rust
use std::path::{Path, PathBuf};
|
|
|
|
use models::{PackageId, VersionString};
|
|
|
|
pub const PKG_SCRIPT_DIR: &str = "package-data/scripts";
|
|
|
|
pub fn script_dir<P: AsRef<Path>>(
|
|
datadir: P,
|
|
pkg_id: &PackageId,
|
|
version: &VersionString,
|
|
) -> PathBuf {
|
|
datadir
|
|
.as_ref()
|
|
.join(&*PKG_SCRIPT_DIR)
|
|
.join(pkg_id)
|
|
.join(version.as_str())
|
|
}
|