[Title] If tizen configuration exist in bashrc, don't add tizen configuration
authorTaeyoung Son <taeyoung2.son@samsung.com>
Fri, 23 Dec 2011 01:53:55 +0000 (10:53 +0900)
committerTaeyoung Son <taeyoung2.son@samsung.com>
Fri, 23 Dec 2011 01:53:55 +0000 (10:53 +0900)
[Type] Feature
[Module] Sub
[Priority] Minor
[CQ#]
[Redmine#]
[Problem]
[Cause]
[Solution]

packager/linux/install.sh

index dd48727..a8acea2 100755 (executable)
@@ -86,7 +86,10 @@ rm -rf $TIZEN_SDK_INSTALL_PATH/$webkit_lib_linux_path/webkit-lib.tar.gz
 #fi
 
 ## Set sbi, sdb's environment path
-cat >> ${HOME}/.bashrc << END
+s=`cat ${HOME}/.bashrc | grep -n "## Tizen SDK configuration" | cut -f1 -d":"`
+
+if [ "x${s}" = "x" ] ; then
+       cat >> ${HOME}/.bashrc << END
 ## Tizen SDK configuration
 # This is generated by Tizen SDK. Please do not modify by yourself.
 # Set sbi, sdb environment path
@@ -94,7 +97,8 @@ export PATH=\$PATH:${TIZEN_SDK_INSTALL_PATH}/SDK/sdb:${TIZEN_SDK_INSTALL_PATH}/S
 ## End Tizen SDK configuration
 END
 
+fi
+
 source ${HOME}/.bashrc
 
 exit 0
-