From abe78312ac4ca44bb8410ae7aa7e94968c040005 Mon Sep 17 00:00:00 2001 From: Fabio Valentini Date: Feb 06 2023 22:02:04 +0000 Subject: initial implementation of crate metadata loading / processing --- diff --git a/MANIFEST.in b/MANIFEST.in index 1aba38f..864dd73 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1 +1,2 @@ include LICENSE +include cargo2rpm/testdata/*.json diff --git a/cargo2rpm/metadata.py b/cargo2rpm/metadata.py new file mode 100644 index 0000000..f756892 --- /dev/null +++ b/cargo2rpm/metadata.py @@ -0,0 +1,259 @@ +import json +import logging +import subprocess +from typing import Dict, List, Set, Optional, Tuple + + +class FeatureFlags: + def __init__(self, all_features: bool = False, no_default_features: bool = False, features: List[str] = None): + if features is None: + features = [] + + if all_features and features: + raise ValueError("Cannot specify both '--all-features' and '--features'.") + + if all_features and no_default_features: + raise ValueError("Cannot specify both '--all-features' and '--no-default-features'.") + + self.all_features = all_features + self.no_default_features = no_default_features + self.features = features + + def __repr__(self): + parts = [] + + if self.all_features: + parts.append("all_features") + if self.no_default_features: + parts.append("no_default_features") + if self.features: + parts.append(f"features=[{', '.join(self.features)}]") + + if parts: + string = ", ".join(parts) + return f"[{string}]" + else: + return "[]" + + +class Dependency: + def __init__(self, data): + self._data = data + + def __repr__(self): + return repr(self._data) + + def name(self) -> str: + return self._data["name"] + + def req(self) -> str: + return self._data["req"] + + def kind(self) -> Optional[str]: + return self._data["kind"] + + def rename(self) -> Optional[str]: + return self._data["rename"] + + def optional(self) -> bool: + return self._data["optional"] + + def uses_default_features(self) -> bool: + return self._data["uses_default_features"] + + def features(self) -> List[str]: + return self._data["features"] + + +class Target: + def __init__(self, data): + self._data = data + + def __repr__(self): + return repr(self._data) + + def name(self) -> str: + return self._data["name"] + + def kind(self) -> List[str]: + return self._data["kind"] + + def crate_types(self) -> List[str]: + return self._data["crate_types"] + + +class Package: + def __init__(self, data): + self._data = data + + def __repr__(self): + return repr(self._data) + + def name(self) -> str: + return self._data["name"] + + def version(self) -> str: + return self._data["version"] + + def license(self) -> Optional[str]: + return self._data["license"] + + def license_file(self) -> Optional[str]: + return self._data["license_file"] + + def description(self) -> str: + return self._data["description"] + + def dependencies(self) -> List[Dependency]: + return [Dependency(dependency) for dependency in self._data["dependencies"]] + + def targets(self) -> List[Target]: + return [Target(target) for target in self._data["targets"]] + + def features(self) -> Dict[str, List[str]]: + return self._data["features"] + + def manifest_path(self) -> str: + return self._data["manifest_path"] + + def rust_version(self) -> str: + return self._data["rust_version"] + + def get_feature_names(self) -> Set[str]: + return set(self.features().keys()) + + def get_enabled_features_transitive(self, flags: FeatureFlags) -> Tuple[Set[str], Set[str], Dict[str, Set[str]], Dict[str, Set[str]]]: + # collect enabled features of this crate + enabled: Set[str] = set() + # collect enabled optional dependencies + optional_enabled: Set[str] = set() + # collect enabled features of other crates + other_enabled: Dict[str, Set[str]] = dict() + # collect conditionally enabled features of other crates + other_conditional: Dict[str, Set[str]] = dict() + + # process arguments + feature_names = self.get_feature_names() + + if not flags.no_default_features and "default" not in flags.features and "default" in feature_names: + enabled.add("default") + + if flags.all_features: + for feature in feature_names: + enabled.add(feature) + + for feature in flags.features: + enabled.add(feature) + + # calculate transitive closure of enabled features + while True: + new = set() + + for feature in enabled: + deps = self.features()[feature] + + for dep in deps: + # named optional dependency + if dep.startswith("dep:"): + name = dep.removeprefix("dep:") + optional_enabled.add(name) + continue + + # dependency/feature + if "/" in dep and "?/" not in dep: + name, feat = dep.split("/") + if name in other_enabled.keys(): + other_enabled[name].add(feat) + else: + other_enabled[name] = {feat} + continue + + # dependency?/feature + if "?/" in dep: + name, feat = dep.split("?/") + if name in other_conditional.keys(): + other_conditional[name].add(feat) + else: + other_conditional[name] = {feat} + continue + + if dep not in enabled: + new.add(dep) + + # continue until set of enabled "proper" features no longer changes + if new: + for feature in new: + enabled.add(feature) + else: + break + + return enabled, optional_enabled, other_enabled, other_conditional + + +class Metadata: + def __init__(self, data): + self._data = data + + def __repr__(self): + return repr(self._data) + + @staticmethod + def from_json(data: str) -> "Metadata": + return Metadata(json.loads(data)) + + @staticmethod + def from_cargo(cargo: str, path: str) -> "Metadata": + ret = subprocess.run( + [ + cargo, + "metadata", + "--quiet", + "--format-version", + "1", + "--offline", + "--no-deps", + "--manifest-path", + path, + ], + stdout=subprocess.PIPE, + stderr=subprocess.PIPE, + ) + + ret.check_returncode() + + data = ret.stdout.decode() + warn = ret.stderr.decode() + + if warn: + logging.warning("'cargo metadata' subcommand returned warnings:") + logging.warning(warn) + + return Metadata.from_json(data) + + def packages(self) -> List[Package]: + return [Package(package) for package in self._data["packages"]] + + def target_directory(self) -> str: + return self._data["target_directory"] + + def is_bin(self) -> bool: + for package in self.packages(): + for target in package.targets(): + if "bin" in target.kind(): + return True + return False + + def get_binaries(self) -> Set[str]: + bins = set() + for package in self.packages(): + for target in package.targets(): + if "bin" in target.kind(): + bins.add(target.name()) + return bins + + def is_lib(self) -> bool: + for package in self.packages(): + for target in package.targets(): + if "lib" in target.kind(): + return True + return False diff --git a/cargo2rpm/test_metadata.py b/cargo2rpm/test_metadata.py new file mode 100644 index 0000000..e486807 --- /dev/null +++ b/cargo2rpm/test_metadata.py @@ -0,0 +1,915 @@ +import importlib.resources +from typing import Dict, Set + +from cargo2rpm.metadata import Metadata, FeatureFlags + +import pytest + + +def load_metadata_from_resource(filename: str) -> Metadata: + data = importlib.resources.files("cargo2rpm.testdata").joinpath(filename).read_text() + return Metadata.from_json(data) + + +@pytest.mark.parametrize( + "filename", + [ + "ahash-0.8.3.json", + "assert_cmd-2.0.8.json", + "assert_fs-1.0.10.json", + "autocfg-1.1.0.json", + "bstr-1.2.0.json", + "cfg-if-1.0.0.json", + "clap-4.1.4.json", + "gstreamer-0.19.7.json", + "human-panic-1.1.0.json", + "libc-0.2.139.json", + "predicates-2.1.5.json", + "proc-macro2-1.0.50.json", + "quote-1.0.23.json", + "rand-0.8.5.json", + "rand_core-0.6.4.json", + "rust_decimal-1.28.0.json", + "serde-1.0.152.json", + "syn-1.0.107.json", + "time-0.3.17.json", + "unicode-xid-0.2.4.json", + "zbus-3.8.0.json", + "zola-0.16.1.json", + ], + ids=repr, +) +def test_metadata_smoke(filename: str): + metadata = load_metadata_from_resource(filename) + packages = metadata.packages() + assert len(packages) >= 1 + + +@pytest.mark.parametrize( + "filename,expected", + [ + ("ahash-0.8.3.json", False), + ("assert_cmd-2.0.8.json", True), + ("assert_fs-1.0.10.json", False), + ("autocfg-1.1.0.json", False), + ("bstr-1.2.0.json", False), + ("cfg-if-1.0.0.json", False), + ("clap-4.1.4.json", True), + ("gstreamer-0.19.7.json", False), + ("human-panic-1.1.0.json", False), + ("libc-0.2.139.json", False), + ("predicates-2.1.5.json", False), + ("proc-macro2-1.0.50.json", False), + ("quote-1.0.23.json", False), + ("rand-0.8.5.json", False), + ("rand_core-0.6.4.json", False), + ("rust_decimal-1.28.0.json", False), + ("serde-1.0.152.json", False), + ("syn-1.0.107.json", False), + ("time-0.3.17.json", False), + ("unicode-xid-0.2.4.json", False), + ("zbus-3.8.0.json", False), + ("zola-0.16.1.json", True), + ], + ids=repr, +) +def test_metadata_is_bin(filename: str, expected): + metadata = load_metadata_from_resource(filename) + assert metadata.is_bin() == expected + + +@pytest.mark.parametrize( + "filename,expected", + [ + ("ahash-0.8.3.json", True), + ("assert_cmd-2.0.8.json", True), + ("assert_fs-1.0.10.json", True), + ("autocfg-1.1.0.json", True), + ("bstr-1.2.0.json", True), + ("cfg-if-1.0.0.json", True), + ("clap-4.1.4.json", True), + ("gstreamer-0.19.7.json", True), + ("human-panic-1.1.0.json", True), + ("libc-0.2.139.json", True), + ("predicates-2.1.5.json", True), + ("proc-macro2-1.0.50.json", True), + ("quote-1.0.23.json", True), + ("rand-0.8.5.json", True), + ("rand_core-0.6.4.json", True), + ("rust_decimal-1.28.0.json", True), + ("serde-1.0.152.json", True), + ("syn-1.0.107.json", True), + ("time-0.3.17.json", True), + ("unicode-xid-0.2.4.json", True), + ("zbus-3.8.0.json", True), + ("zola-0.16.1.json", True), + ], + ids=repr, +) +def test_metadata_is_lib(filename: str, expected: bool): + metadata = load_metadata_from_resource(filename) + assert metadata.is_lib() == expected + + +@pytest.mark.parametrize( + "filename,expected", + [ + ("ahash-0.8.3.json", set()), + ("assert_cmd-2.0.8.json", {"bin_fixture"}), + ("assert_fs-1.0.10.json", set()), + ("autocfg-1.1.0.json", set()), + ("bstr-1.2.0.json", set()), + ("cfg-if-1.0.0.json", set()), + ("clap-4.1.4.json", {"stdio-fixture"}), + ("gstreamer-0.19.7.json", set()), + ("human-panic-1.1.0.json", set()), + ("libc-0.2.139.json", set()), + ("predicates-2.1.5.json", set()), + ("proc-macro2-1.0.50.json", set()), + ("quote-1.0.23.json", set()), + ("rand-0.8.5.json", set()), + ("rand_core-0.6.4.json", set()), + ("rust_decimal-1.28.0.json", set()), + ("serde-1.0.152.json", set()), + ("syn-1.0.107.json", set()), + ("time-0.3.17.json", set()), + ("unicode-xid-0.2.4.json", set()), + ("zbus-3.8.0.json", set()), + ("zola-0.16.1.json", {"zola"}), + ], + ids=repr, +) +def test_metadata_get_binaries(filename: str, expected: Set[str]): + metadata = load_metadata_from_resource(filename) + assert metadata.get_binaries() == expected + + +@pytest.mark.parametrize( + "filename,flags,expected_enabled,expected_optional,expected_other,expected_conditional", + [ + # default features + ("ahash-0.8.3.json", FeatureFlags(), {"default", "std", "runtime-rng", "getrandom"}, {"getrandom"}, dict(), dict()), + # all features + ( + "ahash-0.8.3.json", + FeatureFlags(all_features=True), + { + "default", + "std", + "runtime-rng", + "getrandom", + "atomic-polyfill", + "compile-time-rng", + "const-random", + "no-rng", + "serde", + }, + { + "atomic-polyfill", + "const-random", + "getrandom", + "serde", + }, + {"once_cell": {"atomic-polyfill"}}, + dict(), + ), + # no default features + ("ahash-0.8.3.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + compile-time-rng + ( + "ahash-0.8.3.json", + FeatureFlags(features=["compile-time-rng"]), + {"default", "std", "runtime-rng", "getrandom", "compile-time-rng", "const-random"}, + {"const-random", "getrandom"}, + dict(), + dict(), + ), + # no default features + compile-time-rng + ( + "ahash-0.8.3.json", + FeatureFlags(no_default_features=True, features=["compile-time-rng"]), + {"compile-time-rng", "const-random"}, + {"const-random"}, + dict(), + dict(), + ), + # default features + ("assert_cmd-2.0.8.json", FeatureFlags(), set(), set(), dict(), dict()), + # all features + ( + "assert_cmd-2.0.8.json", + FeatureFlags(all_features=True), + {"color", "color-auto"}, + {"concolor", "yansi"}, + {"predicates": {"color"}}, + {"concolor": {"std", "auto"}}, + ), + # no default features + ("assert_cmd-2.0.8.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + color + ( + "assert_cmd-2.0.8.json", + FeatureFlags(features=["color"]), + {"color"}, + {"concolor", "yansi"}, + {"predicates": {"color"}}, + {"concolor": {"std"}}, + ), + # no default features + color + ( + "assert_cmd-2.0.8.json", + FeatureFlags(no_default_features=True, features=["color"]), + {"color"}, + {"concolor", "yansi"}, + {"predicates": {"color"}}, + {"concolor": {"std"}}, + ), + # default features + ("assert_fs-1.0.10.json", FeatureFlags(), set(), set(), dict(), dict()), + # all features + ( + "assert_fs-1.0.10.json", + FeatureFlags(all_features=True), + {"color", "color-auto"}, + {"concolor", "yansi"}, + {"predicates": {"color"}}, + {"concolor": {"auto"}}, + ), + # no default features + ("assert_fs-1.0.10.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + color + ("assert_fs-1.0.10.json", FeatureFlags(features=["color"]), {"color"}, {"concolor", "yansi"}, {"predicates": {"color"}}, dict()), + # no default features + color + ( + "assert_fs-1.0.10.json", + FeatureFlags(no_default_features=True, features=["color"]), + {"color"}, + {"concolor", "yansi"}, + {"predicates": {"color"}}, + dict(), + ), + # default features + ("autocfg-1.1.0.json", FeatureFlags(), set(), set(), dict(), dict()), + # all features + ("autocfg-1.1.0.json", FeatureFlags(all_features=True), set(), set(), dict(), dict()), + # no default features + ("autocfg-1.1.0.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + ( + "bstr-1.2.0.json", + FeatureFlags(), + {"default", "std", "unicode", "alloc"}, + {"once_cell", "regex-automata"}, + {"memchr": {"std"}}, + {"serde": {"alloc", "std"}}, + ), + # all features + ( + "bstr-1.2.0.json", + FeatureFlags(all_features=True), + {"default", "alloc", "serde", "std", "unicode"}, + {"serde", "once_cell", "regex-automata"}, + {"memchr": {"std"}}, + {"serde": {"alloc", "std"}}, + ), + # no default features + ("bstr-1.2.0.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + serde + ( + "bstr-1.2.0.json", + FeatureFlags(features=["serde"]), + {"default", "std", "unicode", "alloc", "serde"}, + {"once_cell", "regex-automata", "serde"}, + {"memchr": {"std"}}, + {"serde": {"alloc", "std"}}, + ), + # no default features + serde + ( + "bstr-1.2.0.json", + FeatureFlags(no_default_features=True, features=["serde"]), + {"serde"}, + {"serde"}, + dict(), + dict(), + ), + # default features + ("cfg-if-1.0.0.json", FeatureFlags(), set(), set(), dict(), dict()), + # all features + ( + "cfg-if-1.0.0.json", + FeatureFlags(all_features=True), + {"compiler_builtins", "core", "rustc-dep-of-std"}, + {"compiler_builtins", "core"}, + dict(), + dict(), + ), + # no default features + ("cfg-if-1.0.0.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + ( + "clap-4.1.4.json", + FeatureFlags(), + {"default", "std", "color", "help", "usage", "error-context", "suggestions"}, + {"is-terminal", "termcolor", "strsim"}, + dict(), + dict(), + ), + # all features + ( + "clap-4.1.4.json", + FeatureFlags(all_features=True), + { + "default", + "cargo", + "color", + "debug", + "deprecated", + "derive", + "env", + "error-context", + "help", + "std", + "string", + "suggestions", + "unicode", + "unstable-doc", + "unstable-grouped", + "unstable-replace", + "unstable-v5", + "usage", + "wrap_help", + }, + {"once_cell", "is-terminal", "termcolor", "backtrace", "clap_derive", "strsim", "unicode-width", "unicase", "terminal_size"}, + dict(), + {"clap_derive": {"debug", "deprecated", "unstable-v5"}}, + ), + # no default features + ("clap-4.1.4.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + wrap_help + ( + "clap-4.1.4.json", + FeatureFlags(features=["wrap_help"]), + {"default", "std", "color", "help", "usage", "error-context", "suggestions", "wrap_help"}, + {"is-terminal", "termcolor", "strsim", "terminal_size"}, + dict(), + dict(), + ), + # no default features + wrap_help + ( + "clap-4.1.4.json", + FeatureFlags(no_default_features=True, features=["wrap_help"]), + {"wrap_help", "help"}, + {"terminal_size"}, + dict(), + dict(), + ), + # default features + ( + "gstreamer-0.19.7.json", + FeatureFlags(), + {"default"}, + set(), + dict(), + dict(), + ), + # all features + ( + "gstreamer-0.19.7.json", + FeatureFlags(all_features=True), + {"default", "dox", "serde", "serde_bytes", "v1_16", "v1_18", "v1_20", "v1_22"}, + {"serde", "serde_bytes"}, + {"ffi": {"dox", "v1_16", "v1_18", "v1_20", "v1_22"}, "glib": {"dox"}, "num-rational": {"serde"}}, + dict(), + ), + # no default features + ("gstreamer-0.19.7.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + serde + ( + "gstreamer-0.19.7.json", + FeatureFlags(features=["serde"]), + {"default", "serde", "serde_bytes"}, + {"serde", "serde_bytes"}, + {"num-rational": {"serde"}}, + dict(), + ), + # no default features + serde + ( + "gstreamer-0.19.7.json", + FeatureFlags(no_default_features=True, features=["serde"]), + {"serde", "serde_bytes"}, + {"serde", "serde_bytes"}, + {"num-rational": {"serde"}}, + dict(), + ), + # default features + ( + "human-panic-1.1.0.json", + FeatureFlags(), + {"default", "color"}, + {"concolor", "termcolor"}, + dict(), + dict(), + ), + # all features + ( + "human-panic-1.1.0.json", + FeatureFlags(all_features=True), + {"default", "color", "nightly"}, + {"concolor", "termcolor"}, + dict(), + dict(), + ), + # no default features + ("human-panic-1.1.0.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + nightly + ( + "human-panic-1.1.0.json", + FeatureFlags(features=["nightly"]), + {"default", "color", "nightly"}, + {"concolor", "termcolor"}, + dict(), + dict(), + ), + # no default features + nightly + ( + "human-panic-1.1.0.json", + FeatureFlags(no_default_features=True, features=["nightly"]), + {"nightly"}, + set(), + dict(), + dict(), + ), + # default features + ("libc-0.2.139.json", FeatureFlags(), {"default", "std"}, set(), dict(), dict()), + # all features + ( + "libc-0.2.139.json", + FeatureFlags(all_features=True), + {"default", "align", "const-extern-fn", "extra_traits", "rustc-dep-of-std", "rustc-std-workspace-core", "std", "use_std"}, + {"rustc-std-workspace-core"}, + dict(), + dict(), + ), + # no default features + ("libc-0.2.139.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + align + ( + "libc-0.2.139.json", + FeatureFlags(features=["align"]), + {"default", "std", "align"}, + set(), + dict(), + dict(), + ), + # no default features + align + ("libc-0.2.139.json", FeatureFlags(no_default_features=True, features=["align"]), {"align"}, set(), dict(), dict()), + # default features + ( + "predicates-2.1.5.json", + FeatureFlags(), + {"default", "diff", "regex", "float-cmp", "normalize-line-endings"}, + {"difflib", "regex", "float-cmp", "normalize-line-endings"}, + dict(), + dict(), + ), + # all features + ( + "predicates-2.1.5.json", + FeatureFlags(all_features=True), + {"default", "color", "color-auto", "diff", "float-cmp", "normalize-line-endings", "regex", "unstable"}, + {"yansi", "concolor", "difflib", "float-cmp", "normalize-line-endings", "regex"}, + dict(), + {"concolor": {"auto", "std"}}, + ), + # no default features + ("predicates-2.1.5.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + color + ( + "predicates-2.1.5.json", + FeatureFlags(features=["color"]), + {"default", "diff", "regex", "float-cmp", "normalize-line-endings", "color"}, + {"difflib", "regex", "float-cmp", "normalize-line-endings", "yansi", "concolor"}, + dict(), + {"concolor": {"std"}}, + ), + # no default features + color + ( + "predicates-2.1.5.json", + FeatureFlags(no_default_features=True, features=["color"]), + {"color"}, + {"yansi", "concolor"}, + dict(), + {"concolor": {"std"}}, + ), + # default features + ("proc-macro2-1.0.50.json", FeatureFlags(), {"default", "proc-macro"}, set(), dict(), dict()), + # all features + ( + "proc-macro2-1.0.50.json", + FeatureFlags(all_features=True), + {"default", "nightly", "proc-macro", "span-locations"}, + set(), + dict(), + dict(), + ), + # no default features + ("proc-macro2-1.0.50.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + span-locations + ( + "proc-macro2-1.0.50.json", + FeatureFlags(features=["span-locations"]), + {"default", "proc-macro", "span-locations"}, + set(), + dict(), + dict(), + ), + # no default features + span-locations + ( + "proc-macro2-1.0.50.json", + FeatureFlags(no_default_features=True, features=["span-locations"]), + {"span-locations"}, + set(), + dict(), + dict(), + ), + # default features + ("quote-1.0.23.json", FeatureFlags(), {"default", "proc-macro"}, set(), {"proc-macro2": {"proc-macro"}}, dict()), + # all features + ( + "quote-1.0.23.json", + FeatureFlags(all_features=True), + {"default", "proc-macro"}, + set(), + {"proc-macro2": {"proc-macro"}}, + dict(), + ), + # no default features + ("quote-1.0.23.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + ( + "rand-0.8.5.json", + FeatureFlags(), + {"default", "std", "std_rng", "alloc", "getrandom", "libc", "rand_chacha"}, + {"libc", "rand_chacha"}, + {"rand_core": {"alloc", "getrandom", "std"}, "rand_chacha": {"std"}}, + dict(), + ), + # all features + ( + "rand-0.8.5.json", + FeatureFlags(all_features=True), + { + "default", + "alloc", + "getrandom", + "libc", + "log", + "min_const_gen", + "nightly", + "packed_simd", + "rand_chacha", + "serde", + "serde1", + "simd_support", + "small_rng", + "std", + "std_rng", + }, + {"libc", "log", "packed_simd", "rand_chacha", "serde"}, + {"rand_core": {"alloc", "getrandom", "serde1", "std"}, "rand_chacha": {"std"}}, + dict(), + ), + # no default features + ("rand-0.8.5.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + serde1 + ( + "rand-0.8.5.json", + FeatureFlags(features=["serde1"]), + {"default", "std", "std_rng", "alloc", "getrandom", "libc", "rand_chacha", "serde1", "serde"}, + {"libc", "rand_chacha", "serde"}, + {"rand_core": {"alloc", "getrandom", "std", "serde1"}, "rand_chacha": {"std"}}, + dict(), + ), + # no default features + serde1 + ( + "rand-0.8.5.json", + FeatureFlags(no_default_features=True, features=["serde1"]), + {"serde1", "serde"}, + {"serde"}, + {"rand_core": {"serde1"}}, + dict(), + ), + # default features + ("rand_core-0.6.4.json", FeatureFlags(), set(), set(), dict(), dict()), + # all features + ( + "rand_core-0.6.4.json", + FeatureFlags(all_features=True), + {"alloc", "getrandom", "serde", "serde1", "std"}, + {"getrandom", "serde"}, + {"getrandom": {"std"}}, + dict(), + ), + # no default features + ("rand_core-0.6.4.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + ( + "rust_decimal-1.28.0.json", + FeatureFlags(), + {"default", "serde", "std"}, + {"serde"}, + {"arrayvec": {"std"}}, + { + "borsh": {"std"}, + "bytecheck": {"std"}, + "byteorder": {"std"}, + "bytes": {"std"}, + "rand": {"std"}, + "rkyv": {"std"}, + "serde": {"std"}, + "serde_json": {"std"}, + }, + ), + # all features + ( + "rust_decimal-1.28.0.json", + FeatureFlags(all_features=True), + { + "default", + "arbitrary", + "borsh", + "bytecheck", + "byteorder", + "bytes", + "c-repr", + "db-diesel-mysql", + "db-diesel-postgres", + "db-diesel1-mysql", + "db-diesel1-postgres", + "db-diesel2-mysql", + "db-diesel2-postgres", + "db-postgres", + "db-tokio-postgres", + "diesel1", + "diesel2", + "legacy-ops", + "maths", + "maths-nopanic", + "postgres", + "rand", + "rkyv", + "rkyv-safe", + "rocket", + "rocket-traits", + "rust-fuzz", + "serde", + "serde-arbitrary-precision", + "serde-bincode", + "serde-float", + "serde-str", + "serde-with-arbitrary-precision", + "serde-with-float", + "serde-with-str", + "serde_json", + "std", + "tokio-pg", + "tokio-postgres", + }, + { + "arbitrary", + "borsh", + "bytecheck", + "byteorder", + "bytes", + "diesel1", + "diesel2", + "postgres", + "rand", + "rkyv", + "rocket", + "serde", + "serde_json", + "tokio-postgres", + }, + { + "diesel1": {"mysql", "postgres"}, + "diesel2": {"mysql", "postgres"}, + "rkyv": {"validation"}, + "serde_json": {"arbitrary_precision", "std"}, + "arrayvec": {"std"}, + }, + { + "borsh": {"std"}, + "bytecheck": {"std"}, + "byteorder": {"std"}, + "bytes": {"std"}, + "rand": {"std"}, + "rkyv": {"std"}, + "serde": {"std"}, + "serde_json": {"std"}, + }, + ), + # no default features + ("rust_decimal-1.28.0.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + ("serde-1.0.152.json", FeatureFlags(), {"default", "std"}, set(), dict(), dict()), + # all features + ( + "serde-1.0.152.json", + FeatureFlags(all_features=True), + {"default", "alloc", "derive", "serde_derive", "rc", "std", "unstable"}, + {"serde_derive"}, + dict(), + dict(), + ), + # no default features + ("serde-1.0.152.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + derive + ( + "serde-1.0.152.json", + FeatureFlags(features=["derive"]), + {"default", "std", "derive", "serde_derive"}, + {"serde_derive"}, + dict(), + dict(), + ), + # default features + ( + "syn-1.0.107.json", + FeatureFlags(), + {"default", "derive", "parsing", "printing", "clone-impls", "proc-macro", "quote"}, + {"quote"}, + {"proc-macro2": {"proc-macro"}, "quote": {"proc-macro"}}, + dict(), + ), + # all features + ( + "syn-1.0.107.json", + FeatureFlags(all_features=True), + { + "default", + "clone-impls", + "derive", + "extra-traits", + "fold", + "full", + "parsing", + "printing", + "proc-macro", + "quote", + "test", + "visit", + "visit-mut", + }, + {"quote"}, + {"proc-macro2": {"proc-macro"}, "quote": {"proc-macro"}, "syn-test-suite": {"all-features"}}, + dict(), + ), + # no default features + ("syn-1.0.107.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + ( + "time-0.3.17.json", + FeatureFlags(), + {"default", "std", "alloc"}, + set(), + dict(), + {"serde": {"alloc"}}, + ), + # all features + ( + "time-0.3.17.json", + FeatureFlags(all_features=True), + { + "default", + "alloc", + "formatting", + "large-dates", + "local-offset", + "macros", + "parsing", + "quickcheck", + "rand", + "serde", + "serde-human-readable", + "serde-well-known", + "std", + "wasm-bindgen", + }, + {"itoa", "libc", "num_threads", "time-macros", "quickcheck", "rand", "serde", "js-sys"}, + dict(), + {"serde": {"alloc"}, "time-macros": {"formatting", "large-dates", "parsing", "serde"}}, + ), + # no default features + ("time-0.3.17.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + serde + ( + "time-0.3.17.json", + FeatureFlags(features=["serde"]), + {"default", "std", "alloc", "serde"}, + {"serde"}, + dict(), + {"serde": {"alloc"}, "time-macros": {"serde"}}, + ), + # no default features + serde + ( + "time-0.3.17.json", + FeatureFlags(no_default_features=True, features=["serde"]), + {"serde"}, + {"serde"}, + dict(), + {"time-macros": {"serde"}}, + ), + # default features + ("unicode-xid-0.2.4.json", FeatureFlags(), {"default"}, set(), dict(), dict()), + # all features + ("unicode-xid-0.2.4.json", FeatureFlags(all_features=True), {"default", "bench", "no_std"}, set(), dict(), dict()), + # no default features + ("unicode-xid-0.2.4.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + ( + "zbus-3.8.0.json", + FeatureFlags(), + {"default", "async-io", "async-executor", "async-task", "async-lock"}, + {"async-io", "async-executor", "async-task", "async-lock"}, + dict(), + dict(), + ), + # all features + ( + "zbus-3.8.0.json", + FeatureFlags(all_features=True), + { + "default", + "async-executor", + "async-io", + "async-lock", + "async-task", + "chrono", + "gvariant", + "lazy_static", + "quick-xml", + "serde-xml-rs", + "time", + "tokio", + "tokio-vsock", + "url", + "uuid", + "vsock", + "windows-gdbus", + "xml", + }, + { + "async-executor", + "async-io", + "async-lock", + "async-task", + "lazy_static", + "quick-xml", + "serde-xml-rs", + "tokio", + "tokio-vsock", + "vsock", + }, + {"zvariant": {"chrono", "gvariant", "time", "url", "uuid"}}, + dict(), + ), + # no default features + ("zbus-3.8.0.json", FeatureFlags(no_default_features=True), set(), set(), dict(), dict()), + # default features + tokio + ( + "zbus-3.8.0.json", + FeatureFlags(features=["tokio"]), + {"default", "async-io", "async-executor", "async-task", "async-lock", "tokio", "lazy_static"}, + {"async-io", "async-executor", "async-task", "async-lock", "tokio", "lazy_static"}, + dict(), + dict(), + ), + ], + ids=repr, +) +def test_package_get_enabled_features_transitive( + filename: str, + flags: FeatureFlags, + expected_enabled: Set[str], + expected_optional: Set[str], + expected_other: Dict[str, Set[str]], + expected_conditional: Dict[str, Set[str]], +): + metadata = load_metadata_from_resource(filename) + enabled, optional_enabled, other_enabled, other_conditional = metadata.packages()[0].get_enabled_features_transitive(flags) + + assert enabled == expected_enabled + assert optional_enabled == expected_optional + assert other_enabled == expected_other + assert other_conditional == expected_conditional + + +def test_feature_flags_invalid(): + with pytest.raises(ValueError) as exc: + FeatureFlags(all_features=True, features=["default"]) + assert "Cannot specify both '--all-features' and '--features'." in str(exc.value) + + with pytest.raises(ValueError) as exc: + FeatureFlags(no_default_features=True, all_features=True) + assert "Cannot specify both '--all-features' and '--no-default-features'." in str(exc.value) diff --git a/cargo2rpm/testdata/.gitignore b/cargo2rpm/testdata/.gitignore new file mode 100644 index 0000000..e22893e --- /dev/null +++ b/cargo2rpm/testdata/.gitignore @@ -0,0 +1 @@ +/*.pretty diff --git a/cargo2rpm/testdata/README.md b/cargo2rpm/testdata/README.md new file mode 100644 index 0000000..ff28225 --- /dev/null +++ b/cargo2rpm/testdata/README.md @@ -0,0 +1,30 @@ +# cargo2rpm test data + +This directory includes the output of `cargo metadata` for the 10 most popular +crates of all time on plus some crates that use additional +cargo features (i.e. "namespaced dependencies" and "weak dependency features") +to improve test coverage for the implementation of these features. + +The JSON files were generated by downloading `.crate` files from +, unpacking the sources, and then running this command: + +```shell +cargo metadata --quiet --format-version 1 --offline --no-deps \ + --manifest-path ./Cargo.toml > $crate-$version.json +``` + +The output of `cargo metadata` is unformatted JSON without whitespace or line +breaks. The `prettyjson` script can be used to reformat them as human-readable +JSON: + +```shell +./prettyjson syn-1.0.107.json syn-1.0.107.json.pretty +``` + +Or, to generate human-readable JSON files for all test data: + +```shell +for i in $(find -name "*.json") ; do + ./prettyjson $i $i.pretty ; +done +``` diff --git a/cargo2rpm/testdata/ahash-0.8.3.json b/cargo2rpm/testdata/ahash-0.8.3.json new file mode 100644 index 0000000..b86c856 --- /dev/null +++ b/cargo2rpm/testdata/ahash-0.8.3.json @@ -0,0 +1 @@ +{"packages":[{"name":"ahash","version":"0.8.3","id":"ahash 0.8.3 (path+file:///home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3)","license":"MIT OR Apache-2.0","license_file":null,"description":"A non-cryptographic hash function using AES-NI for high performance","source":null,"dependencies":[{"name":"atomic-polyfill","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"cfg-if","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"const-random","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.12","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"getrandom","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.7","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.117","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"criterion","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.2","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":["html_reports"],"target":null,"registry":null},{"name":"fnv","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.5","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"fxhash","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"hashbrown","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.12.3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"hex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.2","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"no-panic","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.10","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"rand","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8.5","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"seahash","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^4.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde_json","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.59","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"version_check","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9.4","kind":"build","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"once_cell","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.13.1","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["unstable","alloc"],"target":"cfg(not(all(target_arch = \"arm\", target_os = \"none\")))","registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"ahash","src_path":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"bench","src_path":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/tests/bench.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"map_tests","src_path":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/tests/map_tests.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"nopanic","src_path":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/tests/nopanic.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["bench"],"crate_types":["bin"],"name":"ahash","src_path":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/tests/bench.rs","edition":"2018","doc":false,"doctest":false,"test":false},{"kind":["bench"],"crate_types":["bin"],"name":"map","src_path":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/tests/map_tests.rs","edition":"2018","doc":false,"doctest":false,"test":false},{"kind":["custom-build"],"crate_types":["bin"],"name":"build-script-build","src_path":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/./build.rs","edition":"2018","doc":false,"doctest":false,"test":false}],"features":{"atomic-polyfill":["dep:atomic-polyfill","once_cell/atomic-polyfill"],"compile-time-rng":["const-random"],"const-random":["dep:const-random"],"default":["std","runtime-rng"],"getrandom":["dep:getrandom"],"no-rng":[],"runtime-rng":["getrandom"],"serde":["dep:serde"],"std":[]},"manifest_path":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/Cargo.toml","metadata":{"docs":{"rs":{"rustc-args":["-C","target-feature=+aes"],"rustdoc-args":["-C","target-feature=+aes"],"features":["std"]}}},"publish":null,"authors":["Tom Kaitchuck "],"categories":["algorithms","data-structures","no-std"],"keywords":["hash","hasher","hashmap","aes","no-std"],"readme":"README.md","repository":"https://github.com/tkaitchuck/ahash","homepage":null,"documentation":"https://docs.rs/ahash","edition":"2018","links":null,"default_run":null,"rust_version":null}],"workspace_members":["ahash 0.8.3 (path+file:///home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-ahash/ahash-0.8.3","metadata":null} diff --git a/cargo2rpm/testdata/assert_cmd-2.0.8.json b/cargo2rpm/testdata/assert_cmd-2.0.8.json new file mode 100644 index 0000000..de1c4f3 --- /dev/null +++ b/cargo2rpm/testdata/assert_cmd-2.0.8.json @@ -0,0 +1 @@ +{"packages":[{"name":"assert_cmd","version":"2.0.8","id":"assert_cmd 2.0.8 (path+file:///home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8)","license":"MIT OR Apache-2.0","license_file":null,"description":"Test CLI Applications.","source":null,"dependencies":[{"name":"bstr","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"concolor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.0.11","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"doc-comment","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"predicates","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.1","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["diff"],"target":null,"registry":null},{"name":"predicates-core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"predicates-tree","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"wait-timeout","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"yansi","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"escargot","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"assert_cmd","src_path":"/home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["bin"],"crate_types":["bin"],"name":"bin_fixture","src_path":"/home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8/src/bin/bin_fixture.rs","edition":"2021","doc":true,"doctest":false,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"example_fixture","src_path":"/home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8/examples/example_fixture.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"failure","src_path":"/home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8/examples/failure.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{"color":["dep:yansi","dep:concolor","concolor?/std","predicates/color"],"color-auto":["color","concolor?/auto"]},"manifest_path":"/home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8/Cargo.toml","metadata":{"release":{"pre-release-replacements":[{"file":"CHANGELOG.md","search":"Unreleased","replace":"{{version}}","min":1},{"file":"CHANGELOG.md","search":"\\.\\.\\.HEAD","replace":"...{{tag_name}}","exactly":1},{"file":"CHANGELOG.md","search":"ReleaseDate","replace":"{{date}}","min":1},{"file":"CHANGELOG.md","search":"","replace":"\n## [Unreleased] - ReleaseDate\n","exactly":1},{"file":"CHANGELOG.md","search":"","replace":"\n[Unreleased]: https://github.com/assert-rs/assert_cmd/compare/{{tag_name}}...HEAD","exactly":1}]}},"publish":null,"authors":["Pascal Hertleif ","Ed Page "],"categories":["development-tools::testing"],"keywords":["cli","test","assert","command","duct"],"readme":"README.md","repository":"https://github.com/assert-rs/assert_cmd.git","homepage":"https://github.com/assert-rs/assert_cmd","documentation":"http://docs.rs/assert_cmd/","edition":"2021","links":null,"default_run":null,"rust_version":"1.60.0"}],"workspace_members":["assert_cmd 2.0.8 (path+file:///home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-assert_cmd/assert_cmd-2.0.8","metadata":null} diff --git a/cargo2rpm/testdata/assert_fs-1.0.10.json b/cargo2rpm/testdata/assert_fs-1.0.10.json new file mode 100644 index 0000000..593d430 --- /dev/null +++ b/cargo2rpm/testdata/assert_fs-1.0.10.json @@ -0,0 +1 @@ +{"packages":[{"name":"assert_fs","version":"1.0.10","id":"assert_fs 1.0.10 (path+file:///home/deca/Workspace/depfoo/rust-assert_fs/assert_fs-1.0.10)","license":"MIT OR Apache-2.0","license_file":null,"description":"Filesystem fixtures and assertions for testing.","source":null,"dependencies":[{"name":"concolor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.0.11","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"doc-comment","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"globwalk","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"predicates","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.0.3","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["diff"],"target":null,"registry":null},{"name":"predicates-core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"predicates-tree","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"yansi","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"assert_fs","src_path":"/home/deca/Workspace/depfoo/rust-assert_fs/assert_fs-1.0.10/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"failure","src_path":"/home/deca/Workspace/depfoo/rust-assert_fs/assert_fs-1.0.10/examples/failure.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{"color":["dep:yansi","dep:concolor","predicates/color"],"color-auto":["color","concolor?/auto"]},"manifest_path":"/home/deca/Workspace/depfoo/rust-assert_fs/assert_fs-1.0.10/Cargo.toml","metadata":{"release":{"pre-release-replacements":[{"file":"CHANGELOG.md","search":"Unreleased","replace":"{{version}}","min":1},{"file":"CHANGELOG.md","search":"\\.\\.\\.HEAD","replace":"...{{tag_name}}","exactly":1},{"file":"CHANGELOG.md","search":"ReleaseDate","replace":"{{date}}","min":1},{"file":"CHANGELOG.md","search":"","replace":"\n## [Unreleased] - ReleaseDate\n","exactly":1},{"file":"CHANGELOG.md","search":"","replace":"\n[Unreleased]: https://github.com/assert-rs/assert_fs/compare/{{tag_name}}...HEAD","exactly":1}]}},"publish":null,"authors":["Ed Page "],"categories":["development-tools::testing"],"keywords":["filesystem","test","assert","fixture"],"readme":"README.md","repository":"https://github.com/assert-rs/assert_fs.git","homepage":"https://github.com/assert-rs/assert_fs","documentation":"http://docs.rs/assert_fs/","edition":"2021","links":null,"default_run":null,"rust_version":"1.60.0"}],"workspace_members":["assert_fs 1.0.10 (path+file:///home/deca/Workspace/depfoo/rust-assert_fs/assert_fs-1.0.10)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-assert_fs/assert_fs-1.0.10/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-assert_fs/assert_fs-1.0.10","metadata":null} diff --git a/cargo2rpm/testdata/autocfg-1.1.0.json b/cargo2rpm/testdata/autocfg-1.1.0.json new file mode 100644 index 0000000..d1cdb3a --- /dev/null +++ b/cargo2rpm/testdata/autocfg-1.1.0.json @@ -0,0 +1 @@ +{"packages":[{"name":"autocfg","version":"1.1.0","id":"autocfg 1.1.0 (path+file:///home/deca/Workspace/rust-autocfg/autocfg-1.1.0)","license":"Apache-2.0 OR MIT","license_file":null,"description":"Automatic cfg for Rust compiler features","source":null,"dependencies":[],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"autocfg","src_path":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0/src/lib.rs","edition":"2015","doc":true,"doctest":true,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"integers","src_path":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0/examples/integers.rs","edition":"2015","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"paths","src_path":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0/examples/paths.rs","edition":"2015","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"traits","src_path":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0/examples/traits.rs","edition":"2015","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"versions","src_path":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0/examples/versions.rs","edition":"2015","doc":false,"doctest":false,"test":false},{"kind":["test"],"crate_types":["bin"],"name":"rustflags","src_path":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0/tests/rustflags.rs","edition":"2015","doc":false,"doctest":false,"test":true}],"features":{},"manifest_path":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0/Cargo.toml","metadata":null,"publish":null,"authors":["Josh Stone "],"categories":["development-tools::build-utils"],"keywords":["rustc","build","autoconf"],"readme":"README.md","repository":"https://github.com/cuviper/autocfg","homepage":null,"documentation":null,"edition":"2015","links":null,"default_run":null,"rust_version":null}],"workspace_members":["autocfg 1.1.0 (path+file:///home/deca/Workspace/rust-autocfg/autocfg-1.1.0)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0/target","version":1,"workspace_root":"/home/deca/Workspace/rust-autocfg/autocfg-1.1.0","metadata":null} diff --git a/cargo2rpm/testdata/bstr-1.2.0.json b/cargo2rpm/testdata/bstr-1.2.0.json new file mode 100644 index 0000000..2f25eb7 --- /dev/null +++ b/cargo2rpm/testdata/bstr-1.2.0.json @@ -0,0 +1 @@ +{"packages":[{"name":"bstr","version":"1.2.0","id":"bstr 1.2.0 (path+file:///home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0)","license":"MIT OR Apache-2.0","license_file":null,"description":"A string type that is not required to be valid UTF-8.","source":null,"dependencies":[{"name":"memchr","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.4.0","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"once_cell","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.14.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"regex-automata","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.5","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.85","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"quickcheck","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"ucd-parse","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"unicode-segmentation","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.2.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"bstr","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"graphemes","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/examples/graphemes.rs","edition":"2021","required-features":["std","unicode"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"lines","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/examples/lines.rs","edition":"2021","required-features":["std"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"uppercase","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/examples/uppercase.rs","edition":"2021","required-features":["std","unicode"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"words","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/examples/words.rs","edition":"2021","required-features":["std","unicode"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"graphemes-std","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/examples/graphemes-std.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"lines-std","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/examples/lines-std.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"uppercase-std","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/examples/uppercase-std.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"words-std","src_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/examples/words-std.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{"alloc":["serde?/alloc"],"default":["std","unicode"],"serde":["dep:serde"],"std":["alloc","memchr/std","serde?/std"],"unicode":["dep:once_cell","dep:regex-automata"]},"manifest_path":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true,"rustdoc-args":["--cfg","docsrs"]}}},"publish":null,"authors":["Andrew Gallant "],"categories":["text-processing","encoding"],"keywords":["string","str","byte","bytes","text"],"readme":"README.md","repository":"https://github.com/BurntSushi/bstr","homepage":"https://github.com/BurntSushi/bstr","documentation":"https://docs.rs/bstr","edition":"2021","links":null,"default_run":null,"rust_version":"1.60"}],"workspace_members":["bstr 1.2.0 (path+file:///home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-bstr/bstr-1.2.0","metadata":null} diff --git a/cargo2rpm/testdata/cfg-if-1.0.0.json b/cargo2rpm/testdata/cfg-if-1.0.0.json new file mode 100644 index 0000000..1b98f72 --- /dev/null +++ b/cargo2rpm/testdata/cfg-if-1.0.0.json @@ -0,0 +1 @@ +{"packages":[{"name":"cfg-if","version":"1.0.0","id":"cfg-if 1.0.0 (path+file:///home/deca/Workspace/rust-cfg-if/cfg-if-1.0.0)","license":"MIT/Apache-2.0","license_file":null,"description":"A macro to ergonomically define an item depending on a large number of #[cfg]\nparameters. Structured like an if-else chain, the first matching branch is the\nitem that gets emitted.\n","source":null,"dependencies":[{"name":"compiler_builtins","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.2","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"rustc-std-workspace-core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.0","kind":null,"rename":"core","optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"cfg-if","src_path":"/home/deca/Workspace/rust-cfg-if/cfg-if-1.0.0/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"xcrate","src_path":"/home/deca/Workspace/rust-cfg-if/cfg-if-1.0.0/tests/xcrate.rs","edition":"2018","doc":false,"doctest":false,"test":true}],"features":{"compiler_builtins":["dep:compiler_builtins"],"core":["dep:core"],"rustc-dep-of-std":["core","compiler_builtins"]},"manifest_path":"/home/deca/Workspace/rust-cfg-if/cfg-if-1.0.0/Cargo.toml","metadata":null,"publish":null,"authors":["Alex Crichton "],"categories":[],"keywords":[],"readme":"README.md","repository":"https://github.com/alexcrichton/cfg-if","homepage":"https://github.com/alexcrichton/cfg-if","documentation":"https://docs.rs/cfg-if","edition":"2018","links":null,"default_run":null,"rust_version":null}],"workspace_members":["cfg-if 1.0.0 (path+file:///home/deca/Workspace/rust-cfg-if/cfg-if-1.0.0)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-cfg-if/cfg-if-1.0.0/target","version":1,"workspace_root":"/home/deca/Workspace/rust-cfg-if/cfg-if-1.0.0","metadata":null} diff --git a/cargo2rpm/testdata/clap-4.1.4.json b/cargo2rpm/testdata/clap-4.1.4.json new file mode 100644 index 0000000..00615da --- /dev/null +++ b/cargo2rpm/testdata/clap-4.1.4.json @@ -0,0 +1 @@ +{"packages":[{"name":"clap","version":"4.1.4","id":"clap 4.1.4 (path+file:///home/deca/Workspace/depfoo/rust-clap/clap-4.1.4)","license":"MIT OR Apache-2.0","license_file":null,"description":"A simple to use, efficient, and full-featured Command Line Argument Parser","source":null,"dependencies":[{"name":"backtrace","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"bitflags","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"clap_derive","source":"registry+https://github.com/rust-lang/crates.io-index","req":"=4.1.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"clap_lex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"is-terminal","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"once_cell","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.12.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"strsim","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.10","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"termcolor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.1.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"terminal_size","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"unicase","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.6","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"unicode-width","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.9","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"humantime","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"rustversion","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"shlex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"snapbox","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"static_assertions","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"trybuild","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.73","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"trycmd","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.14.9","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["color-auto","diff","examples"],"target":null,"registry":null},{"name":"unic-emoji-char","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"clap","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["bin"],"crate_types":["bin"],"name":"stdio-fixture","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/src/bin/stdio-fixture.rs","edition":"2021","doc":true,"doctest":false,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"demo","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/demo.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"cargo-example","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/cargo-example.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"cargo-example-derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/cargo-example-derive.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"escaped-positional","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/escaped-positional.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"escaped-positional-derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/escaped-positional-derive.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"find","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/find.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"git-derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/git-derive.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"typed-derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/typed-derive.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"busybox","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/multicall-busybox.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"hostname","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/multicall-hostname.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"repl","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/repl.rs","edition":"2021","required-features":["help"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"01_quick","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/01_quick.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"02_apps","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/02_apps.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"02_crate","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/02_crate.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"02_app_settings","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/02_app_settings.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_01_flag_bool","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/03_01_flag_bool.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_01_flag_count","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/03_01_flag_count.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_02_option","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/03_02_option.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_02_option_mult","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/03_02_option_mult.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_03_positional","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/03_03_positional.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_03_positional_mult","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/03_03_positional_mult.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_04_subcommands","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/03_04_subcommands.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_05_default_values","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/03_05_default_values.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_01_possible","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/04_01_possible.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_01_enum","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/04_01_enum.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_02_parse","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/04_02_parse.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_02_validate","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/04_02_validate.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_03_relations","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/04_03_relations.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_04_custom","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/04_04_custom.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"05_01_assert","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_builder/05_01_assert.rs","edition":"2021","required-features":["cargo"],"doc":false,"doctest":false,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"01_quick_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/01_quick.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"02_apps_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/02_apps.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"02_crate_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/02_crate.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"02_app_settings_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/02_app_settings.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_01_flag_bool_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_01_flag_bool.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_01_flag_count_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_01_flag_count.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_02_option_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_02_option.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_02_option_mult_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_02_option_mult.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_03_positional_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_03_positional.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_03_positional_mult_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_03_positional_mult.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_04_subcommands_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_04_subcommands.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_04_subcommands_alt_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_04_subcommands_alt.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"03_05_default_values_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/03_05_default_values.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_01_enum_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/04_01_enum.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_02_parse_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/04_02_parse.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_02_validate_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/04_02_validate.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_03_relations_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/04_03_relations.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"04_04_custom_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/04_04_custom.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"05_01_assert_derive","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/tutorial_derive/05_01_assert.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"interop_augment_args","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/derive_ref/augment_args.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"interop_augment_subcommands","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/derive_ref/augment_subcommands.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"interop_hand_subcommand","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/derive_ref/hand_subcommand.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"interop_flatten_hand_args","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/derive_ref/flatten_hand_args.rs","edition":"2021","required-features":["derive"],"doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"git","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/git.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["example"],"crate_types":["bin"],"name":"pacman","src_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/examples/pacman.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{"cargo":["dep:once_cell"],"color":["dep:is-terminal","dep:termcolor"],"debug":["clap_derive?/debug","dep:backtrace"],"default":["std","color","help","usage","error-context","suggestions"],"deprecated":["clap_derive?/deprecated"],"derive":["dep:clap_derive","dep:once_cell"],"env":[],"error-context":[],"help":[],"std":[],"string":[],"suggestions":["dep:strsim","error-context"],"unicode":["dep:unicode-width","dep:unicase"],"unstable-doc":["derive","cargo","wrap_help","env","unicode","string","unstable-replace"],"unstable-grouped":[],"unstable-replace":[],"unstable-v5":["clap_derive?/unstable-v5","deprecated"],"usage":[],"wrap_help":["help","dep:terminal_size"]},"manifest_path":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/Cargo.toml","metadata":{"docs":{"rs":{"features":["unstable-doc"],"rustdoc-args":["--cfg","docsrs"],"cargo-args":["-Zunstable-options","-Zrustdoc-scrape-examples"]}},"playground":{"features":["unstable-doc"]},"release":{"shared-version":true,"tag-name":"v{{version}}","pre-release-replacements":[{"file":"CHANGELOG.md","search":"Unreleased","replace":"{{version}}","min":1},{"file":"CHANGELOG.md","search":"\\.\\.\\.HEAD","replace":"...{{tag_name}}","exactly":1},{"file":"CHANGELOG.md","search":"ReleaseDate","replace":"{{date}}","min":1},{"file":"CHANGELOG.md","search":"","replace":"\n## [Unreleased] - ReleaseDate\n","exactly":1},{"file":"CHANGELOG.md","search":"","replace":"\n[Unreleased]: https://github.com/clap-rs/clap/compare/{{tag_name}}...HEAD","exactly":1}]}},"publish":null,"authors":[],"categories":["command-line-interface"],"keywords":["argument","cli","arg","parser","parse"],"readme":"README.md","repository":"https://github.com/clap-rs/clap","homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":"1.64.0"}],"workspace_members":["clap 4.1.4 (path+file:///home/deca/Workspace/depfoo/rust-clap/clap-4.1.4)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-clap/clap-4.1.4","metadata":null} diff --git a/cargo2rpm/testdata/gstreamer-0.19.7.json b/cargo2rpm/testdata/gstreamer-0.19.7.json new file mode 100644 index 0000000..9bda7d1 --- /dev/null +++ b/cargo2rpm/testdata/gstreamer-0.19.7.json @@ -0,0 +1 @@ +{"packages":[{"name":"gstreamer","version":"0.19.7","id":"gstreamer 0.19.7 (path+file:///home/deca/Workspace/depfoo/rust-gstreamer/gstreamer-0.19.7)","license":"MIT OR Apache-2.0","license_file":null,"description":"Rust bindings for GStreamer","source":null,"dependencies":[{"name":"bitflags","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"cfg-if","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"gstreamer-sys","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.19","kind":null,"rename":"ffi","optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures-channel","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures-core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures-util","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"glib","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.16.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"libc","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"muldiv","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"num-integer","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"num-rational","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"once_cell","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"option-operations","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5","kind":null,"rename":"opt-ops","optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"paste","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"pretty-hex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"serde_bytes","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.11","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"thiserror","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures-executor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"gir-format-check","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"ron","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde_json","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"gstreamer","src_path":"/home/deca/Workspace/depfoo/rust-gstreamer/gstreamer-0.19.7/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"check_gir","src_path":"/home/deca/Workspace/depfoo/rust-gstreamer/gstreamer-0.19.7/tests/check_gir.rs","edition":"2021","doc":false,"doctest":false,"test":true}],"features":{"default":[],"dox":["ffi/dox","glib/dox","serde"],"serde":["num-rational/serde","dep:serde","serde_bytes"],"serde_bytes":["dep:serde_bytes"],"v1_16":["ffi/v1_16"],"v1_18":["ffi/v1_18","v1_16"],"v1_20":["ffi/v1_20","v1_18"],"v1_22":["ffi/v1_22","v1_20"]},"manifest_path":"/home/deca/Workspace/depfoo/rust-gstreamer/gstreamer-0.19.7/Cargo.toml","metadata":{"docs":{"rs":{"features":["dox"]}}},"publish":null,"authors":["Sebastian Dröge "],"categories":["api-bindings","multimedia"],"keywords":["gstreamer","multimedia","audio","video","gnome"],"readme":"README.md","repository":"https://gitlab.freedesktop.org/gstreamer/gstreamer-rs","homepage":"https://gstreamer.freedesktop.org","documentation":"https://gstreamer.pages.freedesktop.org/gstreamer-rs/stable/latest/docs/gstreamer/","edition":"2021","links":null,"default_run":null,"rust_version":"1.63"}],"workspace_members":["gstreamer 0.19.7 (path+file:///home/deca/Workspace/depfoo/rust-gstreamer/gstreamer-0.19.7)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-gstreamer/gstreamer-0.19.7/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-gstreamer/gstreamer-0.19.7","metadata":null} diff --git a/cargo2rpm/testdata/human-panic-1.1.0.json b/cargo2rpm/testdata/human-panic-1.1.0.json new file mode 100644 index 0000000..48e2707 --- /dev/null +++ b/cargo2rpm/testdata/human-panic-1.1.0.json @@ -0,0 +1 @@ +{"packages":[{"name":"human-panic","version":"1.1.0","id":"human-panic 1.1.0 (path+file:///home/deca/Workspace/depfoo/rust-human-panic/human-panic-1.1.0)","license":"MIT OR Apache-2.0","license_file":null,"description":"Panic messages for humans","source":null,"dependencies":[{"name":"backtrace","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.9","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"concolor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.0.11","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":["auto"],"target":null,"registry":null},{"name":"os_info","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.0.6","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.79","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde_derive","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.79","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"termcolor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.4","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"toml","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"uuid","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8.0","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["v4"],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"human-panic","src_path":"/home/deca/Workspace/depfoo/rust-human-panic/human-panic-1.1.0/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true}],"features":{"color":["dep:termcolor","dep:concolor"],"default":["color"],"nightly":[]},"manifest_path":"/home/deca/Workspace/depfoo/rust-human-panic/human-panic-1.1.0/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true}},"release":{"pre-release-replacements":[{"file":"CHANGELOG.md","search":"Unreleased","replace":"{{version}}","min":1},{"file":"CHANGELOG.md","search":"\\.\\.\\.HEAD","replace":"...{{tag_name}}","exactly":1},{"file":"CHANGELOG.md","search":"ReleaseDate","replace":"{{date}}","min":1},{"file":"CHANGELOG.md","search":"","replace":"\n## [Unreleased] - ReleaseDate\n","exactly":1},{"file":"CHANGELOG.md","search":"","replace":"\n[Unreleased]: https://github.com/rust-cli/human-panic/compare/{{tag_name}}...HEAD","exactly":1}]}},"publish":null,"authors":[],"categories":["command-line-interface"],"keywords":["cli","panic"],"readme":"README.md","repository":"https://github.com/rust-cli/human-panic","homepage":"https://github.com/rust-cli/human-panic","documentation":null,"edition":"2018","links":null,"default_run":null,"rust_version":"1.60.0"}],"workspace_members":["human-panic 1.1.0 (path+file:///home/deca/Workspace/depfoo/rust-human-panic/human-panic-1.1.0)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-human-panic/human-panic-1.1.0/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-human-panic/human-panic-1.1.0","metadata":null} diff --git a/cargo2rpm/testdata/libc-0.2.139.json b/cargo2rpm/testdata/libc-0.2.139.json new file mode 100644 index 0000000..beab838 --- /dev/null +++ b/cargo2rpm/testdata/libc-0.2.139.json @@ -0,0 +1 @@ +{"packages":[{"name":"libc","version":"0.2.139","id":"libc 0.2.139 (path+file:///home/deca/Workspace/rust-libc/libc-0.2.139)","license":"MIT OR Apache-2.0","license_file":null,"description":"Raw FFI bindings to platform libraries like libc.\n","source":null,"dependencies":[{"name":"rustc-std-workspace-core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"libc","src_path":"/home/deca/Workspace/rust-libc/libc-0.2.139/src/lib.rs","edition":"2015","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"const_fn","src_path":"/home/deca/Workspace/rust-libc/libc-0.2.139/tests/const_fn.rs","edition":"2015","doc":false,"doctest":false,"test":true},{"kind":["custom-build"],"crate_types":["bin"],"name":"build-script-build","src_path":"/home/deca/Workspace/rust-libc/libc-0.2.139/build.rs","edition":"2015","doc":false,"doctest":false,"test":false}],"features":{"align":[],"const-extern-fn":[],"default":["std"],"extra_traits":[],"rustc-dep-of-std":["align","rustc-std-workspace-core"],"rustc-std-workspace-core":["dep:rustc-std-workspace-core"],"std":[],"use_std":["std"]},"manifest_path":"/home/deca/Workspace/rust-libc/libc-0.2.139/Cargo.toml","metadata":{"docs":{"rs":{"features":["const-extern-fn","extra_traits"]}}},"publish":null,"authors":["The Rust Project Developers"],"categories":["external-ffi-bindings","no-std","os"],"keywords":["libc","ffi","bindings","operating","system"],"readme":"README.md","repository":"https://github.com/rust-lang/libc","homepage":"https://github.com/rust-lang/libc","documentation":"https://docs.rs/libc/","edition":"2015","links":null,"default_run":null,"rust_version":null}],"workspace_members":["libc 0.2.139 (path+file:///home/deca/Workspace/rust-libc/libc-0.2.139)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-libc/libc-0.2.139/target","version":1,"workspace_root":"/home/deca/Workspace/rust-libc/libc-0.2.139","metadata":null} diff --git a/cargo2rpm/testdata/predicates-2.1.5.json b/cargo2rpm/testdata/predicates-2.1.5.json new file mode 100644 index 0000000..09b6efd --- /dev/null +++ b/cargo2rpm/testdata/predicates-2.1.5.json @@ -0,0 +1 @@ +{"packages":[{"name":"predicates","version":"2.1.5","id":"predicates 2.1.5 (path+file:///home/deca/Workspace/depfoo/rust-predicates/predicates-2.1.5)","license":"MIT OR Apache-2.0","license_file":null,"description":"An implementation of boolean-valued predicate functions.","source":null,"dependencies":[{"name":"concolor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.0.11","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"difflib","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"float-cmp","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"itertools","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.10","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"normalize-line-endings","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"predicates-core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"regex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"yansi","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"predicates-tree","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"predicates","src_path":"/home/deca/Workspace/depfoo/rust-predicates/predicates-2.1.5/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"case_tree","src_path":"/home/deca/Workspace/depfoo/rust-predicates/predicates-2.1.5/examples/case_tree.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{"color":["dep:yansi","dep:concolor","concolor?/std"],"color-auto":["color","concolor?/auto"],"default":["diff","regex","float-cmp","normalize-line-endings"],"diff":["dep:difflib"],"float-cmp":["dep:float-cmp"],"normalize-line-endings":["dep:normalize-line-endings"],"regex":["dep:regex"],"unstable":[]},"manifest_path":"/home/deca/Workspace/depfoo/rust-predicates/predicates-2.1.5/Cargo.toml","metadata":{"release":{"pre-release-replacements":[{"file":"src/lib.rs","search":"predicates = \".*\"","replace":"predicates = \"{{version}}\"","exactly":1},{"file":"README.md","search":"predicates = \".*\"","replace":"predicates = \"{{version}}\"","exactly":1},{"file":"CHANGELOG.md","search":"Unreleased","replace":"{{version}}","min":1},{"file":"CHANGELOG.md","search":"\\.\\.\\.HEAD","replace":"...{{tag_name}}","exactly":1},{"file":"CHANGELOG.md","search":"ReleaseDate","replace":"{{date}}","min":1},{"file":"CHANGELOG.md","search":"","replace":"\n## [Unreleased] - ReleaseDate\n","exactly":1},{"file":"CHANGELOG.md","search":"","replace":"\n[Unreleased]: https://github.com/assert-rs/predicates-rs/compare/{{tag_name}}...HEAD","exactly":1}]}},"publish":null,"authors":["Nick Stevens "],"categories":["data-structures","rust-patterns"],"keywords":["predicate","boolean","combinatorial","match","logic"],"readme":"README.md","repository":"https://github.com/assert-rs/predicates-rs","homepage":"https://github.com/assert-rs/predicates-rs","documentation":"https://docs.rs/predicates","edition":"2021","links":null,"default_run":null,"rust_version":"1.60.0"}],"workspace_members":["predicates 2.1.5 (path+file:///home/deca/Workspace/depfoo/rust-predicates/predicates-2.1.5)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-predicates/predicates-2.1.5/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-predicates/predicates-2.1.5","metadata":null} diff --git a/cargo2rpm/testdata/prettyjson b/cargo2rpm/testdata/prettyjson new file mode 100755 index 0000000..47d79be --- /dev/null +++ b/cargo2rpm/testdata/prettyjson @@ -0,0 +1,20 @@ +#!/usr/bin/python3 + +# Simple Python script for pretty-printing JSON files produced by +# "cargo metadata" for better human-readability. + +import json +import sys + +if len(sys.argv) != 3: + print("Missing arguments. Usage:", file=sys.stderr) + print(f" {sys.argv[0]} INPUT OUTPUT") + exit(1) + +with open(sys.argv[1]) as file: + data = json.load(file) + +with open(sys.argv[2], "w") as file: + json.dump(data, file, indent=2) + +exit(0) diff --git a/cargo2rpm/testdata/proc-macro2-1.0.50.json b/cargo2rpm/testdata/proc-macro2-1.0.50.json new file mode 100644 index 0000000..45921f4 --- /dev/null +++ b/cargo2rpm/testdata/proc-macro2-1.0.50.json @@ -0,0 +1 @@ +{"packages":[{"name":"proc-macro2","version":"1.0.50","id":"proc-macro2 1.0.50 (path+file:///home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50)","license":"MIT OR Apache-2.0","license_file":null,"description":"A substitute implementation of the compiler's `proc_macro` API to decouple token-based libraries from the procedural macro use case.","source":null,"dependencies":[{"name":"unicode-ident","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"quote","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"proc-macro2","src_path":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"comments","src_path":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/tests/comments.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"features","src_path":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/tests/features.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"marker","src_path":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/tests/marker.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test","src_path":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/tests/test.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_fmt","src_path":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/tests/test_fmt.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["custom-build"],"crate_types":["bin"],"name":"build-script-build","src_path":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/build.rs","edition":"2018","doc":false,"doctest":false,"test":false}],"features":{"default":["proc-macro"],"nightly":[],"proc-macro":[],"span-locations":[]},"manifest_path":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/Cargo.toml","metadata":{"docs":{"rs":{"rustc-args":["--cfg","procmacro2_semver_exempt"],"rustdoc-args":["--cfg","procmacro2_semver_exempt","--cfg","doc_cfg"],"targets":["x86_64-unknown-linux-gnu"]}},"playground":{"features":["span-locations"]}},"publish":null,"authors":["David Tolnay ","Alex Crichton "],"categories":["development-tools::procedural-macro-helpers"],"keywords":["macros","syn"],"readme":"README.md","repository":"https://github.com/dtolnay/proc-macro2","homepage":null,"documentation":"https://docs.rs/proc-macro2","edition":"2018","links":null,"default_run":null,"rust_version":"1.31"}],"workspace_members":["proc-macro2 1.0.50 (path+file:///home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50/target","version":1,"workspace_root":"/home/deca/Workspace/rust-proc-macro2/proc-macro2-1.0.50","metadata":null} diff --git a/cargo2rpm/testdata/quote-1.0.23.json b/cargo2rpm/testdata/quote-1.0.23.json new file mode 100644 index 0000000..c91820a --- /dev/null +++ b/cargo2rpm/testdata/quote-1.0.23.json @@ -0,0 +1 @@ +{"packages":[{"name":"quote","version":"1.0.23","id":"quote 1.0.23 (path+file:///home/deca/Workspace/rust-quote/quote-1.0.23)","license":"MIT OR Apache-2.0","license_file":null,"description":"Quasi-quoting macro quote!(...)","source":null,"dependencies":[{"name":"proc-macro2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.40","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"rustversion","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"trybuild","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.66","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":["diff"],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"quote","src_path":"/home/deca/Workspace/rust-quote/quote-1.0.23/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"compiletest","src_path":"/home/deca/Workspace/rust-quote/quote-1.0.23/tests/compiletest.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test","src_path":"/home/deca/Workspace/rust-quote/quote-1.0.23/tests/test.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["custom-build"],"crate_types":["bin"],"name":"build-script-build","src_path":"/home/deca/Workspace/rust-quote/quote-1.0.23/build.rs","edition":"2018","doc":false,"doctest":false,"test":false}],"features":{"default":["proc-macro"],"proc-macro":["proc-macro2/proc-macro"]},"manifest_path":"/home/deca/Workspace/rust-quote/quote-1.0.23/Cargo.toml","metadata":{"docs":{"rs":{"targets":["x86_64-unknown-linux-gnu"]}}},"publish":null,"authors":["David Tolnay "],"categories":["development-tools::procedural-macro-helpers"],"keywords":["macros","syn"],"readme":"README.md","repository":"https://github.com/dtolnay/quote","homepage":null,"documentation":"https://docs.rs/quote/","edition":"2018","links":null,"default_run":null,"rust_version":"1.31"}],"workspace_members":["quote 1.0.23 (path+file:///home/deca/Workspace/rust-quote/quote-1.0.23)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-quote/quote-1.0.23/target","version":1,"workspace_root":"/home/deca/Workspace/rust-quote/quote-1.0.23","metadata":null} diff --git a/cargo2rpm/testdata/rand-0.8.5.json b/cargo2rpm/testdata/rand-0.8.5.json new file mode 100644 index 0000000..0033a89 --- /dev/null +++ b/cargo2rpm/testdata/rand-0.8.5.json @@ -0,0 +1 @@ +{"packages":[{"name":"rand","version":"0.8.5","id":"rand 0.8.5 (path+file:///home/deca/Workspace/rust-rand/rand-0.8.5)","license":"MIT OR Apache-2.0","license_file":null,"description":"Random number generators and other randomness functionality.\n","source":null,"dependencies":[{"name":"log","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.4","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"packed_simd_2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.7","kind":null,"rename":"packed_simd","optional":true,"uses_default_features":true,"features":["into_bits"],"target":null,"registry":null},{"name":"rand_chacha","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.0","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"rand_core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.6.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.103","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"bincode","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.2.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"rand_pcg","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"libc","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.22","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":"cfg(unix)","registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"rand","src_path":"/home/deca/Workspace/rust-rand/rand-0.8.5/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true}],"features":{"alloc":["rand_core/alloc"],"default":["std","std_rng"],"getrandom":["rand_core/getrandom"],"libc":["dep:libc"],"log":["dep:log"],"min_const_gen":[],"nightly":[],"packed_simd":["dep:packed_simd"],"rand_chacha":["dep:rand_chacha"],"serde":["dep:serde"],"serde1":["serde","rand_core/serde1"],"simd_support":["packed_simd"],"small_rng":[],"std":["rand_core/std","rand_chacha/std","alloc","getrandom","libc"],"std_rng":["rand_chacha"]},"manifest_path":"/home/deca/Workspace/rust-rand/rand-0.8.5/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true,"rustdoc-args":["--cfg","doc_cfg"]}},"playground":{"features":["small_rng","serde1"]}},"publish":null,"authors":["The Rand Project Developers","The Rust Project Developers"],"categories":["algorithms","no-std"],"keywords":["random","rng"],"readme":"README.md","repository":"https://github.com/rust-random/rand","homepage":"https://rust-random.github.io/book","documentation":"https://docs.rs/rand","edition":"2018","links":null,"default_run":null,"rust_version":null}],"workspace_members":["rand 0.8.5 (path+file:///home/deca/Workspace/rust-rand/rand-0.8.5)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-rand/rand-0.8.5/target","version":1,"workspace_root":"/home/deca/Workspace/rust-rand/rand-0.8.5","metadata":null} diff --git a/cargo2rpm/testdata/rand_core-0.6.4.json b/cargo2rpm/testdata/rand_core-0.6.4.json new file mode 100644 index 0000000..5db5d7b --- /dev/null +++ b/cargo2rpm/testdata/rand_core-0.6.4.json @@ -0,0 +1 @@ +{"packages":[{"name":"rand_core","version":"0.6.4","id":"rand_core 0.6.4 (path+file:///home/deca/Workspace/rust-rand_core/rand_core-0.6.4)","license":"MIT OR Apache-2.0","license_file":null,"description":"Core random number generator traits and tools for implementation.\n","source":null,"dependencies":[{"name":"getrandom","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":["derive"],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"rand_core","src_path":"/home/deca/Workspace/rust-rand_core/rand_core-0.6.4/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true}],"features":{"alloc":[],"getrandom":["dep:getrandom"],"serde":["dep:serde"],"serde1":["serde"],"std":["alloc","getrandom","getrandom/std"]},"manifest_path":"/home/deca/Workspace/rust-rand_core/rand_core-0.6.4/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true,"rustdoc-args":["--cfg","doc_cfg"]}},"playground":{"all-features":true}},"publish":null,"authors":["The Rand Project Developers","The Rust Project Developers"],"categories":["algorithms","no-std"],"keywords":["random","rng"],"readme":"README.md","repository":"https://github.com/rust-random/rand","homepage":"https://rust-random.github.io/book","documentation":"https://docs.rs/rand_core","edition":"2018","links":null,"default_run":null,"rust_version":null}],"workspace_members":["rand_core 0.6.4 (path+file:///home/deca/Workspace/rust-rand_core/rand_core-0.6.4)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-rand_core/rand_core-0.6.4/target","version":1,"workspace_root":"/home/deca/Workspace/rust-rand_core/rand_core-0.6.4","metadata":null} diff --git a/cargo2rpm/testdata/rust_decimal-1.28.0.json b/cargo2rpm/testdata/rust_decimal-1.28.0.json new file mode 100644 index 0000000..4780331 --- /dev/null +++ b/cargo2rpm/testdata/rust_decimal-1.28.0.json @@ -0,0 +1 @@ +{"packages":[{"name":"rust_decimal","version":"1.28.0","id":"rust_decimal 1.28.0 (path+file:///home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0)","license":"MIT","license_file":null,"description":"Decimal number implementation written in pure Rust suitable for financial and fixed-precision calculations.","source":null,"dependencies":[{"name":"arbitrary","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"arrayvec","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.7","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"borsh","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"bytecheck","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.6","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"byteorder","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"bytes","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"diesel","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":"diesel1","optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"diesel","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.0","kind":null,"rename":"diesel2","optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"num-traits","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["i128"],"target":null,"registry":null},{"name":"postgres","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.19","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"rand","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"rkyv","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.7","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":["size_32","std"],"target":null,"registry":null},{"name":"rocket","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.0-rc.1","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"serde_json","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"tokio-postgres","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.7","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"bincode","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"bytes","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"criterion","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"csv","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"rand","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["getrandom"],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["derive"],"target":null,"registry":null},{"name":"serde_json","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tokio","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["macros","rt-multi-thread","test-util"],"target":null,"registry":null},{"name":"version-sync","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["html_root_url_updated","markdown_deps_updated"],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"rust_decimal","src_path":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"decimal_tests","src_path":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/tests/decimal_tests.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"macros","src_path":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/tests/macros.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"version-numbers","src_path":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/tests/version-numbers.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["bench"],"crate_types":["bin"],"name":"comparison","src_path":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/benches/comparison.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["bench"],"crate_types":["bin"],"name":"lib_benches","src_path":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/benches/lib_benches.rs","edition":"2021","doc":false,"doctest":false,"test":false},{"kind":["custom-build"],"crate_types":["bin"],"name":"build-script-build","src_path":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/build.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{"arbitrary":["dep:arbitrary"],"borsh":["dep:borsh"],"bytecheck":["dep:bytecheck"],"byteorder":["dep:byteorder"],"bytes":["dep:bytes"],"c-repr":[],"db-diesel-mysql":["db-diesel1-mysql"],"db-diesel-postgres":["db-diesel1-postgres"],"db-diesel1-mysql":["diesel1/mysql","std"],"db-diesel1-postgres":["diesel1/postgres","std"],"db-diesel2-mysql":["diesel2/mysql","std"],"db-diesel2-postgres":["diesel2/postgres","std"],"db-postgres":["byteorder","bytes","postgres","std"],"db-tokio-postgres":["byteorder","bytes","postgres","std","tokio-postgres"],"default":["serde","std"],"diesel1":["dep:diesel1"],"diesel2":["dep:diesel2"],"legacy-ops":[],"maths":[],"maths-nopanic":["maths"],"postgres":["dep:postgres"],"rand":["dep:rand"],"rkyv":["dep:rkyv"],"rkyv-safe":["bytecheck","rkyv/validation"],"rocket":["dep:rocket"],"rocket-traits":["rocket"],"rust-fuzz":["arbitrary"],"serde":["dep:serde"],"serde-arbitrary-precision":["serde-with-arbitrary-precision"],"serde-bincode":["serde-str"],"serde-float":["serde-with-float"],"serde-str":["serde-with-str"],"serde-with-arbitrary-precision":["serde","serde_json/arbitrary_precision","serde_json/std"],"serde-with-float":["serde"],"serde-with-str":["serde"],"serde_json":["dep:serde_json"],"std":["arrayvec/std","borsh?/std","bytecheck?/std","byteorder?/std","bytes?/std","rand?/std","rkyv?/std","serde?/std","serde_json?/std"],"tokio-pg":["db-tokio-postgres"],"tokio-postgres":["dep:tokio-postgres"]},"manifest_path":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true}}},"publish":null,"authors":["Paul Mason "],"categories":["science","mathematics","data-structures"],"keywords":["decimal","financial","fixed","precision","number"],"readme":"./README.md","repository":"https://github.com/paupino/rust-decimal","homepage":null,"documentation":"https://docs.rs/rust_decimal/","edition":"2021","links":null,"default_run":null,"rust_version":"1.60"}],"workspace_members":["rust_decimal 1.28.0 (path+file:///home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-rust_decimal/rust_decimal-1.28.0","metadata":null} diff --git a/cargo2rpm/testdata/serde-1.0.152.json b/cargo2rpm/testdata/serde-1.0.152.json new file mode 100644 index 0000000..9b8d7b6 --- /dev/null +++ b/cargo2rpm/testdata/serde-1.0.152.json @@ -0,0 +1 @@ +{"packages":[{"name":"serde","version":"1.0.152","id":"serde 1.0.152 (path+file:///home/deca/Workspace/rust-serde/serde-1.0.152)","license":"MIT OR Apache-2.0","license_file":null,"description":"A generic serialization/deserialization framework","source":null,"dependencies":[{"name":"serde_derive","source":"registry+https://github.com/rust-lang/crates.io-index","req":"=1.0.152","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde_derive","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"serde","src_path":"/home/deca/Workspace/rust-serde/serde-1.0.152/src/lib.rs","edition":"2015","doc":true,"doctest":true,"test":true},{"kind":["custom-build"],"crate_types":["bin"],"name":"build-script-build","src_path":"/home/deca/Workspace/rust-serde/serde-1.0.152/build.rs","edition":"2015","doc":false,"doctest":false,"test":false}],"features":{"alloc":[],"default":["std"],"derive":["serde_derive"],"rc":[],"serde_derive":["dep:serde_derive"],"std":[],"unstable":[]},"manifest_path":"/home/deca/Workspace/rust-serde/serde-1.0.152/Cargo.toml","metadata":{"playground":{"features":["derive","rc"]},"docs":{"rs":{"targets":["x86_64-unknown-linux-gnu"]}}},"publish":null,"authors":["Erick Tryzelaar ","David Tolnay "],"categories":["encoding","no-std"],"keywords":["serde","serialization","no_std"],"readme":"crates-io.md","repository":"https://github.com/serde-rs/serde","homepage":"https://serde.rs","documentation":"https://docs.rs/serde","edition":"2015","links":null,"default_run":null,"rust_version":"1.13"}],"workspace_members":["serde 1.0.152 (path+file:///home/deca/Workspace/rust-serde/serde-1.0.152)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-serde/serde-1.0.152/target","version":1,"workspace_root":"/home/deca/Workspace/rust-serde/serde-1.0.152","metadata":null} diff --git a/cargo2rpm/testdata/syn-1.0.107.json b/cargo2rpm/testdata/syn-1.0.107.json new file mode 100644 index 0000000..93a1547 --- /dev/null +++ b/cargo2rpm/testdata/syn-1.0.107.json @@ -0,0 +1 @@ +{"packages":[{"name":"syn","version":"1.0.107","id":"syn 1.0.107 (path+file:///home/deca/Workspace/rust-syn/syn-1.0.107)","license":"MIT OR Apache-2.0","license_file":null,"description":"Parser for Rust source code","source":null,"dependencies":[{"name":"proc-macro2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.46","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"quote","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"unicode-ident","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"anyhow","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"automod","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"flate2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"insta","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"rayon","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"ref-cast","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"regex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"reqwest","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.11","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":["blocking"],"target":null,"registry":null},{"name":"syn-test-suite","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tar","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.16","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"termcolor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"walkdir","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"syn","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"regression","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/regression.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_asyncness","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_asyncness.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_attribute","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_attribute.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_derive_input","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_derive_input.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_expr","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_expr.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_generics","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_generics.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_grouping","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_grouping.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_ident","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_ident.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_item","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_item.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_iterators","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_iterators.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_lit","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_lit.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_meta","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_meta.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_parse_buffer","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_parse_buffer.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_parse_stream","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_parse_stream.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_pat","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_pat.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_path","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_path.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_precedence","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_precedence.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_receiver","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_receiver.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_round_trip","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_round_trip.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_shebang","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_shebang.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_should_parse","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_should_parse.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_size","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_size.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_stmt","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_stmt.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_token_trees","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_token_trees.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_ty","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_ty.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_visibility","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/test_visibility.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"zzz_stable","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/tests/zzz_stable.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["bench"],"crate_types":["bin"],"name":"rust","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/benches/rust.rs","edition":"2018","required-features":["full","parsing"],"doc":false,"doctest":false,"test":false},{"kind":["bench"],"crate_types":["bin"],"name":"file","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/benches/file.rs","edition":"2018","required-features":["full","parsing"],"doc":false,"doctest":false,"test":false},{"kind":["custom-build"],"crate_types":["bin"],"name":"build-script-build","src_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/build.rs","edition":"2018","doc":false,"doctest":false,"test":false}],"features":{"clone-impls":[],"default":["derive","parsing","printing","clone-impls","proc-macro"],"derive":[],"extra-traits":[],"fold":[],"full":[],"parsing":[],"printing":["quote"],"proc-macro":["proc-macro2/proc-macro","quote/proc-macro"],"quote":["dep:quote"],"test":["syn-test-suite/all-features"],"visit":[],"visit-mut":[]},"manifest_path":"/home/deca/Workspace/rust-syn/syn-1.0.107/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true,"targets":["x86_64-unknown-linux-gnu"],"rustdoc-args":["--cfg","doc_cfg"]}},"playground":{"features":["full","visit","visit-mut","fold","extra-traits"]}},"publish":null,"authors":["David Tolnay "],"categories":["development-tools::procedural-macro-helpers","parser-implementations"],"keywords":["macros","syn"],"readme":"README.md","repository":"https://github.com/dtolnay/syn","homepage":null,"documentation":"https://docs.rs/syn","edition":"2018","links":null,"default_run":null,"rust_version":"1.31"}],"workspace_members":["syn 1.0.107 (path+file:///home/deca/Workspace/rust-syn/syn-1.0.107)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-syn/syn-1.0.107/target","version":1,"workspace_root":"/home/deca/Workspace/rust-syn/syn-1.0.107","metadata":null} diff --git a/cargo2rpm/testdata/time-0.3.17.json b/cargo2rpm/testdata/time-0.3.17.json new file mode 100644 index 0000000..2fe6969 --- /dev/null +++ b/cargo2rpm/testdata/time-0.3.17.json @@ -0,0 +1 @@ +{"packages":[{"name":"time","version":"0.3.17","id":"time 0.3.17 (path+file:///home/deca/Workspace/depfoo/rust-time/time-0.3.17)","license":"MIT OR Apache-2.0","license_file":null,"description":"Date and time library. Fully interoperable with the standard library. Mostly compatible with #![no_std].","source":null,"dependencies":[{"name":"itoa","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"quickcheck","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.3","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"rand","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8.4","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.126","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"time-core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"=0.1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"time-macros","source":"registry+https://github.com/rust-lang/crates.io-index","req":"=0.2.6","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"quickcheck_macros","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"rand","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8.4","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.126","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["derive"],"target":null,"registry":null},{"name":"serde_json","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.68","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde_test","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.126","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"time-macros","source":"registry+https://github.com/rust-lang/crates.io-index","req":"=0.2.6","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"trybuild","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.68","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(__ui_tests)","registry":null},{"name":"js-sys","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.58","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":"cfg(all(target_arch = \"wasm32\", not(any(target_os = \"emscripten\", target_os = \"wasi\"))))","registry":null},{"name":"criterion","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.0","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":[],"target":"cfg(bench)","registry":null},{"name":"libc","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.98","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":"cfg(target_family = \"unix\")","registry":null},{"name":"num_threads","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.2","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":"cfg(target_family = \"unix\")","registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"time","src_path":"/home/deca/Workspace/depfoo/rust-time/time-0.3.17/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tests","src_path":"/home/deca/Workspace/depfoo/rust-time/time-0.3.17/../tests/main.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["bench"],"crate_types":["bin"],"name":"benchmarks","src_path":"/home/deca/Workspace/depfoo/rust-time/time-0.3.17/../benchmarks/main.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{"alloc":["serde?/alloc"],"default":["std"],"formatting":["dep:itoa","std","time-macros?/formatting"],"large-dates":["time-macros?/large-dates"],"local-offset":["std","dep:libc","dep:num_threads"],"macros":["dep:time-macros"],"parsing":["time-macros?/parsing"],"quickcheck":["dep:quickcheck","alloc"],"rand":["dep:rand"],"serde":["dep:serde","time-macros?/serde"],"serde-human-readable":["serde","formatting","parsing"],"serde-well-known":["serde","formatting","parsing"],"std":["alloc"],"wasm-bindgen":["dep:js-sys"]},"manifest_path":"/home/deca/Workspace/depfoo/rust-time/time-0.3.17/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true,"targets":["x86_64-unknown-linux-gnu"],"rustdoc-args":["--cfg","__time_03_docs"]}}},"publish":null,"authors":["Jacob Pratt ","Time contributors"],"categories":["date-and-time","no-std","parser-implementations","value-formatting"],"keywords":["date","time","calendar","duration"],"readme":"README.md","repository":"https://github.com/time-rs/time","homepage":"https://time-rs.github.io","documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":"1.60.0"}],"workspace_members":["time 0.3.17 (path+file:///home/deca/Workspace/depfoo/rust-time/time-0.3.17)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-time/time-0.3.17/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-time/time-0.3.17","metadata":null} diff --git a/cargo2rpm/testdata/unicode-xid-0.2.4.json b/cargo2rpm/testdata/unicode-xid-0.2.4.json new file mode 100644 index 0000000..1166b6d --- /dev/null +++ b/cargo2rpm/testdata/unicode-xid-0.2.4.json @@ -0,0 +1 @@ +{"packages":[{"name":"unicode-xid","version":"0.2.4","id":"unicode-xid 0.2.4 (path+file:///home/deca/Workspace/rust-unicode-xid/unicode-xid-0.2.4)","license":"MIT OR Apache-2.0","license_file":null,"description":"Determine whether characters have the XID_Start\nor XID_Continue properties according to\nUnicode Standard Annex #31.\n","source":null,"dependencies":[{"name":"criterion","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"unicode-xid","src_path":"/home/deca/Workspace/rust-unicode-xid/unicode-xid-0.2.4/src/lib.rs","edition":"2015","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"exhaustive_tests","src_path":"/home/deca/Workspace/rust-unicode-xid/unicode-xid-0.2.4/tests/exhaustive_tests.rs","edition":"2015","doc":false,"doctest":false,"test":true},{"kind":["bench"],"crate_types":["bin"],"name":"xid","src_path":"/home/deca/Workspace/rust-unicode-xid/unicode-xid-0.2.4/benches/xid.rs","edition":"2015","doc":false,"doctest":false,"test":false}],"features":{"bench":[],"default":[],"no_std":[]},"manifest_path":"/home/deca/Workspace/rust-unicode-xid/unicode-xid-0.2.4/Cargo.toml","metadata":null,"publish":null,"authors":["erick.tryzelaar ","kwantam ","Manish Goregaokar "],"categories":[],"keywords":["text","unicode","xid"],"readme":"README.md","repository":"https://github.com/unicode-rs/unicode-xid","homepage":"https://github.com/unicode-rs/unicode-xid","documentation":"https://unicode-rs.github.io/unicode-xid","edition":"2015","links":null,"default_run":null,"rust_version":"1.17"}],"workspace_members":["unicode-xid 0.2.4 (path+file:///home/deca/Workspace/rust-unicode-xid/unicode-xid-0.2.4)"],"resolve":null,"target_directory":"/home/deca/Workspace/rust-unicode-xid/unicode-xid-0.2.4/target","version":1,"workspace_root":"/home/deca/Workspace/rust-unicode-xid/unicode-xid-0.2.4","metadata":null} diff --git a/cargo2rpm/testdata/zbus-3.8.0.json b/cargo2rpm/testdata/zbus-3.8.0.json new file mode 100644 index 0000000..d60e9af --- /dev/null +++ b/cargo2rpm/testdata/zbus-3.8.0.json @@ -0,0 +1 @@ +{"packages":[{"name":"zbus","version":"3.8.0","id":"zbus 3.8.0 (path+file:///home/deca/Workspace/depfoo/rust-zbus/zbus-3.8.0)","license":"MIT","license_file":null,"description":"API for D-Bus communication","source":null,"dependencies":[{"name":"async-broadcast","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"async-executor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.5.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"async-io","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.12.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"async-lock","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.6.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"async-recursion","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"async-task","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^4.3.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"async-trait","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.58","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"byteorder","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.4.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"derivative","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"dirs","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^4.0.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"enumflags2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.7.5","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["serde"],"target":null,"registry":null},{"name":"event-listener","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.5.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures-core","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.25","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures-sink","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.25","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures-util","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.25","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["sink","std"],"target":null,"registry":null},{"name":"hex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"lazy_static","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.4.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"nix","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.25.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"once_cell","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.4.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"ordered-stream","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.4","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"quick-xml","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.27.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":["serialize","overlapped-lists"],"target":null,"registry":null},{"name":"rand","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8.5","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"serde-xml-rs","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde_repr","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.9","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"sha1","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.10.5","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["std"],"target":null,"registry":null},{"name":"static_assertions","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tokio","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.21.2","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":["rt","net","time","fs","io-util","sync","tracing"],"target":null,"registry":null},{"name":"tokio-vsock","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.3","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tracing","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.37","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"vsock","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"zbus_macros","source":"registry+https://github.com/rust-lang/crates.io-index","req":"=3.8.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"zbus_names","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.5","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"zvariant","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3.10.0","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["enumflags2"],"target":null,"registry":null},{"name":"async-std","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.12.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":["attributes"],"target":null,"registry":null},{"name":"doc-comment","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures-util","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.25","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"ntest","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3.3.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"test-log","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.11","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["trace"],"target":null,"registry":null},{"name":"tokio","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":["macros","rt-multi-thread","fs","io-util","net","sync"],"target":null,"registry":null},{"name":"tracing-subscriber","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.16","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["env-filter","fmt"],"target":null,"registry":null},{"name":"uds_windows","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(windows)","registry":null},{"name":"winapi","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["handleapi","iphlpapi","memoryapi","processthreadsapi","sddl","securitybaseapi","synchapi","tcpmib","winbase","winerror","winsock2"],"target":"cfg(windows)","registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"zbus","src_path":"/home/deca/Workspace/depfoo/rust-zbus/zbus-3.8.0/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"screen-brightness","src_path":"/home/deca/Workspace/depfoo/rust-zbus/zbus-3.8.0/examples/screen-brightness.rs","edition":"2018","doc":false,"doctest":false,"test":false},{"kind":["test"],"crate_types":["bin"],"name":"e2e","src_path":"/home/deca/Workspace/depfoo/rust-zbus/zbus-3.8.0/tests/e2e.rs","edition":"2018","doc":false,"doctest":false,"test":true}],"features":{"async-executor":["dep:async-executor"],"async-io":["dep:async-io","async-executor","async-task","async-lock"],"async-lock":["dep:async-lock"],"async-task":["dep:async-task"],"chrono":["zvariant/chrono"],"default":["async-io"],"gvariant":["zvariant/gvariant"],"lazy_static":["dep:lazy_static"],"quick-xml":["dep:quick-xml"],"serde-xml-rs":["dep:serde-xml-rs"],"time":["zvariant/time"],"tokio":["dep:tokio","lazy_static"],"tokio-vsock":["dep:tokio-vsock","tokio"],"url":["zvariant/url"],"uuid":["zvariant/uuid"],"vsock":["dep:vsock","dep:async-io"],"windows-gdbus":[],"xml":["serde-xml-rs"]},"manifest_path":"/home/deca/Workspace/depfoo/rust-zbus/zbus-3.8.0/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true,"targets":["x86_64-unknown-linux-gnu"]}}},"publish":null,"authors":["Zeeshan Ali Khan "],"categories":["os::unix-apis"],"keywords":["D-Bus","DBus","IPC"],"readme":"README.md","repository":"https://gitlab.freedesktop.org/dbus/zbus/","homepage":null,"documentation":null,"edition":"2018","links":null,"default_run":null,"rust_version":"1.60"}],"workspace_members":["zbus 3.8.0 (path+file:///home/deca/Workspace/depfoo/rust-zbus/zbus-3.8.0)"],"resolve":null,"target_directory":"/home/deca/Workspace/depfoo/rust-zbus/zbus-3.8.0/target","version":1,"workspace_root":"/home/deca/Workspace/depfoo/rust-zbus/zbus-3.8.0","metadata":null} diff --git a/cargo2rpm/testdata/zola-0.16.1.json b/cargo2rpm/testdata/zola-0.16.1.json new file mode 100644 index 0000000..12c2157 --- /dev/null +++ b/cargo2rpm/testdata/zola-0.16.1.json @@ -0,0 +1 @@ +{"packages":[{"name":"config","version":"0.1.0","id":"config 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/config)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"utils","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/utils"}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"config","src_path":"/home/deca/Downloads/zola-0.16.1/components/config/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["example"],"crate_types":["bin"],"name":"generate_sublime","src_path":"/home/deca/Downloads/zola-0.16.1/components/config/examples/generate_sublime.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/config/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"errors","version":"0.1.0","id":"errors 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/errors)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"anyhow","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.56","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"errors","src_path":"/home/deca/Downloads/zola-0.16.1/components/errors/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/errors/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"libs","version":"0.1.0","id":"libs 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/libs)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"ahash","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"ammonia","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"atty","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.11","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"base64","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.13","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"csv","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"elasticlunr-rs","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3.0.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["da","no","de","du","es","fi","fr","it","pt","ro","ru","sv","tr"],"target":null,"registry":null},{"name":"filetime","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"gh-emoji","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"glob","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"globset","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"image","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.24","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"lexical-sort","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"minify-html","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"nom-bibtex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"num-format","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"once_cell","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"percent-encoding","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"pulldown-cmark","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["simd"],"target":null,"registry":null},{"name":"quickxml_to_serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"rayon","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"regex","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"relative-path","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"reqwest","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.11","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["blocking"],"target":null,"registry":null},{"name":"sass-rs","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde_json","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"serde_yaml","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"sha2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.10","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"slug","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"svg_metadata","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"syntect","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^5","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tera","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["preserve_order"],"target":null,"registry":null},{"name":"termcolor","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.4","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"time","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"toml","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"unic-langid","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"unicode-segmentation","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"url","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"walkdir","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"webp","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"libs","src_path":"/home/deca/Downloads/zola-0.16.1/components/libs/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true}],"features":{"default":["rust-tls"],"indexing-ja":["elasticlunr-rs/ja"],"indexing-zh":["elasticlunr-rs/zh"],"native-tls":["reqwest/default-tls"],"rust-tls":["reqwest/rustls-tls"]},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/libs/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"utils","version":"0.1.0","id":"utils 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/utils)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"utils","src_path":"/home/deca/Downloads/zola-0.16.1/components/utils/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/utils/Cargo.toml","metadata":null,"publish":null,"authors":["Vincent Prouillet "],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2018","links":null,"default_run":null,"rust_version":null},{"name":"console","version":"0.1.0","id":"console 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/console)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"console","src_path":"/home/deca/Downloads/zola-0.16.1/components/console/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/console/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"content","version":"0.1.0","id":"content 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/content)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"config","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/config"},{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"markdown","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/markdown"},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"time","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["macros"],"target":null,"registry":null},{"name":"utils","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/utils"},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3.3.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"test-case","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"content","src_path":"/home/deca/Downloads/zola-0.16.1/components/content/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/content/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"markdown","version":"0.1.0","id":"markdown 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/markdown)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"config","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/config"},{"name":"console","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/console"},{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"pest","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"pest_derive","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"utils","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/utils"},{"name":"insta","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.12.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"templates","source":null,"req":"*","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/templates"}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"markdown","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"codeblocks","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/tests/codeblocks.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"common","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/tests/common.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"links","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/tests/links.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"markdown","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/tests/markdown.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"shortcodes","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/tests/shortcodes.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"summary","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/tests/summary.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"toc","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/tests/toc.rs","edition":"2021","doc":false,"doctest":false,"test":true},{"kind":["bench"],"crate_types":["bin"],"name":"all","src_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/benches/all.rs","edition":"2021","doc":false,"doctest":false,"test":false}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/markdown/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"templates","version":"0.1.0","id":"templates 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/templates)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"config","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/config"},{"name":"content","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/content"},{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"imageproc","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/imageproc"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"markdown","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/markdown"},{"name":"utils","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/utils"},{"name":"mockito","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.31","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"templates","src_path":"/home/deca/Downloads/zola-0.16.1/components/templates/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/templates/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"imageproc","version":"0.1.0","id":"imageproc 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/imageproc)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"config","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/config"},{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"kamadak-exif","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.4","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"utils","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/utils"},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"imageproc","src_path":"/home/deca/Downloads/zola-0.16.1/components/imageproc/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"resize_image","src_path":"/home/deca/Downloads/zola-0.16.1/components/imageproc/tests/resize_image.rs","edition":"2021","doc":false,"doctest":false,"test":true}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/imageproc/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"link_checker","version":"0.1.0","id":"link_checker 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/link_checker)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"config","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/config"},{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"utils","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/utils"},{"name":"mockito","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.31","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"link_checker","src_path":"/home/deca/Downloads/zola-0.16.1/components/link_checker/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/link_checker/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"search","version":"0.1.0","id":"search 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/search)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"config","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/config"},{"name":"content","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/content"},{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"search","src_path":"/home/deca/Downloads/zola-0.16.1/components/search/src/lib.rs","edition":"2021","doc":true,"doctest":true,"test":true}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/search/Cargo.toml","metadata":null,"publish":null,"authors":[],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2021","links":null,"default_run":null,"rust_version":null},{"name":"site","version":"0.1.0","id":"site 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/site)","license":null,"license_file":null,"description":null,"source":null,"dependencies":[{"name":"config","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/config"},{"name":"console","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/console"},{"name":"content","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/content"},{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"imageproc","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/imageproc"},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"link_checker","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/link_checker"},{"name":"search","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/search"},{"name":"serde","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"templates","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/templates"},{"name":"utils","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/utils"},{"name":"path-slash","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"site","src_path":"/home/deca/Downloads/zola-0.16.1/components/site/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"common","src_path":"/home/deca/Downloads/zola-0.16.1/components/site/tests/common.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"site","src_path":"/home/deca/Downloads/zola-0.16.1/components/site/tests/site.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"site_i18n","src_path":"/home/deca/Downloads/zola-0.16.1/components/site/tests/site_i18n.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["bench"],"crate_types":["bin"],"name":"load","src_path":"/home/deca/Downloads/zola-0.16.1/components/site/benches/load.rs","edition":"2018","doc":false,"doctest":false,"test":false},{"kind":["bench"],"crate_types":["bin"],"name":"site","src_path":"/home/deca/Downloads/zola-0.16.1/components/site/benches/site.rs","edition":"2018","doc":false,"doctest":false,"test":false}],"features":{},"manifest_path":"/home/deca/Downloads/zola-0.16.1/components/site/Cargo.toml","metadata":null,"publish":null,"authors":["Vincent Prouillet "],"categories":[],"keywords":[],"readme":null,"repository":null,"homepage":null,"documentation":null,"edition":"2018","links":null,"default_run":null,"rust_version":null},{"name":"zola","version":"0.16.1","id":"zola 0.16.1 (path+file:///home/deca/Downloads/zola-0.16.1)","license":"MIT","license_file":null,"description":"A fast static site generator with everything built-in","source":null,"dependencies":[{"name":"clap","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["derive"],"target":null,"registry":null},{"name":"console","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/console"},{"name":"ctrlc","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"errors","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/errors"},{"name":"hyper","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.14.1","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["runtime","server","http2","http1"],"target":null,"registry":null},{"name":"libs","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/libs"},{"name":"mime","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.16","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"mime_guess","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"notify","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^4","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"open","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"pathdiff","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"site","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/site"},{"name":"time","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["formatting","macros","local-offset"],"target":null,"registry":null},{"name":"tokio","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.1","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["rt","fs","time"],"target":null,"registry":null},{"name":"utils","source":null,"req":"*","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null,"path":"/home/deca/Downloads/zola-0.16.1/components/utils"},{"name":"ws","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.9","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"same-file","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"clap","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":"build","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"clap_complete","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3","kind":"build","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"time","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":"build","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"winres","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1","kind":"build","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["bin"],"crate_types":["bin"],"name":"zola","src_path":"/home/deca/Downloads/zola-0.16.1/src/main.rs","edition":"2018","doc":true,"doctest":false,"test":true},{"kind":["custom-build"],"crate_types":["bin"],"name":"build-script-build","src_path":"/home/deca/Downloads/zola-0.16.1/build.rs","edition":"2018","doc":false,"doctest":false,"test":false}],"features":{"default":["rust-tls"],"indexing-ja":["libs/indexing-ja"],"indexing-zh":["libs/indexing-zh"],"native-tls":["libs/native-tls"],"rust-tls":["libs/rust-tls"]},"manifest_path":"/home/deca/Downloads/zola-0.16.1/Cargo.toml","metadata":{"winres":{"OriginalFilename":"zola.exe","InternalName":"zola"}},"publish":null,"authors":["Vincent Prouillet "],"categories":[],"keywords":["static","site","generator","blog"],"readme":"README.md","repository":"https://github.com/getzola/zola","homepage":"https://www.getzola.org","documentation":null,"edition":"2018","links":null,"default_run":null,"rust_version":null}],"workspace_members":["config 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/config)","errors 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/errors)","libs 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/libs)","utils 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/utils)","console 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/console)","content 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/content)","markdown 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/markdown)","templates 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/templates)","imageproc 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/imageproc)","link_checker 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/link_checker)","search 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/search)","site 0.1.0 (path+file:///home/deca/Downloads/zola-0.16.1/components/site)","zola 0.16.1 (path+file:///home/deca/Downloads/zola-0.16.1)"],"resolve":null,"target_directory":"/home/deca/Downloads/zola-0.16.1/target","version":1,"workspace_root":"/home/deca/Downloads/zola-0.16.1","metadata":null} diff --git a/tox.ini b/tox.ini index cb8b6d0..a0d98c0 100644 --- a/tox.ini +++ b/tox.ini @@ -8,7 +8,7 @@ deps = whitelist_externals = cargo commands = - pytest -v + pytest -v {posargs} setenv = PYTHONPATH = {toxinidir} @@ -19,7 +19,7 @@ deps = whitelist_externals = cargo commands = - coverage run --branch -m pytest -v + coverage run --branch -m pytest -v {posargs} coverage html coverage report setenv =