aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-10-26 06:22:19 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-10-26 06:22:19 +0000
commit343a0dc5aa3d28913b37045cee0201c0de3d660e (patch)
tree92e865725fa7662291c751e8ea29bac98a584d14
parentf91560d6d40e933031e4e4d678e374a08e3abcf8 (diff)
downloadpaludis-343a0dc5aa3d28913b37045cee0201c0de3d660e.tar.gz
paludis-343a0dc5aa3d28913b37045cee0201c0de3d660e.tar.xz
--info output for unpackaged repositories
-rw-r--r--paludis/repositories/unpackaged/installed_repository.cc10
-rw-r--r--paludis/repositories/unpackaged/unpackaged_repository.cc11
2 files changed, 20 insertions, 1 deletions
diff --git a/paludis/repositories/unpackaged/installed_repository.cc b/paludis/repositories/unpackaged/installed_repository.cc
index 0389b44..bca6a4d 100644
--- a/paludis/repositories/unpackaged/installed_repository.cc
+++ b/paludis/repositories/unpackaged/installed_repository.cc
@@ -30,6 +30,7 @@
#include <paludis/util/set.hh>
#include <paludis/util/dir_iterator.hh>
#include <paludis/util/system.hh>
+#include <paludis/repository_info.hh>
#include <paludis/action.hh>
#include <paludis/environment.hh>
#include <paludis/dep_tag.hh>
@@ -88,8 +89,15 @@ InstalledUnpackagedRepository::InstalledUnpackagedRepository(
.hook_interface(0)
.qa_interface(0)
.manifest_interface(0),
- "installed-unpackaged")
+ "installed_unpackaged")
{
+ tr1::shared_ptr<RepositoryInfoSection> config_info(new RepositoryInfoSection("Configuration information"));
+
+ config_info->add_kv("location", stringify(_imp->params.location));
+ config_info->add_kv("root", stringify(_imp->params.root));
+ config_info->add_kv("format", "installed_unpackage");
+
+ _info->add_section(config_info);
}
InstalledUnpackagedRepository::~InstalledUnpackagedRepository()
diff --git a/paludis/repositories/unpackaged/unpackaged_repository.cc b/paludis/repositories/unpackaged/unpackaged_repository.cc
index 78ba8e3..5db3a30 100644
--- a/paludis/repositories/unpackaged/unpackaged_repository.cc
+++ b/paludis/repositories/unpackaged/unpackaged_repository.cc
@@ -23,7 +23,9 @@
#include <paludis/util/set.hh>
#include <paludis/util/private_implementation_pattern-impl.hh>
#include <paludis/util/make_shared_ptr.hh>
+#include <paludis/util/stringify.hh>
#include <paludis/package_id.hh>
+#include <paludis/repository_info.hh>
#include <paludis/action.hh>
using namespace paludis;
@@ -79,6 +81,15 @@ UnpackagedRepository::UnpackagedRepository(const RepositoryName & n,
.manifest_interface(0),
"unpackaged")
{
+ tr1::shared_ptr<RepositoryInfoSection> config_info(new RepositoryInfoSection("Configuration information"));
+
+ config_info->add_kv("location", stringify(_imp->params.location));
+ config_info->add_kv("name", stringify(_imp->params.name));
+ config_info->add_kv("version", stringify(_imp->params.version));
+ config_info->add_kv("slot", stringify(_imp->params.slot));
+ config_info->add_kv("format", "unpackaged");
+
+ _info->add_section(config_info);
}
UnpackagedRepository::~UnpackagedRepository()