Commit cb84f4a

Nick committed on
Update post build script
commit cb84f4a63211a375d5b1f83acf2a2fcff78b07d3 parent 93e44f7
1 changed files +14−3
ModifiedPostBuild.pas +14−3
@@ -24,7 +24,18 @@ uses SysUtils, StrUtils;
24 procedure HTCopyFile(Source: String); 24 procedure HTCopyFile(Source: String);
25 begin 25 begin
26 {$ifdef WINDOWS} 26 {$ifdef WINDOWS}
27 ExecuteProcess('cmd.exe', '/c "xcopy /e /Y ' + ExpandFileName(Source) + ' ' + ParamStr(2) + ExtractFileName(Source) + '" > NUL'); 27 ExecuteProcess('cmd.exe', '/c "copy ' + ExpandFileName(Source) + ' ' + ParamStr(2) + ExtractFileName(Source) + '"');
28 {$endif}
29
30 {$ifdef UNIX}
31 ExecuteProcess('/bin/bash', '-c "cp -rf ' + Source + ' ' + ParamStr(2) + ExtractFileName(Source) + '" > /dev/null');
32 {$endif}
33 end;
34
35 procedure HTCopyDir(Source: String);
36 begin
37 {$ifdef WINDOWS}
38 ExecuteProcess('cmd.exe', '/c "robocopy /E ' + ExpandFileName(Source) + ' ' + ParamStr(2) + ExtractFileName(Source) + '"');
28 {$endif} 39 {$endif}
29 40
30 {$ifdef UNIX} 41 {$ifdef UNIX}
@@ -44,8 +55,8 @@ begin
44 HTCopyFile('Resources/Fonts/PixeliteTTF.ttf'); 55 HTCopyFile('Resources/Fonts/PixeliteTTF.ttf');
45 56
46 if not Dev then begin 57 if not Dev then begin
47 HTCopyFile('hUGEDriver'); 58 HTCopyDir('hUGEDriver');
48 HTCopyFile('Resources/SampleSongs'); 59 HTCopyDir('Resources/SampleSongs');
49 end else begin 60 end else begin
50 if not DirectoryExists(DestDir+'hUGEDriver') then 61 if not DirectoryExists(DestDir+'hUGEDriver') then
51 Writeln('hUGEDriver not copied in development mode. Manually link it there yourself!'); 62 Writeln('hUGEDriver not copied in development mode. Manually link it there yourself!');