diff options
author | John Hodge <tpg@mutabah.net> | 2018-03-10 16:34:25 +0800 |
---|---|---|
committer | John Hodge <tpg@mutabah.net> | 2018-03-10 16:34:25 +0800 |
commit | daea1ea3f07fc57dd0f90f7d8c5de76584dd9c02 (patch) | |
tree | f413a99952030d90fd641ca366e4a81366a24686 /tools/minicargo/repository.cpp | |
parent | 0f8cca87de85e0387a3e6e6cbb4a75656e649ed5 (diff) | |
download | mrust-daea1ea3f07fc57dd0f90f7d8c5de76584dd9c02.tar.gz |
minicargo - Handle wildcard dependencies
Diffstat (limited to 'tools/minicargo/repository.cpp')
-rw-r--r-- | tools/minicargo/repository.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tools/minicargo/repository.cpp b/tools/minicargo/repository.cpp index c0b39b5a..ebe660f1 100644 --- a/tools/minicargo/repository.cpp +++ b/tools/minicargo/repository.cpp @@ -139,7 +139,14 @@ void Repository::load_vendored(const ::helpers::path& path) { throw "TODO: Download package"; } - best->loaded_manifest = ::std::shared_ptr<PackageManifest>( new PackageManifest(PackageManifest::load_from_toml(best->manifest_path)) ); + try + { + best->loaded_manifest = ::std::shared_ptr<PackageManifest>( new PackageManifest(PackageManifest::load_from_toml(best->manifest_path)) ); + } + catch(const ::std::exception& e) + { + throw ::std::runtime_error( format("Error loading manifest '", best->manifest_path, "' - ", e.what()) ); + } } return best->loaded_manifest; |