Svn commit with TeamCity

I use Visual Studio and TeamCity tools. I added the project to TeamCity. When the TeamCity project project succeeds, TeamCity should automatically commit the new binaries from the bin / Release folder to specify the SVN path (for example, svn: \ abc.com \ root \ trunk). Does anyone know how I can achieve this? Please let me know the steps. Thanks in advance.

+4
source share
2 answers

Add the Command Line build step to your TS configuration immediately after the initial build step containing the commit_build.bat command. Create a commit_build.bat file that will transfer your artifacts to SVN with standard svn commands.

Remember to commit commit_build.bat in the repo.

+1
source

Our build process includes the MsBuild Label step after completing the building and unit testing phases. this step cleans up any additional files from the assembly (for example, unnecessary external dependencies if you are building the project for a link elsewhere) and writes binary files. it's just an MsBuild step that runs the MsBuild script, putting inline projects.

you can get a list of project DLLs using the TargetOutputs element of the MsBuild call in your script, for example:

 <MSBuild Projects="yourSolutions" Targets="Rebuild" Properties="Configuration=Release;Platform=x86"> <Output ItemName="BinaryOutputs" TaskParameter="TargetOutputs"/> </MSBuild> 

you can use standard svn commands to commit your files.

0
source

Source: https://habr.com/ru/post/1436569/


All Articles