Automating Releases for D365 & Power Platform – Episode 2 Version Control

In this video, we explore CI/CD (continuous integration/continuous deployment) using Azure DevOps Pipelines to copy our Dynamics 365 Customer Engagement & Power Platform solutions to version control (Git) so that we can a) see what has changed over time and b) recall a solution at any point in time that was captured.

In the video, a couple of copy/paste blocks were used. I’ve provided them below for easy reference.

Powershell Script:

$date=$(Get-Date -Format 'yyyyMMdd')
Write-Host "##vso[task.setvariable variable=CurrentDate]$date"
Write-Host "Set CurrentDate to $date"

Command Line:

echo Commiting all changes
git config user.email "justin@notjust365.com"
git config user.name "Automatic Build"
git checkout master
git add --all
git commit -m "Automatic solution commit $(CurrentDate)"

echo Push code to repository
git -c http.extraheader="AUTHORIZATION: bearer $(System.AccessToken)" push origin master

Your support by SUBSCRIBING to my YouTube channel is very much appreciated.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Create a website or blog at WordPress.com

Up ↑