XIDE: Placeholders in prebuild and postbuild events

May 06
2016

The following placeholders are available:

%NETSDKPATH%
%OUTPUTFILE%
%OUTPUTPDB%
%OUTPUTPATH%
%ProjectOutputPath%
%AppPath%
%ProjectPath%
%ConfigPath%
%AppName%
%AssemblyName%

A small sample for the executable cmd.exe:
%AppPath%Prg\App.config %ProjectOutputPath%%ConfigPath%%AssemblyName%.exe.config /y

or preferred by myself:
/c c:\xsharp\xide\postbuildcopy.cmd "%AssemblyName%.dll" "%ProjectOutputPath%%ConfigPath%" "c:\devnet\libs\rdm"

where postbuildcopy.cmd has the following content:
@echo off
set assemblyname=%1
set sourcepath=%2%
set targetpath=%3%
set sourcefile=%sourcepath%\%assemblyname%
set targetfile=%targetpath%\%assemblyname%
if not exist %sourcefile% goto ende
if exist %targetfile% goto replace
copy %sourcefile% %targetfile%
goto ende
:replace
replace %sourcefile% %targetpath% /u
:ende

Comments are closed.