chore: update docs; final read
ci/woodpecker/pr/docs Pipeline was successful Details
ci/woodpecker/pr/lint Pipeline was successful Details
ci/woodpecker/pr/build Pipeline was successful Details
ci/woodpecker/pr/docker Pipeline was successful Details
ci/woodpecker/pr/man Pipeline was successful Details
ci/woodpecker/pr/test Pipeline was successful Details

pull/332/head
Jef Roosens 2023-01-04 14:37:41 +01:00
parent 39a026fdb3
commit 398e2bd9eb
Signed by: Jef Roosens
GPG Key ID: B75D4F293C7052DB
2 changed files with 5 additions and 1 deletions

View File

@ -55,6 +55,8 @@ Parameter | Description
limit | Maximum amount of results to return.
offset | Offset of results.
repo | Limit results to targets that publish to the given repo.
query | Only return targets that have this substring in their URL, path or branch.
arch | Only return targets that publish to this arch.
## Get specific target

View File

@ -63,6 +63,7 @@ fn (mut ti TargetsIterator) advance_window() {
|| it.path.contains(ti.filter.query) || it.branch.contains(ti.filter.query))
}
// We break out of the loop once we found a non-empty window
if ti.window.len > 0 {
break
}
@ -75,7 +76,8 @@ pub fn (mut ti TargetsIterator) next() ?Target {
return none
}
// The first call to `next` will cause the sliding window to move to where the requested offset starts
// The first call to `next` will cause the sliding window to move to where
// the requested offset starts
if !ti.started {
ti.advance_window()