xsharp.eu • XIDE: copy none build file to output directory
Page 1 of 1

XIDE: copy none build file to output directory

Posted: Fri Mar 15, 2019 3:33 pm
by SHirsch
Hi Chris,

as you know I'm using XIDE. My question today: is there an easy way to have none code files copied to output directory?
Background: I have script and config files included in the project. I'm changing them inside of XIDE. When I'm compiling the project it would be very good to have them automatically copied to the output directory. At the moment I copy them manually.

If there is no easy way: My suggestion is to implement another Build Type 'copy to output folder'.

Regards,
Stefan

XIDE: copy none build file to output directory

Posted: Fri Mar 15, 2019 3:41 pm
by lumberjack
Hi Stefan,
You can copy them to your output folder e.g. BinDebug and reference them from there. If you Add existing file, just point to those and when prompted they not in the Project folder, do you want to copy, say no. They then permanently stay in the output folder. Better even, make a folder in the Debug and Release folders to have them seperate from the outputs. Adapt your code to read from these folders.

HTH,

XIDE: copy none build file to output directory

Posted: Fri Mar 15, 2019 3:43 pm
by SHirsch
Hi Johan,

I thought about that too but that would be outside of my git repo. And I like to have them also under source control.

Stefan

XIDE: copy none build file to output directory

Posted: Fri Mar 15, 2019 3:50 pm
by lumberjack
Hi Stefan,
In the application properties, on the advance tab, there is the post build events. Just create a small bat file that copies the files over...
Add it to the post build events.

//OutputCopy.bat
copy *.ext c:xideprojects....

XIDE: copy none build file to output directory

Posted: Fri Mar 15, 2019 4:14 pm
by Chris
Stefan, yeah I would do exactly what Johan says, add a Post Build event, this is exactly their purpose. Does that suit you?