Revision 117,
1.5 KB
checked in by pkopta, 12 years ago
(diff) |
AWK for Windows, scripts and installer for GaussView?/QCG-Icon integration
|
-
Property svn:executable set to
*
|
Line | |
---|
1 | @echo off
|
---|
2 |
|
---|
3 | rem SETLOCAL ENABLEEXTENSIONS
|
---|
4 | rem SETLOCAL DISABLEDELAYEDEXPANSION
|
---|
5 |
|
---|
6 | set base_dir=%~dps0
|
---|
7 |
|
---|
8 | set input_file=%1
|
---|
9 | set output_file=%2
|
---|
10 |
|
---|
11 | rem echo %input_file%
|
---|
12 |
|
---|
13 | set awk_cmd=%base_dir%\awk.exe
|
---|
14 | rem echo "executing" %awk_cmd% -f %base_dir%\get_chk.awk %input_file%
|
---|
15 |
|
---|
16 | rem set awk_cal1=%awk_cmd% -f %base_dir%\get_chk.awk %input_file%
|
---|
17 | rem %awk_cmd% -f %base_dir%\get_chk.awk %input_file% > awk_result
|
---|
18 |
|
---|
19 | for /f "tokens=*" %%i in ('%awk_cmd% -f %base_dir%\get_chk.awk %input_file%') do set chk_full_path=%%i
|
---|
20 | for %%X in (%chk_full_path%) do set chk_path=%%~dpsX
|
---|
21 | for %%X in (%chk_full_path%) do set chk_fname=%%~nxX
|
---|
22 | for %%X in (%input_file%) do set input_fname=%%~nxX
|
---|
23 | for %%X in (%output_file%) do set output_fname=%%~nxX
|
---|
24 | rem echo "checkpoint path" %chk_full_path%
|
---|
25 | rem echo %chk_fname%
|
---|
26 | rem echo %chk_path%
|
---|
27 |
|
---|
28 | set tmp_dir=%TEMP%\gauss-wd-%RANDOM%
|
---|
29 | mkdir %tmp_dir%
|
---|
30 |
|
---|
31 | set temp_input_file=%tmp_dir%\%input_fname%
|
---|
32 | rem echo "temp_input_file" %temp_input_file%
|
---|
33 |
|
---|
34 | %awk_cmd% -f "%base_dir%\remove_chk.awk" %input_file% > %temp_input_file%
|
---|
35 |
|
---|
36 | rem echo start "QCG-Icon launcher" /min /wait "C:\Program Files\qcg-icon\qcg-submit.exe" -s -w %tmp_dir% -o %tmp_dir%\%output_fname% %temp_input_file% > %tmp_dir%/cmd
|
---|
37 | start "QCG-Icon launcher" /MIN /WAIT "#QCG_ICON_PATH#" -s -w "%tmp_dir%" -o "%tmp_dir%\%output_fname%" "%temp_input_file%"
|
---|
38 | rem echo "coping" %tmp_dir%\%chk_fname% "%chk_full_path%"
|
---|
39 | copy %tmp_dir%\%chk_fname% "%chk_full_path%"
|
---|
40 | rem echo "coping" %tmp_dir%\%output_fname% %output_file%
|
---|
41 | copy %tmp_dir%\%output_fname% %output_file%
|
---|
42 |
|
---|
43 | rmdir %tmp_dir% /S /Q
|
---|
Note: See
TracBrowser
for help on using the repository browser.