Skip to content

Commit

Permalink
refactor(schema): Move PartialVersion into schemas
Browse files Browse the repository at this point in the history
  • Loading branch information
epage committed Dec 15, 2023
1 parent 19bcb3b commit 370cd35
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 3 deletions.
1 change: 0 additions & 1 deletion src/cargo/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,6 @@ pub mod ops;
pub mod sources;
pub mod util;
pub mod util_schemas;
pub mod util_semver;
mod version;

pub fn exit_with_error(err: CliError, shell: &mut Shell) -> ! {
Expand Down
2 changes: 2 additions & 0 deletions src/cargo/util_schemas/core/mod.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
mod package_id_spec;
mod partial_version;
mod source_kind;

pub use package_id_spec::PackageIdSpec;
pub use partial_version::PartialVersion;
pub use source_kind::GitReference;
pub use source_kind::SourceKind;
2 changes: 1 addition & 1 deletion src/cargo/util_schemas/core/package_id_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ use serde::{de, ser};
use url::Url;

use crate::util_schemas::core::GitReference;
use crate::util_schemas::core::PartialVersion;
use crate::util_schemas::core::SourceKind;
use crate::util_schemas::manifest::PackageName;
use crate::util_semver::PartialVersion;

/// Some or all of the data required to identify a package:
///
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/cargo/util_schemas/manifest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ use serde::{Deserialize, Serialize};
use serde_untagged::UntaggedEnumVisitor;

use crate::util_schemas::core::PackageIdSpec;
use crate::util_schemas::core::PartialVersion;
use crate::util_schemas::restricted_names;
use crate::util_semver::PartialVersion;

/// This type is used to deserialize `Cargo.toml` files.
#[derive(Debug, Deserialize, Serialize)]
Expand Down

0 comments on commit 370cd35

Please sign in to comment.