forked from nlohmann/json
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #64 from nlohmann/develop
Update docset generation script (nlohmann#2967)
- Loading branch information
Showing
10 changed files
with
47 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -90,6 +90,7 @@ Thanks everyone! | |
|
||
:bug: If you found a **bug**, please check the [**FAQ**](https://json.nlohmann.me/home/faq/) if it is a known issue or the result of a design decision. Please also have a look at the [**issue list**](https://github.com/nlohmann/json/issues) before you [**create a new issue**](https://github.com/nlohmann/json/issues/new/choose). Please provide as many information as possible to help us understand and reproduce your issue. | ||
|
||
There is also a [**docset**](https://github.com/Kapeli/Dash-User-Contributions/tree/master/docsets/JSON_for_Modern_C%2B%2B) for the documentation browsers [Dash](https://kapeli.com/dash), [Velocity](https://velocity.silverlakesoftware.com), and [Zeal](https://zealdocs.org) that contains the full [documentation](https://json.nlohmann.me) as offline resource. | ||
|
||
## Examples | ||
|
||
|
@@ -1038,7 +1039,7 @@ auto cbor = json::to_msgpack(j); // 0xD5 (fixext2), 0x10, 0xCA, 0xFE | |
Though it's 2021 already, the support for C++11 is still a bit sparse. Currently, the following compilers are known to work: | ||
- GCC 4.8 - 11.0 (and possibly later) | ||
- Clang 3.4 - 12.0 (and possibly later) | ||
- Clang 3.4 - 13.0 (and possibly later) | ||
- Apple Clang 9.1 - 12.4 (and possibly later) | ||
- Intel C++ Compiler 17.0.2 (and possibly later) | ||
- Microsoft Visual C++ 2015 / Build Tools 14.0.25123.0 (and possibly later) | ||
|
@@ -1263,7 +1264,9 @@ If you are using [NuGet](https://www.nuget.org), you can use the package [nlohma | |
|
||
If you are using [conda](https://conda.io/), you can use the package [nlohmann_json](https://github.com/conda-forge/nlohmann_json-feedstock) from [conda-forge](https://conda-forge.org) executing `conda install -c conda-forge nlohmann_json`. Please file issues [here](https://github.com/conda-forge/nlohmann_json-feedstock/issues). | ||
|
||
If you are using [MSYS2](https://www.msys2.org/), your can use the [mingw-w64-nlohmann-json](https://packages.msys2.org/base/mingw-w64-nlohmann-json) package, just type `pacman -S mingw-w64-i686-nlohmann-json` or `pacman -S mingw-w64-x86_64-nlohmann-json` for installation. Please file issues [here](https://github.com/msys2/MINGW-packages/issues/new?title=%5Bnlohmann-json%5D) if you experience problems with the packages. | ||
If you are using [MSYS2](https://www.msys2.org/), you can use the [mingw-w64-nlohmann-json](https://packages.msys2.org/base/mingw-w64-nlohmann-json) package, just type `pacman -S mingw-w64-i686-nlohmann-json` or `pacman -S mingw-w64-x86_64-nlohmann-json` for installation. Please file issues [here](https://github.com/msys2/MINGW-packages/issues/new?title=%5Bnlohmann-json%5D) if you experience problems with the packages. | ||
|
||
If you are using [MacPorts](https://ports.macports.org), execute `sudo port install nlohmann-json` to install the [nlohmann-json](https://ports.macports.org/port/nlohmann-json/) package. | ||
|
||
If you are using [`build2`](https://build2.org), you can use the [`nlohmann-json`](https://cppget.org/nlohmann-json) package from the public repository https://cppget.org or directly from the [package's sources repository](https://github.com/build2-packaging/nlohmann-json). In your project's `manifest` file, just add `depends: nlohmann-json` (probably with some [version constraints](https://build2.org/build2-toolchain/doc/build2-toolchain-intro.xhtml#guide-add-remove-deps)). If you are not familiar with using dependencies in `build2`, [please read this introduction](https://build2.org/build2-toolchain/doc/build2-toolchain-intro.xhtml). | ||
Please file issues [here](https://github.com/build2-packaging/nlohmann-json) if you experience problems with the packages. | ||
|
@@ -1592,6 +1595,7 @@ I deeply appreciate the help of the following people. | |
- [Amir Masoud Abdol](https://github.com/amirmasoudabdol) updated the Homebrew command as nlohmann/json is now in homebrew-core. | ||
- [Hallot](https://github.com/Hallot) fixed some `-Wextra-semi-stmt warnings`. | ||
- [Giovanni Cerretani](https://github.com/gcerretani) fixed `-Wunused` warnings on `JSON_DIAGNOSTICS`. | ||
- [Bogdan Popescu](https://github.com/Kapeli) hosts the [docset](https://github.com/Kapeli/Dash-User-Contributions/tree/master/docsets/JSON_for_Modern_C%2B%2B) for offline documentation viewers. | ||
|
||
Thanks a lot for helping out! Please [let me know](mailto:[email protected]) if I forgot someone. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,25 @@ | ||
nlohmann_json.docset: Info.plist docSet.sql | ||
JSON_for_Modern_C++.docset: Info.plist docSet.sql | ||
$(MAKE) clean | ||
mkdir -p nlohmann_json.docset/Contents/Resources/Documents/ | ||
cp info.plist nlohmann_json.docset/Contents | ||
mkdir -p JSON_for_Modern_C++.docset/Contents/Resources/Documents/ | ||
cp icon*.png JSON_for_Modern_C++.docset | ||
cp Info.plist JSON_for_Modern_C++.docset/Contents | ||
# build and copy documentation | ||
$(MAKE) build -C ../mkdocs | ||
cp -r ../mkdocs/site/* nlohmann_json.docset/Contents/Resources/Documents | ||
cp -r ../mkdocs/site/* JSON_for_Modern_C++.docset/Contents/Resources/Documents | ||
# patch CSS to hide navigation items | ||
echo "\n\nheader, footer, navi, div.md-sidebar--primary, nav.md-tabs--active, a.md-content__button { display: none; }" >> nlohmann_json.docset/Contents/Resources/Documents/assets/stylesheets/main.b5d04df8.min.css | ||
echo "\n\nheader, footer, navi, div.md-sidebar--primary, nav.md-tabs--active, a.md-content__button { display: none; }" >> "$$(ls JSON_for_Modern_C++.docset/Contents/Resources/Documents/assets/stylesheets/main.*.min.css)" | ||
# fix spacing | ||
echo "\n\ndiv.md-sidebar div.md-sidebar--secondary, div.md-main__inner { top: 0; margin-top: 0 }" >> nlohmann_json.docset/Contents/Resources/Documents/assets/stylesheets/main.b5d04df8.min.css | ||
echo "\n\ndiv.md-sidebar div.md-sidebar--secondary, div.md-main__inner { top: 0; margin-top: 0 }" >> "$$(ls JSON_for_Modern_C++.docset/Contents/Resources/Documents/assets/stylesheets/main.*.min.css)" | ||
# remove "JSON for Modern C++" from page titles | ||
find nlohmann_json.docset/Contents/Resources/Documents -type f -exec gsed -i 's| - JSON for Modern C++</title>|</title>|' {} + | ||
find JSON_for_Modern_C++.docset/Contents/Resources/Documents -type f -exec gsed -i 's| - JSON for Modern C++</title>|</title>|' {} + | ||
# clean up | ||
rm nlohmann_json.docset/Contents/Resources/Documents/hooks.py | ||
rm nlohmann_json.docset/Contents/Resources/Documents/sitemap.* | ||
rm JSON_for_Modern_C++.docset/Contents/Resources/Documents/hooks.py | ||
rm JSON_for_Modern_C++.docset/Contents/Resources/Documents/sitemap.* | ||
# generate index | ||
sqlite3 nlohmann_json.docset/Contents/Resources/docSet.dsidx < docSet.sql | ||
sqlite3 JSON_for_Modern_C++.docset/Contents/Resources/docSet.dsidx < docSet.sql | ||
|
||
JSON_for_Modern_C++.tgz: JSON_for_Modern_C++.docset | ||
tar --exclude='.DS_Store' -cvzf JSON_for_Modern_C++.tgz JSON_for_Modern_C++.docset | ||
|
||
clean: | ||
rm -fr nlohmann_json.docset | ||
rm -fr JSON_for_Modern_C++.docset JSON_for_Modern_C++.tgz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"name": "JSON for Modern C++", | ||
"version": "3.10.0", | ||
"archive": "JSON_for_Modern_C++.tgz", | ||
"author": { | ||
"name": "Niels Lohmann", | ||
"link": "https://twitter.com/nlohmann" | ||
}, | ||
"aliases": ["nlohmann/json"] | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters