[PATCH] D27438: clang-format-vsix: add a date stamp to the VSIX version number to ensure upgradability
Antonio Maiorano via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 5 17:38:38 PST 2016
amaiorano created this revision.
amaiorano added reviewers: klimek, hans, zturner.
amaiorano added a subscriber: cfe-commits.
Herald added a subscriber: mgorny.
Presently, the version number of the VSIX matches the LLVM version number. However, as this number doesn't change often, it means that as we release new versions of this VSIX, it will have the same version number, which means users must first uninstall the old version before installing the new one. With this change, we generate a 4th part to the version number that is a date stamp (year, month, day); for example: 4.0.0.161203.
https://reviews.llvm.org/D27438
Files:
tools/clang-format-vs/CMakeLists.txt
Index: tools/clang-format-vs/CMakeLists.txt
===================================================================
--- tools/clang-format-vs/CMakeLists.txt
+++ tools/clang-format-vs/CMakeLists.txt
@@ -11,8 +11,11 @@
"${CLANG_SOURCE_DIR}/LICENSE.TXT"
"${CMAKE_CURRENT_SOURCE_DIR}/ClangFormat/license.txt")
+ # Build number added to Clang version to ensure that new VSIX can be upgraded
+ string(TIMESTAMP CLANG_FORMAT_VSIX_BUILD %y%m%d UTC)
+
if (NOT CLANG_FORMAT_VS_VERSION)
- set(CLANG_FORMAT_VS_VERSION "${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}.${LLVM_VERSION_PATCH}")
+ set(CLANG_FORMAT_VS_VERSION "${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}.${LLVM_VERSION_PATCH}.${CLANG_FORMAT_VSIX_BUILD}")
endif()
configure_file("source.extension.vsixmanifest.in"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D27438.80357.patch
Type: text/x-patch
Size: 790 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20161206/79e603f4/attachment.bin>
More information about the cfe-commits
mailing list