data: move the YAML data files into a top-level data/ directory

This commit is contained in:
2026-09-18 13:15:29 +02:00
parent 69f3c3954e
commit 6e5ecd2f45
6 changed files with 3 additions and 3 deletions
View File
+1 -1
View File
@@ -43,7 +43,7 @@ struct Data {
dist: std::collections::HashMap<String, DistData>, dist: std::collections::HashMap<String, DistData>,
} }
const DATA_YAML: &str = include_str!("../distro_info.yml"); const DATA_YAML: &str = include_str!("../data/distro_info.yml");
lazy_static! { lazy_static! {
// The YAML is include_str!'d at compile time and statically valid; if it // The YAML is include_str!'d at compile time and statically valid; if it
// ever failed to parse it would be a build-time bug that cannot be // ever failed to parse it would be a build-time bug that cannot be
+1 -1
View File
@@ -29,7 +29,7 @@ use ssh2::{CheckResult, HostKeyType, KnownHostFileKind, KnownHosts, Session};
use crate::ui::prompt; use crate::ui::prompt;
const HOST_KEYS_YAML: &str = include_str!("../../host_keys.yml"); const HOST_KEYS_YAML: &str = include_str!("../../data/host_keys.yml");
/// Pinned SSH host key fingerprints, loaded from the bundled /// Pinned SSH host key fingerprints, loaded from the bundled
/// `host_keys.yml` data file (same pattern as `distro_info.yml`): data /// `host_keys.yml` data file (same pattern as `distro_info.yml`): data
+1 -1
View File
@@ -44,7 +44,7 @@ pub struct QuirksConfig {
pub quirks: HashMap<String, PackageQuirks>, pub quirks: HashMap<String, PackageQuirks>,
} }
const QUIRKS_YAML: &str = include_str!("../quirks.yml"); const QUIRKS_YAML: &str = include_str!("../data/quirks.yml");
lazy_static! { lazy_static! {
static ref QUIRKS_DATA: QuirksConfig = serde_yaml::from_str(QUIRKS_YAML).unwrap(); static ref QUIRKS_DATA: QuirksConfig = serde_yaml::from_str(QUIRKS_YAML).unwrap();
} }