Slowcheetah XML transform for c# Windows Store / Metro / win-store app

52 views Asked by At

I have installed SlowCheetah from the extensions gallery, then from nuget (then uninstalled and reinstalled from nuget).

It works ! Almost ;)

That is it is transforming the relevant files and copying them to the bin/[nameofconfig e.g. Debug / Release]/ folder

However, when running the app locally the file that gets used is that found in e.g.

D:\Projects[projectname]\bin\Debug\ AppX

And this file remains as the original untransformed file.

What's the easiest way to get this working when I hit F5 as the extensions description claims it should (for a win store app).

I am guessing a copy file task in the .csproj would do the trick - anyone done this successfully?

1

There are 1 answers

0
MemeDeveloper On

Ok, so this seems to work (will have to test it for "Create App Package" later and update this answer then)...

I added an AfterBuild copy file task as follows :

 <Target Name="AfterBuild">
    <Copy SourceFiles="$(OutputPath)\PortiLog.Config.xml" DestinationFolder="$(OutputPath)\AppX" ContinueOnError="true" />
  </Target>

And Voila !!! se fantastique non?

My SlowCheetah transformed xml file is now copied correctly to the AppX folder which is the correct place when debugging locally and corresponds to

Package.Current.InstalledLocation

Thanks to @Christian.K for the answer here which lead me to my solution !