We have a Sitecore based C# project setup in Azure DevOps. In the project there is a TdsGlobal.config file that date how far back to get the TDS changes. This should be dynamically changed during the deployment only to get the previous 3 weeks of TDS packages.
<IncludeItemsChangedAfter>2019-04-01</IncludeItemsChangedAfter>
The above field in TdsGlobal.Config needs to be changed after each Production deployment. Any suggestions how to achieve to this!
If you only update
IncludeItemsChangedAfterfield inTdsGlobal.Configduring the Production deployment instead of updating this field in the repo, you could use the task Replace Tokens to update the key's values:If you need to update the change in the repo, there are two ways to achieve this.
One is using the REST API Pushes - Create to update the
TdsGlobal.Configfile:Check this thread for some more detailed steps.
Another is use powershell scripts to update the file and git command line to submit the the change into the repo:
Add a command line task clone the repo.
TdsGlobal.Config.Add another command line task to submit the changes to the repo:
Check this thread for some more details.
Hope this helps.