From eb0f2be6db8ba1a28efdb194d9b2b9ecd78627d0 Mon Sep 17 00:00:00 2001 From: klokane Date: Mon, 16 Mar 2020 21:14:51 +0100 Subject: [PATCH 1/2] fix: expose version for CMake Fixes #775 --- src/CMakeLists.txt | 2 ++ src/drafter.cc | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 4232cfb4f..e4c2f3625 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -93,6 +93,8 @@ find_package(cmdline 1.0 REQUIRED) find_package(MPark.Variant 1.4 REQUIRED) find_package(pegtl 2.8 REQUIRED) +add_definitions( -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} ) + # drafter-dep # we need it to: # - expose INTERFACE_INCLUDE_DIRECTORIES for drafter-obj diff --git a/src/drafter.cc b/src/drafter.cc index 238ec65b9..95164b916 100644 --- a/src/drafter.cc +++ b/src/drafter.cc @@ -234,7 +234,6 @@ DRAFTER_API const char* drafter_version_string(void) #if defined CMAKE_BUILD_TYPE return DRAFTER_VERSION_STRING; #else - return "Non-oficial drafter gyp-based build"; #endif } From 0160cc8853183699406b35d6ddd6bae3887042a6 Mon Sep 17 00:00:00 2001 From: Kyle Fuller Date: Mon, 16 Mar 2020 17:48:11 +0000 Subject: [PATCH 2/2] release: 5.0.0-rc.1 --- CHANGELOG.md | 23 ++++++++++++++++++++--- src/CMakeLists.txt | 4 ++-- src/Version.h.in | 4 ++-- 3 files changed, 24 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2b8c4f645..be9e0014a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,11 +1,28 @@ # Drafter Changelog -## 5.0.0 (2020-02-04) +## 5.0.0-rc.1 (2020-03-16) + +### Breaking + +* Parsing and serialisation options in the C API of Drafter contain breaking + changes. Direct access to the option structures are no longer possible, a new + API layer has been added for the options. See `drafter_init_parse_options` + and `drafter_serialize_options` respectively. ### Enhancements -- [breaking] Modified C API so that drafter options can be added without - breaking the interface in the future. +* Improved support for URI Template. Drafter supports up to, and including + [level 4 of URI Template](https://tools.ietf.org/html/rfc6570#section-1.2). + This includes support for the URI Template explode (`*`) modifier, and + reserved value operator (`+`), and others. + + [#553](https://github.com/apiaryio/drafter/issues/553) + [#456](https://github.com/apiaryio/drafter/issues/456) + [#630](https://github.com/apiaryio/drafter/issues/630) + [#666](https://github.com/apiaryio/drafter/issues/666) + +* Added support for JSON Schema Draft 7 in schema generation from MSON. + JSON Schemas are now generated using Draft 7 instead of Draft 4. ## 4.1.0 (2019-12-28) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index e4c2f3625..e9eb98d9a 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -2,8 +2,8 @@ cmake_minimum_required(VERSION 3.5 FATAL_ERROR) project(Drafter VERSION 5.0.0 LANGUAGES CXX) -set(DRAFTER_VERSION_IS_RELEASE 1) -set(DRAFTER_PRE_RELEASE_VERSION 0) +set(DRAFTER_VERSION_IS_RELEASE 0) +set(DRAFTER_PRE_RELEASE_VERSION rc.1) configure_file(Version.h.in Version.h) include_directories(${PROJECT_BINARY_BIN}) diff --git a/src/Version.h.in b/src/Version.h.in index 67ab10a61..13cbbb66a 100644 --- a/src/Version.h.in +++ b/src/Version.h.in @@ -15,12 +15,12 @@ #define DRAFTER_PATCH_VERSION @PROJECT_VERSION_PATCH@ #define DRAFTER_VERSION_IS_RELEASE @DRAFTER_VERSION_IS_RELEASE@ -#define DRAFTER_PRE_RELEASE_VERSION @DRAFTER_PRE_RELEASE_VERSION@ +#define DRAFTER_PRE_RELEASE_VERSION "@DRAFTER_PRE_RELEASE_VERSION@" #if DRAFTER_VERSION_IS_RELEASE #define DRAFTER_VERSION_STRING "v@PROJECT_VERSION@" #else -#define DRAFTER_VERSION_STRING "v@PROJECT_VERSION@-pre.@DRAFTER_PRE_RELEASE_VERSION@" +#define DRAFTER_VERSION_STRING "v@PROJECT_VERSION@-@DRAFTER_PRE_RELEASE_VERSION@" #endif #endif