mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-09 16:55:16 +00:00
[CI] Search .forgejo/workflows first
(cherry picked from commit8b11cab677
) (cherry picked from commitbe59270696
) (cherry picked from commite068f8b191
) (cherry picked from commit7855bb0c60
) (cherry picked from commit45c4c8f443
) (cherry picked from commit89520d67ff
) (cherry picked from commit15eeb417a4
) (cherry picked from commit6db53a2643
) (cherry picked from commit2f689b321f
) (cherry picked from commit 04dc478314c3b4927cca78c354ca46ee217f035a) (cherry picked from commita554624f40
) (cherry picked from commitabca05f0d1
) (cherry picked from commitdc13e7eb22
) (cherry picked from commita161c5740e
) (cherry picked from commit06d33e2773
) (cherry picked from commitf536275161
) (cherry picked from commit84ac6f314a
) (cherry picked from commit1e8126edfc
) (cherry picked from commit0287ac3416
) (cherry picked from commit3e5fca2aae
) (cherry picked from commit03b220bfeb
) (cherry picked from commit1d033f4aaf
) (cherry picked from commit2ee9e3e9a3
) (cherry picked from commitd28c284993
) (cherry picked from commit239df83859
) (cherry picked from commit96ae0c2e5d
) (cherry picked from commit49aef71b32
) (cherry picked from commit38b56d108d
) (cherry picked from commit30f8d9ec3a
) (cherry picked from commitd531861850
) (cherry picked from commita75707deaa
) (cherry picked from commitb1c73918b2
) (cherry picked from commit5391917091
) (cherry picked from commita427f8dae5
) (cherry picked from commit6ba6f62c7e
)
This commit is contained in:
parent
c480d7fe6d
commit
be2de105f5
|
@ -40,11 +40,14 @@ func IsWorkflow(path string) bool {
|
|||
return false
|
||||
}
|
||||
|
||||
return strings.HasPrefix(path, ".gitea/workflows") || strings.HasPrefix(path, ".github/workflows")
|
||||
return strings.HasPrefix(path, ".forgejo/workflows") || strings.HasPrefix(path, ".gitea/workflows") || strings.HasPrefix(path, ".github/workflows")
|
||||
}
|
||||
|
||||
func ListWorkflows(commit *git.Commit) (git.Entries, error) {
|
||||
tree, err := commit.SubTree(".gitea/workflows")
|
||||
tree, err := commit.SubTree(".forgejo/workflows")
|
||||
if _, ok := err.(git.ErrNotExist); ok {
|
||||
tree, err = commit.SubTree(".gitea/workflows")
|
||||
}
|
||||
if _, ok := err.(git.ErrNotExist); ok {
|
||||
tree, err = commit.SubTree(".github/workflows")
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue