I’ve for as long as i can remember been using SourceSafe integration for all my siebel projects. Thats all good and fine, but it is aging, and for other projects I’m now using subversion. So when i installed a complete siebel 8.2.2.4, i decided to move the source control integration from SourceSafe to SVN.
First off, Siebel is not really heping you here, the default source control file installed with 8.2.2.4 looks like the source control file back in Siebel 6.
Researching a little on the net, provided lots of discussions if siebel can integrate with SVN, and the answer to that question is yes – it can. But if you come from a development background that is non siebel, then I might as well call it as it is, the source integration will only cover objects modified directly in tools, and it is solely a change log, allowing you to backtrack changes in time to a specific object. Its not a build repository, or even a complete picture of the changes that may be within one version of Siebel (ie. non-metadata changes are not included).
The batch file srcctrl.bat needs a lot of modification to work, luckily there was this one guy Michael Williams, who posted a good looking svn enabled srcctrl.bat file.
Use the file below as your starting point.
@echo off SETLOCAL set SOFTWARE=svn set CHECKIN=%SOFTWARE% commit set CHECKOUT=%SOFTWARE% checkout set ADD=%SOFTWARE% add rem ================================================================== rem =============== User defined parameters ========================== rem ================================================================== rem IF SVN IS NOT IN THE DEFAULT PATH ADD IT HERE set PATH=[Path_to_svn];%PATH% set SVN_URL=https://[svnserver]/svn/[repository] set SVN_REPOS=[trunk] set SRC_USR=[youruser] set SRC_PSWD=[yourpassword] set LOGFILE=[path_to_siebel_root]\SVN\[repository]\svn_integration.log set WORKING_DIR=[path_to_siebel_root]\SVN\[repository] rem LOGFILE SHOULD NOT HAVE SPACES IN ITS PATH rem AND WATCH OUT FOR TRAILING SPACES ON THE SET COMMANDS! rem ================================================================== rem ================================================================== set OPTIONS=--username %SRC_USR% --password %SRC_PSWD% set COMMENT=-F set FILE= echo ===========================START============================ >> %LOGFILE% echo %DATE% %TIME% >> %LOGFILE% echo ARGS: >> %LOGFILE% echo %* >> %LOGFILE% echo ============================================================ >> %LOGFILE% echo PARSING.. >> %LOGFILE% set ACTION=%1 shift set DIR=%1 shift set COMMENT=%COMMENT% %1 set COMMENT_FILE=%1 shift set FILE=%1 SET DIR_NO_QUOTE=###%DIR%### SET DIR_NO_QUOTE=%DIR_NO_QUOTE:"###=% SET DIR_NO_QUOTE=%DIR_NO_QUOTE:###"=% SET DIR_NO_QUOTE=%DIR_NO_QUOTE:###=% if errorlevel 100 goto END echo ACTION: %ACTION% >> %LOGFILE% echo DIR: %DIR% >> %LOGFILE% echo COMMENT_FILE: %COMMENT_FILE% >> %LOGFILE% echo FILE: %FILE% >> %LOGFILE% echo DIR_NO_QUOTE: %DIR_NO_QUOTE% >> %LOGFILE% echo ============================================================ >> %LOGFILE% if %ACTION%==checkout goto CHECK_OUT if %ACTION%==checkin goto CHECK_IN :CHECK_OUT echo =========================CHECKOUT=========================== >> %LOGFILE% echo Check out file: %FILE% from Source Control System >> %LOGFILE% echo Change local directory to %DIR% >> %LOGFILE% chdir %DIR% >> %LOGFILE% 2>&1 echo Start checking out %FILE% from Source Control System >> %LOGFILE% echo %CHECKOUT% %SVN_URL%/%SVN_REPOS% %OPTIONS% "%WORKING_DIR%\%SVN_REPOS%" >> %LOGFILE% %CHECKOUT% %SVN_URL%/%SVN_REPOS% %OPTIONS% "%WORKING_DIR%\%SVN_REPOS%" >> %LOGFILE% 2>&1 echo ======================CHECKOUT DONE========================= >> %LOGFILE% goto END :CHECK_IN echo =========================CHECKIN============================ >> %LOGFILE% echo Check in file: %FILE% into Source Control System >> %LOGFILE% echo Change local directory to %WORKING_DIR%\%SVN_REPOS% >> %LOGFILE% chdir %WORKING_DIR%\%SVN_REPOS% >> %LOGFILE% 2>&1 if exist %FILE% goto FILE_EXIST >> %LOGFILE% 2>&1 echo Copying %FILE% to local Working Copy Folder: %WORKING_DIR%\%SVN_REPOS% >> %LOGFILE% copy "%DIR_NO_QUOTE%%FILE%" "%WORKING_DIR%\%SVN_REPOS%\%FILE%" >> %LOGFILE% 2>&1 echo Add %FILE% in case it doesn't exist in Source Control System >> %LOGFILE% echo %ADD% %WORKING_DIR%\%SVN_REPOS%\%FILE% %OPTIONS% >> %LOGFILE% %ADD% %WORKING_DIR%\%SVN_REPOS%\%FILE% %OPTIONS% >> %LOGFILE% 2>&1 goto COMMIT :FILE_EXIST echo Copying %FILE% to local Working Copy Folder: %WORKING_DIR%\%SVN_REPOS% >> %LOGFILE% echo copy "%DIR_NO_QUOTE%%FILE%" "%WORKING_DIR%\%SVN_REPOS%\%FILE%" >> %LOGFILE% copy "%DIR_NO_QUOTE%%FILE%" "%WORKING_DIR%\%SVN_REPOS%\%FILE%" >> %LOGFILE% 2>&1 :COMMIT echo Check in %WORKING_DIR%\%SVN_REPOS%\%FILE% into Source Control System >> %LOGFILE% echo %CHECKIN% %WORKING_DIR%\%SVN_REPOS%\%FILE% %COMMENT% %OPTIONS% >> %LOGFILE% echo ***** COMMENT_FILE ***** >> %LOGFILE% type %COMMENT_FILE% >> %LOGFILE% 2>&1 echo . >> %LOGFILE% echo ************************ >> %LOGFILE% %CHECKIN% %WORKING_DIR%\%SVN_REPOS%\%FILE% %COMMENT% %OPTIONS% >> %LOGFILE% 2>&1 echo =======================CHECKIN DONE========================= >> %LOGFILE% goto END :END echo %DATE% %TIME% >> %LOGFILE% echo ============================END============================= >> %LOGFILE% ENDLOCAL
Replace the elements in [square brackets] in above file, and you are ready to go.
I Use Subversion 1.7.x, SVNServer (std Edition) and Siebel Tools 8.2.2.4
Note: Rename the source control batch file (eg. to svn_srcctrl.bat) as siebel will overwrite the srcctrl.bat file on patches and updates 🙁
Enjoy!
/Henrik