Adding documentation regarding versions. (#1611)

* Adding documentation regarding versions.

* Minor tweaks.
This commit is contained in:
Daniel Lemire 2021-06-07 14:19:23 -04:00 committed by GitHub
parent 7ca016652e
commit 34bb2079e7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 34 additions and 5 deletions

View File

@ -7,6 +7,7 @@ An overview of what you need to know to use simdjson, with examples.
* [Including simdjson](#including-simdjson)
* [Using simdjson with package managers](#using-simdjson-with-package-managers)
* [Using simdjson as a CMake dependency](#using-simdjson-as-a-cmake-dependency)
* [Versions](#versions)
* [The Basics: Loading and Parsing JSON Documents](#the-basics-loading-and-parsing-json-documents)
* [Documents Are Iterators](#documents-are-iterators)
* [Using the Parsed JSON](#using-the-parsed-json)
@ -54,12 +55,12 @@ Note:
Using simdjson with package managers
------------------
You can install the simdjson library on your system or in your project using multiple package managers such as MSYS2, the conan package manager, vcpkg, brew, the apt package manager (debian-based Linux systems), the FreeBSD package manager (FreeBSD), and so on. [Visit our wiki for more details](https://github.com/simdjson/simdjson/wiki/Installing-simdjson-with-a-package-manager).
You can install the simdjson library on your system or in your project using multiple package managers such as MSYS2, the conan package manager, vcpkg, brew, the apt package manager (debian-based Linux systems), the FreeBSD package manager (FreeBSD), and so on. [Visit our wiki for more details](https://github.com/simdjson/simdjson/wiki/Installing-simdjson-with-a-package-manager).
Using simdjson as a CMake dependency
------------------
You can include the simdjson as a CMake dependency by including the following lines in your `CMakeLists.txt`:
You can include the simdjson library as a CMake dependency by including the following lines in your `CMakeLists.txt`:
```cmake
include(FetchContent)
@ -75,7 +76,7 @@ FetchContent_MakeAvailable(simdjson)
You should replace `GIT_TAG v0.9.3` by the version you need. If you omit `GIT_TAG v0.9.3`, you will work from the main branch of simdjson: we recommend that if you are working on production code, you always work from a release.
Elsewhere in your project, you can declare dependencies on simdjson with lines such as these:
Elsewhere in your project, you can declare dependencies on simdjson with lines such as these:
```cmake
add_executable(myprogram myprogram.cpp)
@ -86,11 +87,39 @@ We recommend CMake version 3.15 or better.
See [our CMake demonstration](https://github.com/simdjson/cmake_demo_single_file). It works under Linux, FreeBSD, macOS and Windows (including Visual Studio).
The CMake build in simdjson can be taylored with a few variables. You can see the available variables and their default values by entering the `cmake -LA` command.
Versions
------------------
Users are discouraged from building production code from the
project's main branch. The main branch is used for development:
it may contain new features but also additional bugs.
Users should pick a release. They should also access the
documentation matching the release that they have chosen.
Note that new features may be added over time.
Our releases are tagged using semantic versioning: the tags
are made of three numbers prefixed by the letter `v` and separated by periods.
You can always find the latest release at the following hyperlink:
https://github.com/simdjson/simdjson/releases/latest/
The archive you download at this location contains its own corresponding
documentation.
You can also choose to browse a specific version
of the documentation and the code using GitHub,
by appending the version number to the hyperlink, like so:
https://github.com/simdjson/simdjson/blob/vx.y.z/doc/basics.md
where `x.y.z` should correspond to the version number you have
chosen.
The Basics: Loading and Parsing JSON Documents
----------------------------------------------