What is the $(Configuration part, Just
# social
s
What is the $(Configuration part, Just trying to do something similar and see this
k
Well.. I am tempted to submit a talk about it at spark 😉 - but on my v14 branch its like this.. (in directory.build.props) https://cdn.discordapp.com/attachments/1306988714685235291/1306996776167018516/image.png?ex=6738b31a&is=6737619a&hm=f589456b7e2130b4fd28d388ee84a96815270357564b6a7db2f2637764c485b6&
and the visual studio soluition took some manual fangling. (becasue the configuration manager writes things to every project!) and it looks a bit like this .. https://cdn.discordapp.com/attachments/1306988714685235291/1306997089623871560/image.png?ex=6738b364&is=673761e4&hm=a1241afe2c1bc00befcbe4f14465c88d64cc539a397e5b6a00bf34a950ef2abe&
and the build scripts are complicated for this one, but essentially you pass the config on the -c line of the
dotnet build
or
dotnet pack
line e.g in powershell , i have something like this.
Copy code
ps
dotnet pack "..\$package\$package.csproj" -c $env -o $outFolder -v q -p:TargetFrameworks=$framework -p:version=$versionString -p:UMBRACO_VERSION=$major -p:TargetFrameworks=$framework
$env would be "release_13" for example.
(i don't actually use the UMBRACO_VERSION bit anymore - i should remove that)
s
Nice, thanks. Doing my first v14+ bits today and trying to target both v13 and v14 is a little tricky, this really helps save some time
k
yeah - for the front end client stuff, i didn't really try, i have a .assets project for v13 and below. and a .client project for v14+ . the front end files and the controllers live in their relevant projects , so the back end core is shared, and they call it as needed.
s
Would be an interesting topic for a talk at Spark