forked from MicrosoftDocs/windows-driver-docs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathci-pipeline.yml
33 lines (32 loc) · 918 Bytes
/
ci-pipeline.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
trigger:
- main
jobs:
- job: MergeBranches
pool:
vmImage: 'ubuntu-latest'
steps:
- checkout: self
persistCredentials: true
- script: |
git config --global user.name "Ted Hudek"
git config --global user.email "[email protected]"
git checkout main
git checkout release-amethyst
git merge main --no-ff --no-commit
if [ $? -eq 0 ]; then
git commit -m "Merged main into release"
git push origin release-amethyst
git checkout live
git merge main --no-ff --no-commit
if [ $? -eq 0 ]; then
git commit -m "Merged main into live"
git push origin live
else
echo "Merge conflict when merging main to live"
exit 1
fi
else
echo "Merge conflict when merging main to release"
exit 1
fi
displayName: 'Merge main to release, then to live'