Changeset 4193 for trunk/tools
- Timestamp:
- Sep 5, 2000, 7:36:22 PM (25 years ago)
- Location:
- trunk/tools/DailyBuild
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/DailyBuild/job.cmd
r3842 r4193 1 /* $Id: job.cmd,v 1. 2 2000-07-18 11:18:13bird Exp $1 /* $Id: job.cmd,v 1.3 2000-09-05 17:36:21 bird Exp $ 2 2 * 3 3 * Main job for building OS/2. … … 13 13 call SysloadFuncs; 14 14 15 sLogFile = '..\logs\' || Date(S) || '.log'; 16 sTree = 'tree' || Date(S); 15 /* 16 * Get source directory of this script 17 */ 18 parse source sd1 sd2 sScript 19 sScriptDir = filespec('drive', sScript) || filespec('path', sScript); 20 sLogFile = sScriptDir || '\logs\' || Date('S') || '.log'; 21 sTree = sScriptDir || '..\tree' || Date('S'); 17 22 18 23 /* 19 24 * Clean tree, get it and build it. 20 25 */ 21 'mkdir ..\'||sTree 22 'cd ..\'||sTree 26 'mkdir' sTree 27 filespec('drive', sScript); 28 'cd' sTree; 23 29 if (rc <> 0) then call failure rc, 'cd ..\'sTree 'failed.'; 24 'call ..\scripts\odin32env.cmd'30 'call' sScriptDir || 'odin32env.cmd' 25 31 if (rc <> 0) then call failure rc, 'Env failed.'; 26 'call ..\scripts\odin32clean.cmd'32 'call' sScriptDir || 'odin32clean.cmd' 27 33 if (rc <> 0) then call failure rc, 'Clean failed.'; 28 'call ..\scripts\odin32get.cmd'34 'call' sScriptDir || 'odin32get.cmd' 29 35 if (rc <> 0) then call failure rc, 'Get failed.'; 30 'call ..\scripts\odin32build.cmd 2>&1 | tee /a ' || sLogFile; /* 4OS/2 tee command. */36 'call' sScriptDir || 'odin32build.cmd 2>&1 | tee /a ' || sLogFile; /* 4OS/2 tee command. */ 31 37 if (rc <> 0) then call failure rc, 'Build failed.'; 32 38 … … 34 40 * Pack and upload it. 35 41 */ 36 'call ..\scripts\odin32pack.cmd 2>&1 | tee /a ' || sLogFile; /* 4OS/2 tee command. */42 'call' sScriptDir || 'odin32pack.cmd 2>&1 | tee /a ' || sLogFile; /* 4OS/2 tee command. */ 37 43 if (rc <> 0) then call failure rc, 'Packing failed.'; 38 'start /BG "Uploading Odin..." nice -f cmd /C ..\scripts\odin32ftp2.cmd';44 'start /BG "Uploading Odin..." nice -f cmd /C' sScriptDir || 'odin32ftp2.cmd'; 39 45 if (rc <> 0) then say 'rc='rc' FTPing failed. i = ' || i; 40 46 … … 42 48 * database update 43 49 */ 44 '..\scripts\odin32db.cmd 2>&1 | tee /a ' || sLogFile; /* 4OS/2 tee command. */50 sScriptDir || 'odin32db.cmd 2>&1 | tee /a ' || sLogFile; /* 4OS/2 tee command. */ 45 51 if (rc <> 0) then call failure rc, 'db failed.'; 46 52 … … 52 58 'cd c:\odin32'; 53 59 if (rc <> 0) then call failure rc, 'cd c:\odin32 failed.'; 54 'unzip -o d:\odin32\tree\*debug.zip';60 'unzip -o ' || sTree || '*debug.zip'; 55 61 if (rc <> 0) then call failure rc, 'unzip failed.'; 56 62 'd:' … … 68 74 say 'rc='rc sText 69 75 exit(rc); 76 -
trunk/tools/DailyBuild/odin32clean.cmd
r3451 r4193 1 /* $Id: odin32clean.cmd,v 1. 1 2000-04-27 11:32:24bird Exp $1 /* $Id: odin32clean.cmd,v 1.2 2000-09-05 17:36:22 bird Exp $ 2 2 * 3 * Deletes the tree (current directory and all subdirectories). 3 * Removes trees. WARNING!!!!! All tree<date> directories are removed 4 * if .nodelete is not found in the root of them. 4 5 * 5 * ( assumes that rd is equal to "deltree" (which it is in my installation).6 * (Delpath is a "deltree" clone I've made, use your own.) 6 7 * 7 8 * Copyright (c) 1999-2000 knut st. osmundsen (knut.stange.osmundsen@mynd.no) … … 10 11 * 11 12 */ 12 'echo y > %temp%\y_odin32'; 13 'rd . < %temp%\y_odin32'; 14 if RC <> 0 then call failure rc, 'Del failed.'; 15 'del %temp%\y_odin32'; 13 14 call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'; 15 call SysloadFuncs; 16 17 sTree = 'tree' || Date(S); 18 19 /* 20 * We assume currentdirectory is the current tree. 21 */ 22 rc = SysFileTree('..\tree'||substr(Date('S'),1,4)||'*.', 'asTrees', 'DO'); 23 if (rc = 0) then 24 do 25 do i = 1 to asTrees.0 26 if (stream(asTrees.i||'\.nodelete', 'c', 'query exists') = '') then 27 do 28 'echo y | delpath' asTrees.i; 29 end 30 say asTrees.i 31 end 32 end 33 16 34 exit(0); 17 35 -
trunk/tools/DailyBuild/odin32db.cmd
r3451 r4193 1 /* $Id: odin32db.cmd,v 1. 1 2000-04-27 11:32:25bird Exp $1 /* $Id: odin32db.cmd,v 1.2 2000-09-05 17:36:22 bird Exp $ 2 2 * 3 3 * Updates the Odin32 API database. … … 11 11 call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'; 12 12 call SysloadFuncs; 13 14 /* 15 * Get source directory of this script 16 */ 17 parse source sd1 sd2 sScript 18 sScriptDir = filespec('drive', sScript) || filespec('path', sScript); 13 19 14 20 'cd tools\database'; … … 26 32 27 33 /* create database backup */ 28 'c:'34 filespec('drive', getMySqlDataDir()); 29 35 if rc <> 0 then call failure rc, 'c: failed'; 30 'cd c:\emx\mysql\data\odin32'36 'cd' getMySqlDataDir()||'\odin32'; 31 37 if rc <> 0 then call failure rc, 'cd <> failed'; 32 38 'mysqladmin refresh'; 33 'rar a -m5 d:\temp\db'||date(S)||'.rar *'39 'rar a -m5 ' || sScriptDir || 'dbbackup\db'||date(S)||'.rar *' 34 40 if rc <> 0 then call failure rc, 'rar db failed'; 35 41 'cd \'; … … 43 49 exit(rc); 44 50 51 52 /* 53 * Get the MySql data directory. 54 */ 55 getMySqlDataDir: procedure 56 57 /* Get mysql variables */ 58 '@mysqladmin variables | rxqueue /lifo' 59 60 /* Get datadir */ 61 sDataDir = ''; 62 do queued() 63 pull s; 64 if (pos(' DATADIR ', s) > 0) then 65 do 66 sDataDir = strip( substr( s, pos('|',s,3) + 1 ) ); 67 sDataDir = strip( substr(sDataDir, 1, length(sDataDir)-1) ); 68 leave; 69 end 70 end 71 72 /* Drain queue */ 73 do queued() 74 pull s 75 end 76 drop s; 77 78 /* If failure set default directory. */ 79 if (sDataDir = '') then 80 sDataDir = 'd:\knut\Apps\MySql\data\'; 81 return sDataDir; 82 -
trunk/tools/DailyBuild/readme.txt
r3452 r4193 1 /* $Id: readme.txt,v 1. 1 2000-04-27 12:00:10bird Exp $ */1 /* $Id: readme.txt,v 1.2 2000-09-05 17:36:22 bird Exp $ */ 2 2 3 3 This is a short readme for the daily builder scripts. These are all the … … 7 7 Directory structure 8 8 ------------------- 9 The build scripts assumes that the scripts are found in ..\ scriptsand10 that the Odin32 CVS tree checkout is to be placed in ..\tree (relative to11 t he starting directory). The job.cmd is normally started from the scripts12 directory, and starts out changing the to ..\tree.9 The build scripts assumes that the scripts are found in ..\DailyBuild and 10 that the Odin32 CVS tree checkout is to be placed in ..\tree<date> (relative 11 to the start directory). The job.cmd is normally started from the 12 DailyBuild directory, and starts out changing the to ..\tree<date>. 13 13 Logs are placed in ..\logs. 14 14 15 <basedir>\scripts - All these scripts. 16 <basedir>\tree - The CVS tree (don't work on this, tree it's delete every night...). 17 <basedir>\logs - Logs. 15 <basedir>\DailyBuild - All these scripts. 16 <basedir>\tree<date> - The CVS tree (don't work on this, tree it's delete every night...). 17 <basedir>\DailyBuild\logs - Logs. 18 <basedir>\DailyBuild\dbbackup - Database backups. 18 19 19 20 … … 50 51 (I have a very simple one if needed.) 51 52 52 T hu 27.04.200053 Tue 05.09.2000 53 54 knut
Note:
See TracChangeset
for help on using the changeset viewer.