Skip to content
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

Fix passing multiple arguments to github action #82

Merged
merged 1 commit into from
Sep 22, 2021
Merged

Fix passing multiple arguments to github action #82

merged 1 commit into from
Sep 22, 2021

Conversation

errnesto
Copy link
Collaborator

@errnesto errnesto commented Aug 10, 2021

I messed up my original contribution… When one would pass more than one argument e.g. arguments: 'example.com --skip-file skipfile.txt' to the github action it would fail with:

FormatException: example.com%20--skipfile%20skipfile.txt is not a valid link-local address but contains %. Scope id should be used as part of link-local address. (at character 13) example.com%20--skipfile%20skipfile.txt

This is because github action arguments can only be strings, but when we pass them as args to the dockerfile the docker cmd looks like this: cmd=["https://qa.ems.press --skipfile hui.txt"]

The workaround I found is overwriting the docker entrypoint via the actions file. There I can just expand the inputs.arguments variable…

This should close #72

@errnesto
Copy link
Collaborator Author

Shure it would also be cool to pass arguments as real "github actions arguments" but I think then a entrypoint.sh script or something like that would be needed to map that input to the linkcheck command…
And that just seems more complicated :-)

@filiph
Copy link
Owner

filiph commented Sep 22, 2021

Sorry, I didn't see this earlier. Thank you!

@filiph filiph merged commit 342ae58 into filiph:master Sep 22, 2021
@errnesto errnesto deleted the fix/github-action-multiple-arguments branch September 22, 2021 16:32
@andrenarchy
Copy link

@filiph Could you create a release so we can start using this? Thank you! :)

@filiph
Copy link
Owner

filiph commented Oct 22, 2021

Thanks for the nudge! The new version (2.0.20) is in flight.

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

Successfully merging this pull request may close these issues.

github actions: Unable to pass -e
3 participants