diff --git a/.circleci/config.yml b/.circleci/config.yml index d08a77ca7..96d7b4b54 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -55,6 +55,7 @@ jobs: env VERSION "$($SCRIPTS/get_json_version.sh ./ci/version.json FULL)" env VERSION_SUFFIX "$($SCRIPTS/get_json_version.sh ./ci/version.json SUFFIX)" env VERSION_JSON_NET "$($SCRIPTS/get_json_version.sh ./ci/version.json JSON_NET)" + env VERSION_ASSEMBLY "$($SCRIPTS/get_json_version.sh ./ci/version.json ASSEMBLY)" echo echo ">>> UPDATING VERSION IN $(pwd)/Src/Newtonsoft.Json-for-Unity/package.json" diff --git a/Src/Newtonsoft.Json-for-Unity/CHANGELOG.md b/Src/Newtonsoft.Json-for-Unity/CHANGELOG.md index 8cda39d0b..6462e5d53 100644 --- a/Src/Newtonsoft.Json-for-Unity/CHANGELOG.md +++ b/Src/Newtonsoft.Json-for-Unity/CHANGELOG.md @@ -1,24 +1,17 @@ # Newtonsoft.Json for Unity changelog -## 12.0.101 +## 12.0.102 + +- Fixed to use only major version in assembly version (ex: `12.0.0.0`, instead of `12.0.1.0`) -## Changes +## 12.0.101 - Setup CircleCI integration - Setup Codacy integration - Switched to [cloudsmith.com][cloudsmith-url] as registry provider - New versioning format. For more info see [the readme in the repository][readme-url]. Changes are based of off `12.0.1-patch-001` version _(in previous format)._ - -## 12.0.1-patch-001 - - Fixed building on standalone ([Issue #3][issue3]) -## 12.0.1 - -- Initial release -- Deployed to [npmjs.com][npm-url] - [readme-url]: https://github.com/jilleJr/Newtonsoft.Json-for-Unity#readme [cloudsmith-url]: https://cloudsmith.io/~jillejr/repos/newtonsoft-json-for-unity -[npm-url]: https://www.npmjs.com/package/jillejr.newtonsoft.json-for-unity [issue3]: https://github.com/jilleJr/Newtonsoft.Json-for-Unity/issues/3 diff --git a/ci/local_build_into_package.ps1 b/ci/local_build_into_package.ps1 index dcc7e7cb2..a3b703031 100644 --- a/ci/local_build_into_package.ps1 +++ b/ci/local_build_into_package.ps1 @@ -70,6 +70,7 @@ try { env VERSION "$($SCRIPTS/get_json_version.sh ./ci/version.json FULL)" env VERSION_SUFFIX "$($SCRIPTS/get_json_version.sh ./ci/version.json SUFFIX)" env VERSION_JSON_NET "$($SCRIPTS/get_json_version.sh ./ci/version.json JSON_NET)" + env VERSION_ASSEMBLY "$($SCRIPTS/get_json_version.sh ./ci/version.json ASSEMBLY)" echo echo ">>> UPDATING VERSION IN $(pwd)/Src/Newtonsoft.Json-for-Unity/package.json" diff --git a/ci/scripts/build.sh b/ci/scripts/build.sh index ac1394fce..b17063824 100644 --- a/ci/scripts/build.sh +++ b/ci/scripts/build.sh @@ -11,6 +11,7 @@ BUILD_DESTINATION=${3:-${BUILD_DESTINATION:-"${BUILD_DESTINATION_BASE:?"Build ou : ${VERSION:?"Full version required."} : ${VERSION_JSON_NET:?"Json.NET version required."} +: ${VERSION_ASSEMBLY:?"Assembly version required."} : ${VERSION_SUFFIX:?"Version suffix required."} : ${BUILD_CONFIGURATION:="Release"} @@ -40,7 +41,7 @@ msbuild -t:build "$BUILD_SOLUTION" \ -p:UnityBuild="$BUILD_UNITY" \ -p:VersionPrefix="$VERSION_JSON_NET" \ -p:VersionSuffix="$VERSION_SUFFIX" \ - -p:AssemblyVersion="$VERSION_JSON_NET" \ + -p:AssemblyVersion="$VERSION_ASSEMBLY" \ -p:FileVersion="$VERSION" echo diff --git a/ci/scripts/get_json_version.sh b/ci/scripts/get_json_version.sh index 81cf201ca..48c4fc244 100644 --- a/ci/scripts/get_json_version.sh +++ b/ci/scripts/get_json_version.sh @@ -45,6 +45,9 @@ FULL) JSON_NET) jq2 -er '(.Major // 0|tostring) + "." + (.Minor // 0|tostring) + "." + (.Patch // 0|tostring)' "$jsonFile" ;; +ASSEMBLY) + jq2 -er '(.Major // 0|tostring) + ".0.0.0"' "$jsonFile" + ;; SUFFIX) release="$(jq2 -er '.Release // empty' "$jsonFile")" @@ -61,7 +64,7 @@ RELEASE) ;; *) error "Error: Unknown output type '$output' - Possible values: FULL, JSON_NET, SUFFIX, RELEASE" + Possible values: FULL, JSON_NET, ASSEMBLY, SUFFIX, RELEASE" exit 3 ;; esac diff --git a/ci/version.json b/ci/version.json index 0fcee831f..75c31c8b3 100644 --- a/ci/version.json +++ b/ci/version.json @@ -3,5 +3,5 @@ "Minor": 0, "Patch": 2, - "Release": 1 + "Release": 2 }