clang-tidy: Enable readability-isolate-declaration check

This check detects local variable declarations declaring more than
one variable and tries to refactor the code to one statement per
declaration.

Change-Id: Ie51ae4cbabb0d71e26e8cacd329a0886604395a9
Signed-off-by: Pavithra Barithaya <pavithrabarithaya07@gmail.com>
diff --git a/.clang-tidy b/.clang-tidy
index 3856aa5..51ee20b 100644
--- a/.clang-tidy
+++ b/.clang-tidy
@@ -236,6 +236,7 @@
 readability-deleted-default,
 readability-function-size,
 readability-identifier-naming,
+readability-isolate-declaration,
 readability-make-member-function-const,
 readability-misleading-indentation,
 readability-misplaced-array-index,
diff --git a/serialize.cpp b/serialize.cpp
index ff9e832..e28129f 100644
--- a/serialize.cpp
+++ b/serialize.cpp
@@ -86,7 +86,8 @@
 
     // Find the mtd device "u-boot-env" to retrieve the environment variables
     std::ifstream mtdDevices("/proc/mtd");
-    std::string device, devicePath;
+    std::string device;
+    std::string devicePath;
 
     try
     {