aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mling/Cargo.toml3
-rw-r--r--mling/build.rs2
-rw-r--r--mling/src/cli.rs8
-rw-r--r--mling/src/lib.rs19
-rw-r--r--mling/src/pkg_mgr/mod.rs3
-rw-r--r--mling/src/proj_mgr/mod.rs16
-rw-r--r--mling/src/proj_mgr/show_binaries.rs7
-rw-r--r--mling/src/proj_mgr/show_directories.rs4
8 files changed, 25 insertions, 37 deletions
diff --git a/mling/Cargo.toml b/mling/Cargo.toml
index 4954320..8008463 100644
--- a/mling/Cargo.toml
+++ b/mling/Cargo.toml
@@ -25,6 +25,7 @@ mingling = { path = "../mingling", features = [
"structural_renderer",
"extra_macros",
"yaml_serde_fmt",
+ "pathf"
] }
serde = { version = "1", features = ["derive"] }
@@ -37,4 +38,4 @@ toml.workspace = true
[build-dependencies]
chrono = "0.4"
-mingling = { path = "../mingling", features = ["comp", "builds"] }
+mingling = { path = "../mingling", features = ["comp", "pathf", "builds"] }
diff --git a/mling/build.rs b/mling/build.rs
index 5e210eb..b935c64 100644
--- a/mling/build.rs
+++ b/mling/build.rs
@@ -2,10 +2,12 @@ use std::path::Path;
use std::process::Command;
use mingling::build::build_comp_scripts;
+use mingling::builds::analyze_and_build_type_mapping;
fn main() {
build_version_info();
build_completion();
+ analyze_and_build_type_mapping().unwrap();
}
fn build_version_info() {
diff --git a/mling/src/cli.rs b/mling/src/cli.rs
index 01a836a..3000645 100644
--- a/mling/src/cli.rs
+++ b/mling/src/cli.rs
@@ -1,9 +1,9 @@
use crate::{
- CMDCompletion, ErrorDispatcherNotFound, Next, PackageManagerSetup, ProjectManagerSetup,
- ThisProgram,
+ CMDCompletion, ErrorDispatcherNotFound, Next, ThisProgram,
display::markdown,
eformat_cargo, eprintln_cargo, hformat_cargo,
- pkg_mgr::{CMDInstall, CMDListNamespace, CMDRemoveNamespace},
+ pkg_mgr::{CMDInstall, CMDListNamespace, CMDRemoveNamespace, PackageManagerSetup},
+ proj_mgr::ProjectManagerSetup,
res::{ResCurrentDir, ResManifestPath},
};
use colored::Colorize;
@@ -12,7 +12,7 @@ use mingling::{
hook::ProgramHook,
macros::{chain, help, pack, program_setup, r_println, renderer},
res::ResExitCode,
- setup::{ExitCodeSetup, StructuralRendererSetup, HelpFlagSetup, QuietFlagSetup},
+ setup::{ExitCodeSetup, HelpFlagSetup, QuietFlagSetup, StructuralRendererSetup},
};
use std::{env::current_dir, path::PathBuf, process::exit, str::FromStr};
diff --git a/mling/src/lib.rs b/mling/src/lib.rs
index 0e122f3..1bf38a7 100644
--- a/mling/src/lib.rs
+++ b/mling/src/lib.rs
@@ -5,23 +5,14 @@ use mingling::{
res::ResExitCode,
};
-pub mod cli;
-pub use cli::*;
-
mod cargo_style;
pub use cargo_style::*;
+
+pub mod cli;
pub mod display;
+pub mod errors;
+pub mod pkg_mgr;
+pub mod proj_mgr;
pub mod res;
-mod pkg_mgr;
-pub use pkg_mgr::*;
-
-mod proj_mgr;
-pub use proj_mgr::*;
-
-mod errors;
-pub use errors::*;
-
-use crate::display::markdown;
-
gen_program!();
diff --git a/mling/src/pkg_mgr/mod.rs b/mling/src/pkg_mgr/mod.rs
index 030529e..682b433 100644
--- a/mling/src/pkg_mgr/mod.rs
+++ b/mling/src/pkg_mgr/mod.rs
@@ -4,8 +4,7 @@ use mingling::{
macros::{dispatcher, program_setup},
};
-mod installer;
-pub use installer::*;
+pub mod installer;
dispatcher!("install");
dispatcher!("ls.namespace", CMDListNamespace => EntryListNamespace);
diff --git a/mling/src/proj_mgr/mod.rs b/mling/src/proj_mgr/mod.rs
index d0c4cbf..e0a4216 100644
--- a/mling/src/proj_mgr/mod.rs
+++ b/mling/src/proj_mgr/mod.rs
@@ -4,19 +4,11 @@ use mingling::{
macros::{dispatcher, program_setup},
};
-mod generator;
-pub use generator::*;
-
+pub mod checklist_reader;
+pub mod generator;
pub mod metadata;
-
-mod checklist_reader;
-pub use checklist_reader::*;
-
-mod show_binaries;
-pub use show_binaries::*;
-
-mod show_directories;
-pub use show_directories::*;
+pub mod show_binaries;
+pub mod show_directories;
dispatcher!("gen", CMDGenerateProject => EntryGenerateProject);
diff --git a/mling/src/proj_mgr/show_binaries.rs b/mling/src/proj_mgr/show_binaries.rs
index 384d8a4..d6872cf 100644
--- a/mling/src/proj_mgr/show_binaries.rs
+++ b/mling/src/proj_mgr/show_binaries.rs
@@ -8,8 +8,11 @@ use mingling::{
use serde::Serialize;
use crate::{
- EntryShowBinaries, Next,
- metadata::{CargoLockFile, read_metadata},
+ Next,
+ proj_mgr::{
+ EntryShowBinaries,
+ metadata::{CargoLockFile, read_metadata},
+ },
res::ResManifestPath,
};
diff --git a/mling/src/proj_mgr/show_directories.rs b/mling/src/proj_mgr/show_directories.rs
index 32020c9..6a20eee 100644
--- a/mling/src/proj_mgr/show_directories.rs
+++ b/mling/src/proj_mgr/show_directories.rs
@@ -6,8 +6,8 @@ use mingling::{
use serde::Serialize;
use crate::{
- EntryShowTargetDirectories, EntryShowWorkspaceDirectory, Next, metadata::read_metadata,
- res::ResManifestPath,
+ EntryShowTargetDirectories, EntryShowWorkspaceDirectory, Next,
+ proj_mgr::metadata::read_metadata, res::ResManifestPath,
};
#[derive(Serialize, Groupped)]