pass active plugins to fomod installer

This commit is contained in:
2026-03-11 00:30:50 +01:00
parent 295c9bd8c3
commit 96dda41c46
5 changed files with 38 additions and 13 deletions

View File

@@ -10,7 +10,7 @@ use std::{
use thiserror::Error;
use walkdir::WalkDir;
use crate::types::{self, ModdedInstance, RootConfig};
use crate::{types::{self, ModdedInstance, RootConfig}, utils::is_plugin_file};
pub fn create_loadorder(
root_config: &RootConfig,
@@ -76,13 +76,6 @@ pub fn create_loadorder(
Ok(sorted)
}
fn is_plugin_file(filename: impl AsRef<Path>) -> bool {
filename
.as_ref()
.extension()
.is_some_and(|ext| ext == "esp" || ext == "esm" || ext == "esl")
}
#[derive(Error, Debug)]
pub enum LoadOrderError {
#[error("Failed to read game directory")]