1#![deny(missing_docs)]
9#![deny(missing_debug_implementations)]
10#![forbid(unused_must_use)]
11#![deny(unsafe_code)]
12#![cfg_attr(feature = "dox", feature(doc_cfg))]
13#![deny(clippy::dbg_macro)]
14#![deny(clippy::todo)]
15
16pub use composefs;
20pub use composefs_boot;
21pub use composefs_oci;
22pub use containers_image_proxy;
23pub use containers_image_proxy::oci_spec;
24pub use ostree;
25pub use ostree::gio;
26pub use ostree::gio::glib;
27
28type Result<T> = anyhow::Result<T>;
31
32pub mod globals;
34
35mod isolation;
36
37pub mod bootabletree;
38pub mod cli;
39pub mod container;
40pub mod container_utils;
41pub mod diff;
42pub(crate) mod generic_decompress;
43pub mod ima;
44pub mod keyfileext;
45pub(crate) mod logging;
46pub mod ostree_prepareroot;
47pub mod refescape;
48#[doc(hidden)]
49pub mod repair;
50pub mod sysroot;
51pub mod tar;
52pub mod tokio_util;
53
54pub mod selinux;
55
56pub mod chunking;
57pub mod commit;
58pub mod objectsource;
59pub(crate) mod objgv;
60#[cfg(feature = "internal-testing-api")]
61pub mod ostree_manual;
62#[cfg(not(feature = "internal-testing-api"))]
63pub(crate) mod ostree_manual;
64
65pub(crate) mod statistics;
66
67mod utils;
68
69#[cfg(feature = "docgen")]
70mod docgen;
71pub mod fsverity;
72
73pub mod prelude {
75 #[doc(hidden)]
76 pub use ostree::prelude::*;
77}
78
79#[cfg(feature = "internal-testing-api")]
80pub mod fixture;
81#[cfg(feature = "internal-testing-api")]
82pub mod integrationtest;
83
84pub fn systemd_has_soft_reboot() -> bool {
87 const UNIT: &str = "/usr/lib/systemd/system/soft-reboot.target";
88 use std::sync::OnceLock;
89 static EXISTS: OnceLock<bool> = OnceLock::new();
90 *EXISTS.get_or_init(|| std::path::Path::new(UNIT).exists())
91}