File tree 1 file changed +3
-2
lines changed
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 99
99
Write-host "Building from PR"
100
100
101
101
# get files changed in PR, if this is a PR
102
- $commit = Invoke-RestMethod -Uri "https://api.github.com/repos/nanoframework/nanoFramework.IoT.Device/pulls/$env:System_PullRequest_PullRequestNumber/files" -Header @{"Authorization"="$auth"} -ContentType "application/json" -Method GET
102
+ # can get max of 100 files using this method (for more requires paging)
103
+ $commit = Invoke-RestMethod -Uri "https://api.github.com/repos/nanoframework/nanoFramework.IoT.Device/pulls/$env:System_PullRequest_PullRequestNumber/files?per_page=100" -Header @{"Authorization"="$auth"} -ContentType "application/json" -Method GET
103
104
104
105
# filter removed files
105
106
$files = $commit.where{$_.status -ne 'removed'}
@@ -129,7 +130,7 @@ steps:
129
130
Write-host ""
130
131
131
132
# pattern to select device folder name
132
- $pattern = '(devices\/)(?<folder>. +)(\/)'
133
+ $pattern = '(devices\/)(?<folder>[a-zA-z.] +)(?> \/)'
133
134
134
135
# filter out the collection
135
136
$results = [Regex]::Matches($files1, $pattern)
You can’t perform that action at this time.
0 commit comments