Welcome to mirror list, hosted at ThFree Co, Russian Federation.

README.md - github.com/ArthurSonzogni/nlohmann_json_cmake_fetchcontent.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 0d47a0c1d59700a67f05c845f58485f11ec8fe70 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# Release-tracking repository for nlohmann/json

Goal is to provide a lightweight and autonomous repository tracking every
releases of [nlohmann/json](https://github.com/nlohmann/json).

It is meant to be used with CMake
[FetchContent](https://cmake.org/cmake/help/v3.11/module/FetchContent.html).

You can always replace the URL by the official repository:
<https://github.com/nlohmann/json>.
The only differences are:

* The download size: ~500KB vs ~150MB (300× difference)
* Some options are not available. See [the unsupported options section](#Unsupported-options).

## Example

~~~cmake
include(FetchContent)

# Optional: set this to ON if your target publicly links to nlohmann_json and needs to install() 
# set(JSON_Install ON)

FetchContent_Declare(json
  GIT_REPOSITORY https://github.com/ArthurSonzogni/nlohmann_json_cmake_fetchcontent
  GIT_PROGRESS TRUE
  GIT_SHALLOW TRUE
  GIT_TAG v3.11.2)

FetchContent_MakeAvailable(json)

target_link_libraries(foo PRIVATE nlohmann_json::nlohmann_json)
~~~

## Unsupported options

The following options are currently not supported. This is done on purpose
because they do not really make sense for a mirror repository, or they have not
been thoroughly tested. Consider using the official repository if you need these
options.

* `JSON_CI`
* `JSON_BuildTests`

## Updates

This repository is fully autonomous. It updates itself every week using github
actions.

### Thanks

This repository is based on: [astoeckel/json](https://github.com/astoeckel/json).

### Addressed `nlohmann/json` issues:

* [#2073](https://github.com/nlohmann/json/issues/2073),
* [#732](https://github.com/nlohmann/json/issues/732),
* [#620](https://github.com/nlohmann/json/issues/620),
* [#556](https://github.com/nlohmann/json/issues/556),
* [#482](https://github.com/nlohmann/json/issues/482),
* [#96](https://github.com/nlohmann/json/issues/96)