Skip to content
Merged
Changes from all commits
Commits
Show all changes
89 commits
Select commit Hold shift + click to select a range
2e9c6d2
add pipeline yml for syncing fabricbot.json aliases
Jan 30, 2023
f77bd21
change git user name and email in script
Jan 30, 2023
38b1f70
change inline script to GetWiki2Json.ps1 file
Feb 1, 2023
2e5c08a
remove unnecessary code
Feb 1, 2023
80aa187
change wrong dir
Feb 1, 2023
2831172
change to my personal repo for test
Feb 1, 2023
74313ff
change the usage of token
Feb 1, 2023
d25175c
change CreatePR.ps1 for test
Feb 1, 2023
c91b484
correct ParseWiki2Json.ps1
Feb 1, 2023
59a49c5
remove unnecessary output
Feb 1, 2023
d5e453e
remove quote
Feb 1, 2023
cf4bc10
finish test, change back to Azure repo
Feb 1, 2023
17b5be6
change branch name
Feb 1, 2023
11eccd6
change some names
Feb 1, 2023
bb4d892
remove the use of magic number
Feb 2, 2023
5b248b3
change commit message
Feb 2, 2023
91438f7
remove redundant git pull
Feb 2, 2023
dc0e489
change the way of getting wiki content
Feb 2, 2023
b5e6f7e
change space to -
Feb 2, 2023
0d2bbff
add md
Feb 2, 2023
affdb10
set current dir
Feb 2, 2023
ab482d1
use space
Feb 2, 2023
59d5cd6
use -
Feb 2, 2023
5d90c4b
still use ADOToken
Feb 2, 2023
635afa3
use a better wiki url
Feb 2, 2023
bcec48e
test purpose
Feb 2, 2023
0eef6bb
test2
Feb 2, 2023
fabc2b9
test oauth
Feb 2, 2023
60c55cb
test3
Feb 2, 2023
d796b9d
finish test
Feb 2, 2023
fdf250c
test again
Feb 5, 2023
198f2b0
test
Feb 6, 2023
51fffc1
finish test
Feb 6, 2023
ed35c0e
test cron
Feb 6, 2023
0f4ae7c
test double pr
Feb 6, 2023
b1924f2
solve double pr
Feb 6, 2023
d323d0d
test
Feb 7, 2023
d5ac369
test
Feb 7, 2023
e663991
test
Feb 7, 2023
95ff796
finish test
Feb 7, 2023
2d350cb
test
Feb 7, 2023
9bc5aab
finish test
Feb 7, 2023
2c5648d
test restapi
Feb 8, 2023
e829d30
te
Feb 8, 2023
e603ebb
finish test
Feb 8, 2023
878e781
test
Feb 8, 2023
077a711
finish test
Feb 8, 2023
9681afb
filter pr
Feb 8, 2023
40f8997
test
Feb 8, 2023
1b3634a
test
Feb 8, 2023
734537a
test
Feb 8, 2023
72f6684
test
Feb 8, 2023
1c4b9f3
finish test
Feb 8, 2023
9537c33
Solve pipeline error when no changes
Feb 14, 2023
6daa937
add newline at end of file
Feb 14, 2023
730d05e
change to pwsh
Feb 14, 2023
a18eebe
Merge branch 'main' into pipeline_for_fabricbot_aliases
greathongtu Feb 14, 2023
219bc14
test diff
Feb 15, 2023
4d13090
Merge branch 'pipeline_for_fabricbot_aliases' of https://github.com/x…
Feb 15, 2023
7be2bae
test
Feb 15, 2023
4ef61b5
test
Feb 15, 2023
d2a87c5
test
Feb 15, 2023
25ed275
test
Feb 15, 2023
1f7bb12
test
Feb 15, 2023
4e396ea
test
Feb 15, 2023
10b2685
test
Feb 15, 2023
ff754eb
test
Feb 15, 2023
cbd15ac
test
Feb 15, 2023
cf5e3cd
test
Feb 15, 2023
bfa48f9
test
Feb 15, 2023
6277ae6
test
Feb 15, 2023
132f64b
testt
Feb 15, 2023
39903d8
testt
Feb 15, 2023
d7625c7
testt
Feb 15, 2023
fdcbe43
testt
Feb 15, 2023
02753b6
Update sync-aliases.yml for Azure Pipelines
greathongtu Feb 15, 2023
61c276f
testt
Feb 15, 2023
9a646e1
Merge branch 'pipeline_for_fabricbot_aliases' of https://github.com/x…
Feb 15, 2023
158c6c2
testt
Feb 15, 2023
57e2409
test yml condition synthx
Feb 15, 2023
3bbaaa5
add succeed
Feb 15, 2023
9b3371f
add trim
Feb 15, 2023
dee9ddf
add null check
Feb 15, 2023
89e7f90
add newline
Feb 15, 2023
6058250
Merge branch 'main' into pipeline_for_fabricbot_aliases
greathongtu Feb 15, 2023
20c915e
remove checkout
Feb 15, 2023
9bb60c4
Merge branch 'pipeline_for_fabricbot_aliases' of https://github.com/x…
Feb 15, 2023
aab9515
use right url
Feb 15, 2023
8398c6c
remove diff
Feb 15, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 18 additions & 11 deletions .azure-pipelines/sync-aliases.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,17 @@ jobs:
./tools/Github/ParseWiki2Json.ps1 -ADOToken $(ADOToken)
displayName: Update fabricbot.json file locally

- pwsh: |
$gitStatus = git status -s
if (-not $gitStatus) {
Write-Host "The wiki has no changes ."
Write-Host "##vso[task.setvariable variable=ChangesDetected]false"
} else {
Write-Host "There are changes in the repository."
Write-Host "##vso[task.setvariable variable=ChangesDetected]true"
}
displayName: Check if Wiki table has any changes

- pwsh: |
git config --global user.email "[email protected]"
git config --global user.name "azure-powershell-bot"
Expand All @@ -25,17 +36,13 @@ jobs:
git remote set-url origin https://azure-powershell-bot:$(BotAccessToken)@github.com/Azure/azure-powershell.git;
git push origin internal/sync-fabricbot-json --force
displayName: Git commit and push
condition: and(succeeded(), eq(variables['ChangesDetected'], 'true'))

- pwsh: |
$diff = git diff main..internal/sync-fabricbot-json
if ($diff.Length -eq 0) {
Write-Host "No differences between main and internal/sync-fabricbot-json. Skipping PR creation."
} else {
$Title = "Sync fabricbot.json According To ADO Wiki Page"
$HeadBranch = "internal/sync-fabricbot-json"
$BaseBranch = "main"
$Description = "This PR sync taskType: scheduledAndTrigger part of fabricbot.json from table of Service-Team-Label-and-Contact-List in ADO wiki page"
./tools/Github/CreatePR.ps1 -Title $Title -HeadBranch $HeadBranch -BaseBranch $BaseBranch -BotAccessToken $(BotAccessToken) -Description $Description
}
$Title = "Sync fabricbot.json According To ADO Wiki Page"
$HeadBranch = "internal/sync-fabricbot-json"
$BaseBranch = "main"
$Description = "This PR sync taskType: scheduledAndTrigger part of fabricbot.json from table of Service-Team-Label-and-Contact-List in ADO wiki page"
./tools/Github/CreatePR.ps1 -Title $Title -HeadBranch $HeadBranch -BaseBranch $BaseBranch -BotAccessToken $(BotAccessToken) -Description $Description
displayName: Create PR to main branch

condition: and(succeeded(), eq(variables['ChangesDetected'], 'true'))