aboutsummaryrefslogtreecommitdiff
path: root/bpkg/package.cxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2021-09-23 20:51:45 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2021-09-24 11:27:09 +0300
commitfa002aac4c3cb75722d973d199a73231062b890c (patch)
treeb09d44844bae7528d63689dfaf7e46d4b668733c /bpkg/package.cxx
parent3f86fb3b73731f680bcffda83e4dddb6914eb13a (diff)
Make database ordering consistent across runs
Diffstat (limited to 'bpkg/package.cxx')
-rw-r--r--bpkg/package.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/bpkg/package.cxx b/bpkg/package.cxx
index 894051a..9a8068c 100644
--- a/bpkg/package.cxx
+++ b/bpkg/package.cxx
@@ -60,6 +60,13 @@ namespace bpkg
return !s.empty () ? name.string () + ' ' + s : name.string ();
}
+ bool config_package::
+ operator< (const config_package& v) const
+ {
+ int r (name.compare (v.name));
+ return r != 0 ? (r < 0) : (db < v.db);
+ }
+
// available_package
//
const version* available_package::