8000 workflow parser too permissive with local path references to actions in uses clauses · Issue #22 · nektos/act · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

workflow parser too permissive with local path references to actions in uses clauses #22

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
michakfromparis opened this issue Jan 24, 2019 · 2 comments

Comments

@michakfromparis
Copy link

act version: 0.0.5
platform: OSX 10.14.2

When referencing actions that are contained in sub directories of the same repo. i.e.:

action "Lint" {
uses = "./.github/actions/go"
args = "lint"
}

the act parser allows you to write the uses clause without "./" at the start like this:

action "Lint" {
uses = ".github/actions/go"
args = "lint"
}

Although this is very correct and will run locally, the GitHub action parser won't be as permissive and will emit a parser error when you push your code

Behaviors should be aligned...

@cplee
Copy link
Contributor
cplee commented Jan 25, 2019

@michakfromparis i'd appreciate your feedback on PR #23 which should address this

@michakfromparis
Copy link
Author

LGTM. Thanks!

@cplee cplee closed this as completed in c2e1188 Jan 25, 2019
makrsmark pushed a commit to makrsmark/act that referenced this issue Aug 3, 2023
Close nektos#21

I have tested this PR and run Go actions successfully on:
- Windows host
- Docker on Windows
- Linux host
- Docker on Linux

Before running Go actions, we need to make sure that Go has been installed on the host or the Docker image.

Reviewed-on: https://gitea.com/gitea/act/pulls/22
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Zettat123 <zettat123@gmail.com>
Co-committed-by: Zettat123 <zettat123@gmail.com>
makrsmark pushed a commit to makrsmark/act that referenced this issue Aug 3, 2023
At present, the runner can't run go actions even if the go environment has been set by the `setup-go` action. The reason is that `setup-go` will add the go related paths to [`GITHUB_PATH`](https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#adding-a-system-path) but in nektos#22 I forgot to apply them before running go actions. After adding the `ApplyExtraPath` function, the `setup-go` action runs properly.

Reviewed-on: https://gitea.com/gitea/act/pulls/26
Reviewed-by: Jason Song <i@wolfogre.com>
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Zettat123 <zettat123@gmail.com>
Co-committed-by: Zettat123 <zettat123@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
0