mirror of
https://github.com/nektos/act.git
synced 2026-04-26 09:25:54 +03:00
[GH-ISSUE #1795] act requries all yaml files in subdirectories to be workflows, but shouldn't #874
Labels
No labels
area/action
area/cli
area/docs
area/image
area/runner
area/workflow
backlog
confirmed/not-planned
kind/bug
kind/discussion
kind/external
kind/feature-request
kind/question
meta/duplicate
meta/invalid
meta/need-more-info
meta/resolved
meta/wontfix
meta/workaround
needs-work
pull-request
review/not-planned
size/M
size/XL
size/XXL
stale
stale-exempt
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/act#874
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @sebix on GitHub (May 10, 2023).
Original GitHub issue: https://github.com/nektos/act/issues/1795
Bug report info
Command used with act
Describe issue
This is the actual output:
But I expect that workflows are listed like
The issue is the file
.github/workflows/scripts/ansible-playbook.ymlwhich is not a workflow file, but act tries to parse it as a workflow file although it isn't placed in the workflow directory.These workflows work on GitHub, see: https://github.com/certtools/intelmq/actions/
Link to GitHub repository
github.com/certtools/intelmq/
Workflow content
Relevant log output
Additional information
No response
@ChristopherHX commented on GitHub (May 10, 2023):
I wondered why recursively loading of workflows was ever merged into act (I didn't had the permission to block that), you can unblock your issue with the flag
--no-recurse.act -l --no-recurseI don't think it is best practice to store non workflow files under
.github/workflows/**/*, because this.githubfolder may introduce new config file locations at any point of time.Do you want to open a PR to set the default value of the flag to true?
github.com/nektos/act@65ef31f102/cmd/root.go (L73)You would only need to replace
falsewithtrue.@sebix commented on GitHub (May 10, 2023):
As long as GitHub itself does not load workflows recursively, I don't think it's adequate to do it in
actfor consistency.@JoshMcCullough commented on GitHub (May 15, 2023):
For this issue, it seems like (as suggested above) non-workflow files shouldn't be stored under
.github/workflows. Instead, the should live somewhere else in the repo and be referenced from the workflows.@github-actions[bot] commented on GitHub (Nov 12, 2023):
Issue is stale and will be closed in 14 days unless there is new activity
@dezren39 commented on GitHub (Nov 16, 2023):
this isn't documented in github, it's probably a best practice of sorts not to do this, but it's common to see variations in how people use the workflows folder. sort of like 'things in .github/workflows are build stuff, the rest is the "real code"'. i don't subscribe to that personally, but i've had multiple experiences (mostly in enterprise) where this has occurred. I suggest that, where possible, act should try to avoid putting additional constraints on users that github actions doesn't have.
@github-actions[bot] commented on GitHub (May 15, 2024):
Issue is stale and will be closed in 14 days unless there is new activity