This commit is contained in:
nlohmann
2026-05-09 09:02:24 +00:00
parent 3d26d62a39
commit 9446cb8fa1
246 changed files with 631 additions and 480 deletions
+6
View File
@@ -0,0 +1,6 @@
libs =
import libs = nlohmann-json%lib{json}
exe{example}: {hxx ixx txx cxx}{**} $libs testscript
cxx.poptions =+ "-I$out_root" "-I$src_root"
+10
View File
@@ -0,0 +1,10 @@
#include <nlohmann/json.hpp>
#include <iostream>
#include <iomanip>
using json = nlohmann::json;
int main()
{
std::cout << std::setw(4) << json::meta() << std::endl;
}
+14
View File
@@ -0,0 +1,14 @@
name: example
version: 0.1.0-a.0.z
language: c++
summary: example C++ executable
license: other: proprietary ; Not free/open source.
description-file: README.md
url: https://example.org/example
email: your@emailprovider.com
#build-error-email: your@emailprovider.com
depends: * build2 >= 0.16.0
depends: * bpkg >= 0.16.0
#depends: libhello ^1.0.0
depends: nlohmann-json
+11
View File
@@ -0,0 +1,11 @@
: 1
summary: example project repository
:
role: prerequisite
location: https://pkg.cppget.org/1/stable
#trust: ...
#:
#role: prerequisite
#location: https://git.build2.org/hello/libhello.git
+24
View File
@@ -0,0 +1,24 @@
: json basics
:
$* >>~/EOO/
{
"compiler": {
/ "c\+\+": "\d+",/
/ "family": "[\w\d]+",/
/ "version": \d+/
},
/ "copyright": "\(C\) 2013-\d+ Niels Lohmann",/
"name": "JSON for Modern C++",
/ "platform": "[\w\d]+",/
"url": "https://github.com/nlohmann/json",
"version": {
"major": 3,
/ "minor": \d+,/
/ "patch": \d+,/
/ "string": "3\.\d+\.\d+"/
}
}
EOO
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long